se_core::HashTable< T, poolSize > Class Template Reference

#include <HashTable.hpp>

List of all members.

Public Types

typedef int iterator_type

Public Member Functions

 HashTable ()
 HashTable (int size)
virtual ~HashTable ()
void initialize (int size=DEFAULT_HASH_TABLE_SIZE)
unsigned int hash (short key)
T * add (short key, T *data)
T * lookup (short key)
iterator_type lookupList (short key)
T * remove (short key)
iterator_type hashTable (int index)
NodeListnodeList ()
int tableSize ()
int count ()

Protected Types

enum  { DEFAULT_HASH_TABLE_SIZE = 16 }

Protected Member Functions

HashTableNodelookupNode (short key)

Protected Attributes

iterator_typehashTable_
int tableSize_
int count_

template<class T, int poolSize>
class se_core::HashTable< T, poolSize >


Member Typedef Documentation

template<class T, int poolSize>
typedef int se_core::HashTable< T, poolSize >::iterator_type
 

Definition at line 52 of file HashTable.hpp.


Member Enumeration Documentation

template<class T, int poolSize>
anonymous enum [protected]
 

Enumeration values:
DEFAULT_HASH_TABLE_SIZE 

Definition at line 32 of file HashTable.hpp.


Constructor & Destructor Documentation

template<class T, int poolSize>
se_core::HashTable< T, poolSize >::HashTable  )  [inline]
 

Definition at line 56 of file HashTable.hpp.

template<class T, int poolSize>
se_core::HashTable< T, poolSize >::HashTable int  size  )  [inline]
 

Definition at line 61 of file HashTable.hpp.

template<class T, int poolSize>
virtual se_core::HashTable< T, poolSize >::~HashTable  )  [inline, virtual]
 

Definition at line 71 of file HashTable.hpp.


Member Function Documentation

template<class T, int poolSize>
T* se_core::HashTable< T, poolSize >::add short  key,
T *  data
[inline]
 

Definition at line 107 of file HashTable.hpp.

References se_core::HashTable< T, poolSize >::HashTableNode::data_.

template<class T, int poolSize>
int se_core::HashTable< T, poolSize >::count  )  [inline]
 

Definition at line 180 of file HashTable.hpp.

template<class T, int poolSize>
unsigned int se_core::HashTable< T, poolSize >::hash short  key  )  [inline]
 

Definition at line 99 of file HashTable.hpp.

template<class T, int poolSize>
iterator_type se_core::HashTable< T, poolSize >::hashTable int  index  )  [inline]
 

Definition at line 164 of file HashTable.hpp.

template<class T, int poolSize>
void se_core::HashTable< T, poolSize >::initialize int  size = DEFAULT_HASH_TABLE_SIZE  )  [inline]
 

Definition at line 90 of file HashTable.hpp.

template<class T, int poolSize>
T* se_core::HashTable< T, poolSize >::lookup short  key  )  [inline]
 

Definition at line 119 of file HashTable.hpp.

References se_core::HashTable< T, poolSize >::HashTableNode::data_.

template<class T, int poolSize>
iterator_type se_core::HashTable< T, poolSize >::lookupList short  key  )  [inline]
 

Definition at line 134 of file HashTable.hpp.

template<class T, int poolSize>
HashTableNode* se_core::HashTable< T, poolSize >::lookupNode short  key  )  [inline, protected]
 

Definition at line 186 of file HashTable.hpp.

References se_core::HashTable< T, poolSize >::HashTableNode::key_, and se_core::SinglyLinkedList< ElementType, maxElements, xid >::next().

template<class T, int poolSize>
NodeList& se_core::HashTable< T, poolSize >::nodeList  )  [inline]
 

Definition at line 169 of file HashTable.hpp.

template<class T, int poolSize>
T* se_core::HashTable< T, poolSize >::remove short  key  )  [inline]
 

Definition at line 142 of file HashTable.hpp.

References se_core::HashTable< T, poolSize >::HashTableNode::data_, and se_core::HashTable< T, poolSize >::HashTableNode::key_.

template<class T, int poolSize>
int se_core::HashTable< T, poolSize >::tableSize  )  [inline]
 

Definition at line 175 of file HashTable.hpp.


Member Data Documentation

template<class T, int poolSize>
int se_core::HashTable< T, poolSize >::count_ [protected]
 

Definition at line 206 of file HashTable.hpp.

template<class T, int poolSize>
iterator_type* se_core::HashTable< T, poolSize >::hashTable_ [protected]
 

Definition at line 204 of file HashTable.hpp.

template<class T, int poolSize>
int se_core::HashTable< T, poolSize >::tableSize_ [protected]
 

Definition at line 205 of file HashTable.hpp.


The documentation for this class was generated from the following file:

Home Page | SagaEngine trunk (updated nightly) reference generated Sun Dec 2 20:06:30 2007 by Doxygen version 1.3.9.1.

SourceForge.net Logo