RobinTrace
Public Member Functions | Private Attributes | List of all members
type_map< element_type > Class Template Reference

Map class storing unique_ptr to elements and keyed by their type. More...

#include <type_map.h>

Collaboration diagram for type_map< element_type >:
[legend]

Public Member Functions

template<typename T >
void add (const T &input)
 Add an element of a type derived from element_type.
 
template<typename T >
T & get ()
 Get a reference to an element of the map.
 

Private Attributes

std::unordered_map< std::type_index, std::unique_ptr< element_type > > table
 Map of type/pointers.
 

Detailed Description

template<class element_type>
class type_map< element_type >

Map class storing unique_ptr to elements and keyed by their type.


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