mirror of
https://github.com/Xevion/easy7zip.git
synced 2025-12-14 14:11:40 -06:00
4.33 beta
This commit is contained in:
committed by
Kornel Lesiński
parent
e8d0636d7a
commit
02516d3fce
@@ -8,9 +8,8 @@ namespace BT_NAMESPACE {
|
||||
typedef UInt32 CIndex;
|
||||
const UInt32 kMaxValForNormalize = (UInt32(1) << 31) - 1;
|
||||
|
||||
class CMatchFinderBinTree:
|
||||
class CMatchFinder:
|
||||
public IMatchFinder,
|
||||
public IMatchFinderSetCallback,
|
||||
public CLZInWindow,
|
||||
public CMyUnknownImp
|
||||
{
|
||||
@@ -18,37 +17,36 @@ class CMatchFinderBinTree:
|
||||
UInt32 _cyclicBufferSize; // it must be historySize + 1
|
||||
UInt32 _matchMaxLen;
|
||||
CIndex *_hash;
|
||||
CIndex *_son;
|
||||
UInt32 _hashMask;
|
||||
UInt32 _cutValue;
|
||||
|
||||
CMyComPtr<IMatchFinderCallback> m_Callback;
|
||||
UInt32 _hashSizeSum;
|
||||
|
||||
void Normalize();
|
||||
void FreeThisClassMemory();
|
||||
void FreeMemory();
|
||||
|
||||
MY_UNKNOWN_IMP1(IMatchFinderSetCallback)
|
||||
MY_UNKNOWN_IMP
|
||||
|
||||
STDMETHOD(Init)(ISequentialInStream *inStream);
|
||||
STDMETHOD(SetStream)(ISequentialInStream *inStream);
|
||||
STDMETHOD_(void, ReleaseStream)();
|
||||
STDMETHOD(MovePos)();
|
||||
STDMETHOD(Init)();
|
||||
HRESULT MovePos();
|
||||
STDMETHOD_(Byte, GetIndexByte)(Int32 index);
|
||||
STDMETHOD_(UInt32, GetMatchLen)(Int32 index, UInt32 back, UInt32 limit);
|
||||
STDMETHOD_(UInt32, GetNumAvailableBytes)();
|
||||
STDMETHOD_(const Byte *, GetPointerToCurrentPos)();
|
||||
STDMETHOD_(Int32, NeedChangeBufferPos)(UInt32 numCheckBytes);
|
||||
STDMETHOD_(void, ChangeBufferPos)();
|
||||
|
||||
STDMETHOD(Create)(UInt32 historySize, UInt32 keepAddBufferBefore,
|
||||
UInt32 matchMaxLen, UInt32 keepAddBufferAfter);
|
||||
STDMETHOD_(UInt32, GetLongestMatch)(UInt32 *distances);
|
||||
STDMETHOD_(void, DummyLongestMatch)();
|
||||
|
||||
// IMatchFinderSetCallback
|
||||
STDMETHOD(SetCallback)(IMatchFinderCallback *callback);
|
||||
|
||||
virtual void BeforeMoveBlock();
|
||||
virtual void AfterMoveBlock();
|
||||
STDMETHOD(GetMatches)(UInt32 *distances);
|
||||
STDMETHOD(Skip)(UInt32 num);
|
||||
|
||||
public:
|
||||
CMatchFinderBinTree();
|
||||
virtual ~CMatchFinderBinTree();
|
||||
CMatchFinder();
|
||||
virtual ~CMatchFinder();
|
||||
void SetCutValue(UInt32 cutValue) { _cutValue = cutValue; }
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user