![]() |
OpenNI 1.5.7
|
#include <XnHash.h>
Classes | |
class | ConstIterator |
class | Iterator |
Public Types | |
typedef XnHashValue(*) | XnHashFunction(const XnKey &key) |
typedef XnInt32(*) | XnCompareFunction(const XnKey &key1, const XnKey &key2) |
Public Member Functions | |
XnHash () | |
virtual | ~XnHash () |
XnStatus | GetInitStatus () const |
XnStatus | Set (const XnKey &key, const XnValue &value) |
XnStatus | Get (const XnKey &key, XnValue &value) const |
XnStatus | Remove (const XnKey &key, XnValue &value) |
XnStatus | Remove (ConstIterator iter, XnKey &key, XnValue &value) |
virtual XnStatus | Remove (ConstIterator iter) |
XnStatus | Clear () |
XnBool | IsEmpty () const |
XnUInt32 | Size () const |
XnStatus | Find (const XnKey &key, ConstIterator &hiter) const |
XnStatus | Find (const XnKey &key, Iterator &hiter) |
Iterator | begin () |
ConstIterator | begin () const |
Iterator | end () |
ConstIterator | end () const |
XnStatus | SetHashFunction (XnHashFunction hashFunction) |
XnStatus | SetCompareFunction (XnCompareFunction compareFunction) |
Protected Member Functions | |
XnStatus | Init () |
XnStatus | Find (const XnKey &key, XnHashValue hashValue, ConstIterator &hiter) const |
Protected Attributes | |
XnList ** | m_Bins |
XnUInt16 | m_nMinBin |
XnStatus | m_nInitStatus |
XnHashFunction | m_HashFunction |
XnCompareFunction | m_CompareFunction |
Friends | |
class | ConstIterator |
The hash - associative array
Definition of comparison function - receives 2 keys, returns 0 on equality
XnHashValue(*) XnHash::XnHashFunction(const XnKey &key) |
Definition of a hash function - receive key, and outputs HashValue
|
inline |
Constructor. Initializes internal representations.
|
inlinevirtual |
Destructor. Destroys internal representations.
|
inline |
Get an iterator to the beginning of the XnHash (non-const version)
|
inline |
Get an iterator to the beginning of the XnHash (const version)
|
inline |
Get an iterator to the end of the XnHash (position is invalid) (non-const version)
|
inline |
Get an iterator to the end of the XnHash (position is invalid) (const version)
|
inline |
|
inlineprotected |
Get the value associated with the supplied key
key | [in] The key of the entry |
value | [out] The retrieved value |
|
inline |
Returns the status of the initialization of the hash.
|
inlineprotected |
|
inline |
Checks if hash is empty.
Remove a key-value entry from the XnHash
key | [in] The key of the entry |
value | [out] The value that was in the removed entry |
|
inlinevirtual |
|
inline |
Set a new key-value entry. If key exists, will replace value.
key | [in] The key to which to associate the value |
value | [in] The value to add to the XnHash |
|
inline |
|
inline |
|
inline |
Gets the number of entries in the hash.
|
friend |
|
protected |
The current comparison function
|
protected |
The current hash function
|
protected |
|
protected |