Elm  2
ELM is a library providing generic data structures, OS-independent interface, plugins and XML.
SelfHashKey< T > Class Template Reference

#include <elm/hash.h>

Public Member Functions

t::hash computeHash (const T &key) const
 
bool isEqual (const T &key1, const T &key2) const
 

Static Public Member Functions

static t::hash hash (const T &v)
 
static bool equals (const T &v1, const T &v2)
 

Detailed Description

template<class T>
class elm::SelfHashKey< T >

Simple hash key that looks in the object itself for the hash function and for the quality operator. The T must have the following methods:

  • t::hash hash(void);
  • bool operator==(const T& v);
Parameters
TType of hashed objects.

Member Function Documentation

◆ computeHash()

t::hash computeHash ( const T &  key) const
inline

◆ equals()

static bool equals ( const T &  v1,
const T &  v2 
)
inlinestatic

◆ hash()

static t::hash hash ( const T &  v)
inlinestatic

◆ isEqual()

bool isEqual ( const T &  key1,
const T &  key2 
) const
inline

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