gambit is hosted by Hepforge, IPPP Durham
GAMBIT  v1.5.0-252-gf9a3f78
a Global And Modular Bsm Inference Tool
Gambit::type_index Struct Reference

#include <type_index.hpp>

Public Member Functions

 type_index (const std::type_info &__rhs)
 
 type_index ()
 
const std::type_info & operator= (const std::type_info &__rhs)
 
bool operator== (const Gambit::type_index &__rhs) const
 
bool operator!= (const Gambit::type_index &__rhs) const
 
bool operator< (const Gambit::type_index &__rhs) const
 
bool operator<= (const Gambit::type_index &__rhs) const
 
bool operator> (const Gambit::type_index &__rhs) const
 
bool operator>= (const Gambit::type_index &__rhs) const
 
size_t hash_code () const
 
const char * name () const
 

Private Attributes

const std::type_info * _M_target
 

Friends

struct type_equal_to
 
struct std::equal_to< Gambit::type_index >
 

Detailed Description

Definition at line 26 of file type_index.hpp.

Constructor & Destructor Documentation

◆ type_index() [1/2]

Gambit::type_index::type_index ( const std::type_info &  __rhs)
inline

Definition at line 32 of file type_index.hpp.

33  : _M_target(&__rhs) { }
const std::type_info * _M_target
Definition: type_index.hpp:66

◆ type_index() [2/2]

Gambit::type_index::type_index ( )
inline

Definition at line 35 of file type_index.hpp.

35 {}

Member Function Documentation

◆ hash_code()

size_t Gambit::type_index::hash_code ( ) const
inline

Definition at line 58 of file type_index.hpp.

References _M_target.

Referenced by Gambit::type_hasher::operator()(), and std::hash< Gambit::type_index >::operator()().

60  { return std::hash<std::string>().operator()(_M_target->name()); }
const std::type_info * _M_target
Definition: type_index.hpp:66
Here is the caller graph for this function:

◆ name()

const char* Gambit::type_index::name ( ) const
inline

Definition at line 62 of file type_index.hpp.

References _M_target.

63  { return _M_target->name(); }
const std::type_info * _M_target
Definition: type_index.hpp:66

◆ operator!=()

bool Gambit::type_index::operator!= ( const Gambit::type_index __rhs) const
inline

Definition at line 43 of file type_index.hpp.

References _M_target.

44  { return *_M_target != *__rhs._M_target; }
const std::type_info * _M_target
Definition: type_index.hpp:66

◆ operator<()

bool Gambit::type_index::operator< ( const Gambit::type_index __rhs) const
inline

Definition at line 46 of file type_index.hpp.

References _M_target.

47  { return _M_target->before(*__rhs._M_target); }
const std::type_info * _M_target
Definition: type_index.hpp:66

◆ operator<=()

bool Gambit::type_index::operator<= ( const Gambit::type_index __rhs) const
inline

Definition at line 49 of file type_index.hpp.

References _M_target.

50  { return !__rhs._M_target->before(*_M_target); }
const std::type_info * _M_target
Definition: type_index.hpp:66

◆ operator=()

const std::type_info& Gambit::type_index::operator= ( const std::type_info &  __rhs)
inline

Definition at line 37 of file type_index.hpp.

References _M_target.

38  {return *(_M_target = &__rhs);}
const std::type_info * _M_target
Definition: type_index.hpp:66

◆ operator==()

bool Gambit::type_index::operator== ( const Gambit::type_index __rhs) const
inline

Definition at line 40 of file type_index.hpp.

References _M_target.

41  { return *_M_target == *__rhs._M_target; }
const std::type_info * _M_target
Definition: type_index.hpp:66

◆ operator>()

bool Gambit::type_index::operator> ( const Gambit::type_index __rhs) const
inline

Definition at line 52 of file type_index.hpp.

References _M_target.

53  { return __rhs._M_target->before(*_M_target); }
const std::type_info * _M_target
Definition: type_index.hpp:66

◆ operator>=()

bool Gambit::type_index::operator>= ( const Gambit::type_index __rhs) const
inline

Definition at line 55 of file type_index.hpp.

References _M_target.

56  { return !_M_target->before(*__rhs._M_target); }
const std::type_info * _M_target
Definition: type_index.hpp:66

Friends And Related Function Documentation

◆ std::equal_to< Gambit::type_index >

friend struct std::equal_to< Gambit::type_index >
friend

Definition at line 30 of file type_index.hpp.

◆ type_equal_to

friend struct type_equal_to
friend

Definition at line 29 of file type_index.hpp.

Member Data Documentation

◆ _M_target


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