Page tree
Skip to end of metadata
Go to start of metadata

FB::TypeIDMap< IDTYPE > Class Template Reference

Bidirectional map between an identifier and a variant. More...

#include "TypeIDMap.h"

Public Member Functions

 TypeIDMap (IDTYPE startValue)
 Constructor. More...
void setIdForValue (IDTYPE idt, const variant &val)
 Sets an identifier for value. More...
IDTYPE getIdForValue (const variant &val)
 Gets the identifier assigned to the given value; if none is yet assigned, assigns a sequential identifier to the provided value. More...
const std::type_info & idGetType (IDTYPE idt)
 Returns the type of the value the given identifier is assigned to. More...
bool idExists (IDTYPE idt)
 Queries if a given identifier has been assigned to anything. More...
template<class T >
bool idIsType (IDTYPE idt)
 Queries if the provided identifier is assigned to a value of the given type. More...
template<class T >
getValueForId (IDTYPE idt)
 Gets the value assigned to the identifier. More...

Protected Types

typedef std::map< IDTYPE,
FB::variant, compare_numerics > 
 Defines an alias representing the map from the id type to a variant. More...
typedef std::map< FB::variant,
IDTYPE, compare_variants > 
 Defines an alias representing the map from a variant to the id. More...

Detailed Description

template<class IDTYPE>
class FB::TypeIDMap< IDTYPE >

Bidirectional map between an identifier and a variant.

Definition at line 33 of file TypeIDMap.h.

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