Main Page | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

shashtbl.hpp File Reference


Detailed Description

Hash tables.

This file invents S-expressions which act as hash tables, with both the key and the value being S-expressions themselves. See the SExpressionHashTable class description. In case you need something like a container, you might want to use the SHashTable class.

Definition in file shashtbl.hpp.

#include "sexpress.hpp"
#include "iexcept.hpp"
#include "gensref.hpp"

Include dependency graph for shashtbl.hpp:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef unsigned long intelib_hash_t
 The type the hash functions are to return.
typedef bool(* SEqualityPredicate )(SReference, SReference)
 Type definition for equality predicate.
typedef GenericSReference<
SExpressionHashTable, IntelibX_not_a_hash_table
SHashTableRef
 Reference to a SExpressionHashTable.

Functions

intelib_hash_t UniversalHash (intelib_hash_t l)
 Generic hash function (for an integer value).
intelib_hash_t LispHash (const SReference &ref)
 Hash function for an arbitry S-expression.
bool SExprsAreEq (SReference l1, SReference l2)
 Equality predicate 'EQ' (pointer comparision).
bool SExprsAreEql (SReference l1, SReference l2)
 Equality predicate 'EQL'.
bool SExprsAreEqual (SReference l1, SReference l2)
 Equality predicate 'EQUAL' (recursive).


Typedef Documentation

typedef unsigned long intelib_hash_t
 

The type the hash functions are to return.

Definition at line 35 of file shashtbl.hpp.

typedef bool(* SEqualityPredicate)(SReference, SReference)
 

Type definition for equality predicate.

Definition at line 43 of file shashtbl.hpp.

typedef GenericSReference<SExpressionHashTable,IntelibX_not_a_hash_table> SHashTableRef
 

Reference to a SExpressionHashTable.

Definition at line 170 of file shashtbl.hpp.


Function Documentation

intelib_hash_t UniversalHash intelib_hash_t  l  ) 
 

Generic hash function (for an integer value).

Definition at line 61 of file shashtbl.cpp.

Referenced by LispHash().

intelib_hash_t LispHash const SReference ref  ) 
 

Hash function for an arbitry S-expression.

Definition at line 95 of file shashtbl.cpp.

References UniversalHash().

Referenced by SExpressionHashTable::FindItem(), SExpressionHashTable::GetItemPosition(), and SExpressionHashTable::RemoveItem().

bool SExprsAreEq SReference  l1,
SReference  l2
 

Equality predicate 'EQ' (pointer comparision).

Definition at line 102 of file shashtbl.cpp.

Referenced by SExpressionHashTable::TextRepresentation().

bool SExprsAreEql SReference  l1,
SReference  l2
 

Equality predicate 'EQL'.

Definition at line 104 of file shashtbl.cpp.

References SReference::IsEql().

Referenced by SExpressionHashTable::TextRepresentation().

bool SExprsAreEqual SReference  l1,
SReference  l2
 

Equality predicate 'EQUAL' (recursive).

Definition at line 106 of file shashtbl.cpp.

References SReference::IsEqual().

Referenced by SExpressionHashTable::SExpressionHashTable(), and SExpressionHashTable::TextRepresentation().


Generated on Tue Dec 18 00:40:25 2007 for InteLib by  doxygen 1.4.1