diff options
Diffstat (limited to '7zip/Compress/LZMA/LZMADecoder.h')
-rwxr-xr-x | 7zip/Compress/LZMA/LZMADecoder.h | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/7zip/Compress/LZMA/LZMADecoder.h b/7zip/Compress/LZMA/LZMADecoder.h index 5cfd72ad..16e49269 100755 --- a/7zip/Compress/LZMA/LZMADecoder.h +++ b/7zip/Compress/LZMA/LZMADecoder.h @@ -145,9 +145,11 @@ public: class CDecoder: public ICompressCoder, public ICompressSetDecoderProperties2, + #ifdef _ST_MODE public ICompressSetInStream, public ICompressSetOutStreamSize, public ISequentialInStream, + #endif public CMyUnknownImp { CLZOutWindow _outWindowStream; @@ -170,26 +172,30 @@ class CDecoder: CLiteralDecoder _literalDecoder; - UInt32 _dictionarySizeCheck; - UInt32 _posStateMask; /////////////////// // State - UInt64 _outSize; - UInt64 _nowPos64; UInt32 _reps[4]; CState _state; Int32 _remainLen; // -1 means end of stream. // -2 means need Init + UInt64 _outSize; + bool _outSizeDefined; void Init(); - HRESULT CodeSpec(Byte *buffer, UInt32 size); + HRESULT CodeSpec(UInt32 size); public: + + #ifdef _ST_MODE MY_UNKNOWN_IMP4( ICompressSetDecoderProperties2, ICompressSetInStream, ICompressSetOutStreamSize, ISequentialInStream) + #else + MY_UNKNOWN_IMP1( + ICompressSetDecoderProperties2) + #endif void ReleaseStreams() { @@ -228,9 +234,12 @@ public: STDMETHOD(SetInStream)(ISequentialInStream *inStream); STDMETHOD(ReleaseInStream)(); STDMETHOD(SetOutStreamSize)(const UInt64 *outSize); + + #ifdef _ST_MODE STDMETHOD(Read)(void *data, UInt32 size, UInt32 *processedSize); - STDMETHOD(ReadPart)(void *data, UInt32 size, UInt32 *processedSize); + #endif + CDecoder(): _outSizeDefined(false) {} virtual ~CDecoder() {} }; |