Templated hashtable class.
More...
#include <Teuchos_Hashtable.hpp>
|
| | Hashtable (int capacity=101, double rehashDensity=0.8) |
| | Create an empty Hashtable. More...
|
| |
| bool | containsKey (const Key &key) const |
| | Check for the presence of a key. More...
|
| |
| const Value & | get (const Key &key) const |
| | Get the value indexed by key. More...
|
| |
| void | put (const Key &key, const Value &value) |
| | Put a new (key, value) pair in the table. More...
|
| |
| void | remove (const Key &key) |
| | Remove from the table the element given by key. More...
|
| |
| int | size () const |
| | Get the number of elements in the table. More...
|
| |
| void | arrayify (Array< Key > &keys, Array< Value > &values) const |
| | Get lists of keys and values in Array form. More...
|
| |
| double | avgDegeneracy () const |
| | Return the average degeneracy (average number of entries per hash code). More...
|
| |
| double | density () const |
| | Return the density of the hashtable (num entries / capacity) More...
|
| |
| void | setRehashDensity (double rehashDensity) |
| | Set the density at which to do a rehash. More...
|
| |
| std::string | toString () const |
| | Write to a std::string. More...
|
| |
|
(Note that these are not member functions.)
|
| template<class Key , class Value > |
| std::ostream & | operator<< (std::ostream &os, const Hashtable< Key, Value > &h) |
| | Write Hashtable to a stream. More...
|
| |
template<class Key, class Value>
class Teuchos::Hashtable< Key, Value >
Templated hashtable class.
- Author
- Kevin Long
Definition at line 80 of file Teuchos_Hashtable.hpp.
◆ Hashtable()
template<class Key , class Value >
◆ containsKey()
template<class Key , class Value >
◆ get()
template<class Key , class Value >
◆ put()
template<class Key , class Value >
◆ remove()
template<class Key , class Value >
◆ size()
template<class Key, class Value>
◆ arrayify()
template<class Key , class Value >
◆ avgDegeneracy()
template<class Key, class Value>
Return the average degeneracy (average number of entries per hash code).
Definition at line 106 of file Teuchos_Hashtable.hpp.
◆ density()
template<class Key, class Value>
◆ setRehashDensity()
template<class Key, class Value>
Set the density at which to do a rehash.
◆ toString()
template<class Key , class Value >
◆ rehash()
template<class Key , class Value >
◆ nextPrime()
template<class Key, class Value>
◆ accumulateAvgFill()
template<class Key , class Value >
◆ operator<<()
template<class Key , class Value >
| std::ostream & operator<< |
( |
std::ostream & |
os, |
|
|
const Hashtable< Key, Value > & |
h |
|
) |
| |
|
related |
◆ data_
template<class Key, class Value>
◆ count_
template<class Key, class Value>
◆ capacity_
template<class Key, class Value>
◆ mostRecentValue_
template<class Key, class Value>
◆ mostRecentKey_
template<class Key, class Value>
◆ nHits_
template<class Key, class Value>
◆ avgDegeneracy_
template<class Key, class Value>
◆ rehashDensity_
template<class Key, class Value>
The documentation for this class was generated from the following file: