ADTF  3.18.2
InfoMap

Info Map for the datamodel to hold a set of optional IInfo instances. More...

Inheritance diagram for InfoMap:
[legend]

Public Member Functions

 InfoMap ()=default
 CTOR.
 
 InfoMap (const InfoMap &)
 copy CTOR More...
 
 InfoMap (InfoMap &&)
 move CTOR More...
 
InfoMapoperator= (const InfoMap &)
 copy assignment operator More...
 
InfoMapoperator= (InfoMap &&)
 move assignment operator More...
 
template<typename INFO_T >
const INFO_T * getInfo () const
 Get the Info Pointer. More...
 
template<typename INFO_T >
INFO_T * getInfo ()
 Get the Info Pointer. More...
 
template<typename INFO_T >
void setInfo (const std::shared_ptr< INFO_T > &info)
 Set the Info object as shared pointer. More...
 

Private Member Functions

IInfogetInfo (uint8_t info_type)
 
const IInfogetInfo (uint8_t info_type) const
 
void setInfo (const std::shared_ptr< IInfo > &info)
 

Private Attributes

std::unordered_map< uint8_t, std::shared_ptr< IInfo > > _infos
 

Detailed Description

Info Map for the datamodel to hold a set of optional IInfo instances.

Only one instance of one Info type is possible.

Definition at line 75 of file infomodel_base.h.

Constructor & Destructor Documentation

◆ InfoMap() [1/2]

InfoMap ( const InfoMap )
inline

copy CTOR

Remarks
InfoMaps will be never copied!

Definition at line 85 of file infomodel_base.h.

◆ InfoMap() [2/2]

InfoMap ( InfoMap &&  )
inline

move CTOR

Remarks
InfoMaps will be never moved!

Definition at line 90 of file infomodel_base.h.

Member Function Documentation

◆ getInfo() [1/2]

INFO_T* getInfo ( )
inline

Get the Info Pointer.

Template Parameters
INFO_TThe Info type class type to retrieve.
Returns
INFO_T*

Definition at line 127 of file infomodel_base.h.

References InfoMap::getInfo().

◆ getInfo() [2/2]

const INFO_T* getInfo ( ) const
inline

Get the Info Pointer.

Template Parameters
INFO_TThe Info type class type to retrieve.
Returns
const INFO_T*

Definition at line 116 of file infomodel_base.h.

Referenced by InfoMap::getInfo().

◆ operator=() [1/2]

InfoMap& operator= ( const InfoMap )
inline

copy assignment operator

Remarks
InfoMaps will be never copied!
Returns
InfoMap&

Definition at line 96 of file infomodel_base.h.

◆ operator=() [2/2]

InfoMap& operator= ( InfoMap &&  )
inline

move assignment operator

Remarks
InfoMaps will be never moved!
Returns
InfoMap&

Definition at line 105 of file infomodel_base.h.

◆ setInfo()

void setInfo ( const std::shared_ptr< INFO_T > &  info)
inline

Set the Info object as shared pointer.

Template Parameters
INFO_TThe Info type class type to set.
Parameters
infothe info pointer to set.
Exceptions
ddl::dd::Errorif samething went wrong while setting the info.

Definition at line 139 of file infomodel_base.h.