Open
Graph Drawing
Framework

 v. 2022.02 (Dogwood)
 

ogdf::HashElement< K, I > Class Template Reference

Representation of elements in a hash table. More...

#include <ogdf/basic/Hashing.h>

+ Inheritance diagram for ogdf::HashElement< K, I >:

Public Member Functions

 HashElement (size_t hashValue, const K &key, const I &info)
 Creates a hash element with given hash value, key, and information. More...
 
I & info ()
 Returns a refeence to the information value. More...
 
const I & info () const
 Returns the information value. More...
 
const K & key () const
 Returns the key value. More...
 
HashElement< K, I > * next () const
 Returns the successor element in the list. More...
 
- Public Member Functions inherited from ogdf::HashElementBase
 HashElementBase (size_t hashValue)
 Creates a hash element with hash value hashValue. More...
 
size_t hashValue () const
 Returns the hash value of this element. More...
 
HashElementBasenext () const
 Returns the successor to this element in the list. More...
 

Private Attributes

m_info
 The information value. More...
 
m_key
 The key value. More...
 

Detailed Description

template<class K, class I>
class ogdf::HashElement< K, I >

Representation of elements in a hash table.

This class adds key and information members to HashElementBase. The two template parameters are K for the type of keys and I for the type of information.

Definition at line 180 of file Hashing.h.

Constructor & Destructor Documentation

◆ HashElement()

template<class K , class I >
ogdf::HashElement< K, I >::HashElement ( size_t  hashValue,
const K &  key,
const I &  info 
)
inline

Creates a hash element with given hash value, key, and information.

Definition at line 187 of file Hashing.h.

Member Function Documentation

◆ info() [1/2]

template<class K , class I >
I& ogdf::HashElement< K, I >::info ( )
inline

Returns a refeence to the information value.

Definition at line 202 of file Hashing.h.

◆ info() [2/2]

template<class K , class I >
const I& ogdf::HashElement< K, I >::info ( ) const
inline

Returns the information value.

Definition at line 199 of file Hashing.h.

◆ key()

template<class K , class I >
const K& ogdf::HashElement< K, I >::key ( ) const
inline

Returns the key value.

Definition at line 196 of file Hashing.h.

◆ next()

template<class K , class I >
HashElement<K,I>* ogdf::HashElement< K, I >::next ( ) const
inline

Returns the successor element in the list.

Definition at line 191 of file Hashing.h.

Member Data Documentation

◆ m_info

template<class K , class I >
I ogdf::HashElement< K, I >::m_info
private

The information value.

Definition at line 183 of file Hashing.h.

◆ m_key

template<class K , class I >
K ogdf::HashElement< K, I >::m_key
private

The key value.

Definition at line 182 of file Hashing.h.


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