Open
Graph Drawing
Framework

 v. 2023.09 (Elderberry)
 

Loading...
Searching...
No Matches
abacus::AbaHashItem< KeyType, ItemType > Class Template Reference

Items in hash tables. More...

#include <ogdf/lib/abacus/hash.h>

+ Inheritance diagram for abacus::AbaHashItem< KeyType, ItemType >:

Public Member Functions

 AbaHashItem (const KeyType &key, const ItemType &item)
 The constructor.
 
AbaHashItem< KeyType, ItemType > * next ()
 Returns a pointer to the next hash-item stored in the linked list corresponding to the slot of this item.
 
const AbaHashItem< KeyType, ItemType > * next () const
 Returns a const pointer to the next hash-item stored in the linked list corresponding to the slot of this item.
 
- Public Member Functions inherited from abacus::AbacusRoot
virtual ~AbacusRoot ()
 The destructor.
 

Private Attributes

ItemType item_
 
KeyType key_
 
AbaHashItem< KeyType, ItemType > * next_
 

Friends

class AbaHash< KeyType, ItemType >
 
std::ostream & operator<< (std::ostream &, const AbaHashItem< KeyType, ItemType > &)
 The output operator writes the key and the value of the item on the stream out.
 

Additional Inherited Members

- Static Public Member Functions inherited from abacus::AbacusRoot
static bool ascii2bool (const string &str)
 Converts the string str to a boolean value.
 
static bool endsWith (const string &str, const string &end)
 Returns true if str ends with end, false otherwise.
 
static double fracPart (double x)
 Returns the absolute value of the fractional part of x.
 
static const charonOff (bool value)
 Converts a boolean variable to the strings "on" and "off".
 

Detailed Description

template<class KeyType, class ItemType>
class abacus::AbaHashItem< KeyType, ItemType >

Items in hash tables.

Definition at line 57 of file hash.h.

Constructor & Destructor Documentation

◆ AbaHashItem()

template<class KeyType , class ItemType >
abacus::AbaHashItem< KeyType, ItemType >::AbaHashItem ( const KeyType key,
const ItemType item 
)

The constructor.

Parameters
keyThe key of the item.
itemThe value of the item.

Member Function Documentation

◆ next() [1/2]

Returns a pointer to the next hash-item stored in the linked list corresponding to the slot of this item.

◆ next() [2/2]

Returns a const pointer to the next hash-item stored in the linked list corresponding to the slot of this item.

Friends And Related Symbol Documentation

◆ AbaHash< KeyType, ItemType >

Definition at line 49 of file hash.h.

◆ operator<<

template<class KeyType , class ItemType >
std::ostream & operator<< ( std::ostream &  ,
const AbaHashItem< KeyType, ItemType > &   
)
friend

The output operator writes the key and the value of the item on the stream out.

Returns
A reference to the output stream.

Member Data Documentation

◆ item_

Definition at line 85 of file hash.h.

◆ key_

Definition at line 84 of file hash.h.

◆ next_

Definition at line 86 of file hash.h.


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