Lightweight hash set class for storing ints Simple hash table with quadratic probing.
More...
#include <IntDoubleMap.h>
List of all members.
Detailed Description
Lightweight hash set class for storing ints Simple hash table with quadratic probing.
Constructor & Destructor Documentation
IntDoubleMap::IntDoubleMap
|
( |
int
|
capacity
) |
|
- Parameters:
-
[in] | capacity | Initial maximum size of hash set |
Member Function Documentation
bool IntDoubleMap::find
|
( |
int
|
x,
|
|
|
double *
|
y
|
|
) |
|
|
returns value of key x in table
- Returns:
- value of key, -1 if not in array
double IntDoubleMap::getHits
|
( |
) |
|
- Returns:
- total number of calls to find that hit
double IntDoubleMap::getMisses
|
( |
) |
|
- Returns:
- total number of calls to find that missed
int IntDoubleMap::getSize
|
( |
) |
|
returns the number of elements stored in hash table
- Returns:
- the number of elements stored in hash table
void IntDoubleMap::insert
|
( |
int
|
x,
|
|
|
double
|
y
|
|
) |
|
|
inserts x into hash table, returns whether x was inserted deletes least recently used element
- Parameters:
-
[in] | x | key to put into map |
[in] | y | value to insert into map |
The documentation for this class was generated from the following files: