ASCO Aerial Autonomy
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
TypeMap< GenericObjectT > Class Template Reference

Store objects with a common base class. More...

#include <type_map.h>

Public Member Functions

template<class ObjectT >
void setObject (ObjectT &object)
 Store the object with base class as GenericObjectT. More...
 
template<class ObjectT >
ObjectT * getObject ()
 return the object stored More...
 
template<class ObjectT >
const ObjectT * getObject () const
 return a const oject pointer stored More...
 

Detailed Description

template<class GenericObjectT>
class TypeMap< GenericObjectT >

Store objects with a common base class.

Template Parameters
GenericObjectTCommon base class for objects stored

Member Function Documentation

template<class GenericObjectT>
template<class ObjectT >
ObjectT* TypeMap< GenericObjectT >::getObject ( )
inline

return the object stored

Template Parameters
ObjectTtype of object to be retrieved.
Returns
pointer to the instance of the object.
template<class GenericObjectT>
template<class ObjectT >
const ObjectT* TypeMap< GenericObjectT >::getObject ( ) const
inline

return a const oject pointer stored

Template Parameters
ObjectTtype of object to be retrieved
Returns
const pointer to the instance of the object.
template<class GenericObjectT>
template<class ObjectT >
void TypeMap< GenericObjectT >::setObject ( ObjectT &  object)
inline

Store the object with base class as GenericObjectT.

Template Parameters
ObjectTThe type of object being stored. ObjectT should be base class of GenericObjectT
Parameters
objectThe address of an instance of ObjectT being stored

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