Leonardus
Loading...
Searching...
No Matches
Public Member Functions | List of all members
SOD::FunctorHash Struct Reference

Hash functor for SO* keys in SOD's unordered_map. More...

+ Collaboration diagram for SOD::FunctorHash:

Public Member Functions

size_t operator() (const SOp &p_key) const
 Computes the hash value for a given SO*.
 

Detailed Description

Hash functor for SO* keys in SOD's unordered_map.

Uses the name of SON objects for hashing (primary use case). For other SO types, falls back to hashing the OTCode.

Note
Designed for use with std::unordered_map<SOp, SOp, FunctorHash, FunctorEqual>.
Invariant
none.

Member Function Documentation

◆ operator()()

size_t SOD::FunctorHash::operator() ( const SOp &  p_key) const
inline

Computes the hash value for a given SO*.

Precondition
p_key != nullptr
Parameters
p_keyThe SO* to hash.
Returns
size_t ... The computed hash value.

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