SNAP Library 3.0, User Reference
2016-07-20 17:56:49
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
|
#include <hash.h>
Public Types | |
typedef TPt< TStringPool > | PStringPool |
Public Member Functions | |
TStrHash () | |
TStrHash (const PStringPool &StrPool) | |
TStrHash (const int &Ports, const bool &_AutoSizeP=false, const PStringPool &StrPool=PStringPool()) | |
TStrHash (const TStrHash &Hash) | |
TStrHash (TSIn &SIn, bool PoolToo=true) | |
void | Load (TSIn &SIn, bool PoolToo=true) |
void | Save (TSOut &SOut, bool PoolToo=true) const |
void | SetPool (const PStringPool &StrPool) |
PStringPool | GetPool () const |
TStrHash & | operator= (const TStrHash &Hash) |
bool | Empty () const |
int | Len () const |
int | Reserved () const |
int | GetPorts () const |
bool | IsAutoSize () const |
int | GetMxKeyIds () const |
bool | IsKeyIdEqKeyN () const |
int | AddKey (const char *Key) |
int | AddKey (const TStr &Key) |
int | AddKey (const TChA &Key) |
int | AddDat (const char *Key, const TDat &Dat) |
int | AddDat (const TStr &Key, const TDat &Dat) |
int | AddDat (const TChA &Key, const TDat &Dat) |
TDat & | AddDat (const char *Key) |
TDat & | AddDat (const TStr &Key) |
TDat & | AddDat (const TChA &Key) |
TDat & | AddDatId (const char *Key) |
TDat & | AddDatId (const TStr &Key) |
TDat & | AddDatId (const TChA &Key) |
const TDat & | operator[] (const int &KeyId) const |
TDat & | operator[] (const int &KeyId) |
const TDat & | operator() (const char *Key) const |
::TSize | GetMemUsed () const |
const TDat & | GetDat (const char *Key) const |
const TDat & | GetDat (const TStr &Key) const |
TDat & | GetDat (const char *Key) |
const TDat & | GetDat (const TStr &Key) |
const TDat & | GetDat (const TChA &Key) |
TDat & | GetDatId (const int &KeyId) |
const TDat & | GetDatId (const int &KeyId) const |
void | GetKeyDat (const int &KeyId, int &KeyO, TDat &Dat) const |
void | GetKeyDat (const int &KeyId, const char *&Key, TDat &Dat) const |
void | GetKeyDat (const int &KeyId, TStr &Key, TDat &Dat) const |
void | GetKeyDat (const int &KeyId, TChA &Key, TDat &Dat) const |
int | GetKeyId (const char *Key) const |
int | GetKeyId (const TStr &Key) const |
const char * | GetKey (const int &KeyId) const |
int | GetKeyOfs (const int &KeyId) const |
const char * | KeyFromOfs (const int &KeyO) const |
bool | IsKey (const char *Key) const |
bool | IsKey (const TStr &Key) const |
bool | IsKey (const TChA &Key) const |
bool | IsKey (const char *Key, int &KeyId) const |
bool | IsKeyGetDat (const char *Key, TDat &Dat) const |
bool | IsKeyGetDat (const TStr &Key, TDat &Dat) const |
bool | IsKeyGetDat (const TChA &Key, TDat &Dat) const |
bool | IsKeyId (const int &KeyId) const |
int | FFirstKeyId () const |
bool | FNextKeyId (int &KeyId) const |
void | GetKeyV (TVec< TStr > &KeyV) const |
void | GetStrIdV (TIntV &StrIdV) const |
void | GetDatV (TVec< TDat > &DatV) const |
void | GetKeyDatPrV (TVec< TPair< TStr, TDat > > &KeyDatPrV) const |
void | GetDatKeyPrV (TVec< TPair< TDat, TStr > > &DatKeyPrV) const |
void | Pack () |
Private Types | |
typedef THashKeyDat< TInt, TDat > | THKeyDat |
typedef TPair< TInt, TDat > | TKeyDatP |
typedef TVec< THKeyDat > | THKeyDatV |
Private Member Functions | |
uint | GetNextPrime (const uint &Val) const |
void | Resize () |
const THKeyDat & | GetHashKeyDat (const int &KeyId) const |
THKeyDat & | GetHashKeyDat (const int &KeyId) |
Private Attributes | |
TIntV | PortV |
THKeyDatV | KeyDatV |
TBool | AutoSizeP |
TInt | FFreeKeyId |
TInt | FreeKeys |
PStringPool | Pool |
typedef TPt<TStringPool> TStrHash< TDat, TStringPool, THashFunc >::PStringPool |
|
private |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 757 of file hash.h.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
int TStrHash< TDat, TStringPool, THashFunc >::AddKey | ( | const char * | Key | ) |
|
inline |
|
inline |
|
inline |
|
inline |
bool TStrHash< TDat, TStringPool, THashFunc >::FNextKeyId | ( | int & | KeyId | ) | const |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
void TStrHash< TDat, TStringPool, THashFunc >::GetDatKeyPrV | ( | TVec< TPair< TDat, TStr > > & | DatKeyPrV | ) | const |
Definition at line 974 of file hash.h.
void TStrHash< TDat, TStringPool, THashFunc >::GetDatV | ( | TVec< TDat > & | DatV | ) | const |
Definition at line 955 of file hash.h.
|
inlineprivate |
|
inlineprivate |
|
inline |
Definition at line 821 of file hash.h.
|
inline |
Definition at line 814 of file hash.h.
|
inline |
Definition at line 815 of file hash.h.
|
inline |
Definition at line 816 of file hash.h.
|
inline |
Definition at line 817 of file hash.h.
void TStrHash< TDat, TStringPool, THashFunc >::GetKeyDatPrV | ( | TVec< TPair< TStr, TDat > > & | KeyDatPrV | ) | const |
Definition at line 963 of file hash.h.
int TStrHash< TDat, TStringPool, THashFunc >::GetKeyId | ( | const char * | Key | ) | const |
|
inline |
|
inline |
Definition at line 822 of file hash.h.
void TStrHash< TDat, TStringPool, THashFunc >::GetKeyV | ( | TVec< TStr > & | KeyV | ) | const |
|
inline |
|
inline |
|
private |
Definition at line 847 of file hash.h.
|
inline |
|
inline |
void TStrHash< TDat, TStringPool, THashFunc >::GetStrIdV | ( | TIntV & | StrIdV | ) | const |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
TStrHash< TDat, TStringPool, THashFunc > & TStrHash< TDat, TStringPool, THashFunc >::operator= | ( | const TStrHash< TDat, TStringPool, THashFunc > & | Hash | ) |
|
inline |
Definition at line 790 of file hash.h.
|
inline |
Definition at line 791 of file hash.h.
|
inline |
|
inline |
|
private |
Definition at line 859 of file hash.h.
|
inline |
|
inline |
|
private |