~ubuntu-branches/ubuntu/utopic/p7zip/utopic-updates

« back to all changes in this revision

Viewing changes to 7zip/Compress/Deflate/DeflateDecoder.h

  • Committer: Bazaar Package Importer
  • Author(s): Mohammed Adnène Trojette
  • Date: 2006-02-10 20:54:59 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20060210205459-qbpkkabtqdd97zo7
Tags: 4.33.dfsg-1
* New upstream release
* Move p7zip from /usr/share to /usr/bin
   - modify debian/install
   - write debian/p7zip.1
* debian/README.Debian: document directory exclusion
* patches/01_add_help_switch: 7z --help works now (Closes: #353235)

Show diffs side-by-side

added added

removed removed

Lines of Context:
11
11
#include "../LZ/LZOutWindow.h"
12
12
#include "../Huffman/HuffmanDecoder.h"
13
13
 
14
 
#include "DeflateExtConst.h"
15
14
#include "DeflateConst.h"
16
15
 
17
16
namespace NCompress {
18
17
namespace NDeflate {
19
18
namespace NDecoder {
20
19
 
21
 
class CException
22
 
{
23
 
public:
24
 
  enum ECauseType
25
 
  {
26
 
    kData
27
 
  } m_Cause;
28
 
  CException(ECauseType aCause): m_Cause(aCause) {}
29
 
};
30
 
 
31
 
typedef NStream::NLSBF::CDecoder<CInBuffer> CInBit;
32
 
 
33
20
class CCoder:
34
21
  public ICompressCoder,
35
22
  public ICompressGetInStreamProcessedSize,
41
28
  public CMyUnknownImp
42
29
{
43
30
  CLZOutWindow m_OutWindowStream;
44
 
  CInBit m_InBitStream;
45
 
  NCompress::NHuffman::CDecoder<kNumHuffmanBits, kStaticMainTableSize> m_MainDecoder;
46
 
  NCompress::NHuffman::CDecoder<kNumHuffmanBits, kStaticDistTableSize> m_DistDecoder;
 
31
  NStream::NLSBF::CDecoder<CInBuffer> m_InBitStream;
 
32
  NCompress::NHuffman::CDecoder<kNumHuffmanBits, kFixedMainTableSize> m_MainDecoder;
 
33
  NCompress::NHuffman::CDecoder<kNumHuffmanBits, kFixedDistTableSize> m_DistDecoder;
47
34
  NCompress::NHuffman::CDecoder<kNumHuffmanBits, kLevelTableSize> m_LevelDecoder;
48
35
 
49
36
  UInt32 m_StoredBlockSize;
50
37
 
51
38
  bool m_FinalBlock;
52
39
  bool m_StoredMode;
 
40
  UInt32 _numDistLevels;
 
41
 
 
42
 
53
43
  bool _deflate64Mode;
54
44
  bool _keepHistory;
55
 
  int _remainLen;
 
45
  Int32 _remainLen;
56
46
  UInt32 _rep0;
57
47
  bool _needReadTable;
58
48
 
 
49
  UInt32 ReadBits(int numBits);
59
50
 
60
 
  void DeCodeLevelTable(Byte *newLevels, int numLevels);
 
51
  bool DeCodeLevelTable(Byte *values, int numSymbols);
61
52
  bool ReadTables();
62
53
  
63
 
  void CCoder::ReleaseStreams()
 
54
  void ReleaseStreams()
64
55
  {
65
56
    m_OutWindowStream.ReleaseStream();
66
57
    ReleaseInStream();