annotate src/win32/7zip/7z/CPP/Common/MyMap.h @ 1:f9f4f1b99eed

importing src directory
author Robert McIntyre <rlm@mit.edu>
date Sat, 03 Mar 2012 10:31:27 -0600
parents
children
rev   line source
rlm@1 1 // MyMap.h
rlm@1 2
rlm@1 3 #ifndef __COMMON_MYMAP_H
rlm@1 4 #define __COMMON_MYMAP_H
rlm@1 5
rlm@1 6 #include "MyVector.h"
rlm@1 7 #include "Types.h"
rlm@1 8
rlm@1 9 class CMap32
rlm@1 10 {
rlm@1 11 struct CNode
rlm@1 12 {
rlm@1 13 UInt32 Key;
rlm@1 14 UInt32 Keys[2];
rlm@1 15 UInt32 Values[2];
rlm@1 16 UInt16 Len;
rlm@1 17 Byte IsLeaf[2];
rlm@1 18 };
rlm@1 19 CRecordVector<CNode> Nodes;
rlm@1 20
rlm@1 21 public:
rlm@1 22
rlm@1 23 void Clear() { Nodes.Clear(); }
rlm@1 24 bool Find(UInt32 key, UInt32 &valueRes) const;
rlm@1 25 bool Set(UInt32 key, UInt32 value); // returns true, if there is such key already
rlm@1 26 };
rlm@1 27
rlm@1 28 #endif