A Discrete-Event Network Simulator
API
anonymous_namespace{length.cc}::EnumHash Class Reference

Functor for hashing Length::Unit values. More...

Public Member Functions

std::size_t operator() (ns3::Length::Unit u) const noexcept
 Produce a hash value for a Length::Unit. More...
 

Detailed Description

Functor for hashing Length::Unit values.

This classes exists as a work around for a C++11 defect. c++11 doesn't provide a std::hash implementation for enums

Definition at line 217 of file length.cc.

Member Function Documentation

◆ operator()()

std::size_t anonymous_namespace{length.cc}::EnumHash::operator() ( ns3::Length::Unit  u) const
inlinenoexcept

Produce a hash value for a Length::Unit.

Parameters
uLength::Unit to hash
Returns
Hash value for the Length::Unit

Definition at line 227 of file length.cc.


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