Public Member Functions | Static Public Member Functions | Friends
CStringAttrTranslatorMap Class Reference

A singelton class to translate strings to attributes based on keys. More...

#include <mia/core/attributes.hh>

Public Member Functions

PAttribute to_attr (const std::string &key, const std::string &value) const
 

Static Public Member Functions

static CStringAttrTranslatorMapinstance ()
 

Friends

class CAttrTranslator
 

Detailed Description

A singelton class to translate strings to attributes based on keys.

This class provides a singleton to translate strings to attributes. For the translation to take place for each attribute key a CAttrTranslator needs to be registered first.

Definition at line 396 of file attributes.hh.

Member Function Documentation

static CStringAttrTranslatorMap& CStringAttrTranslatorMap::instance ( )
static
Returns
an instance to the translator map singleton
PAttribute CStringAttrTranslatorMap::to_attr ( const std::string &  key,
const std::string &  value 
) const

Converts the input string value to a PAttribute by using the translator that was registered for the given key.

Parameters
key
value
Returns
the respective attribute

Friends And Related Function Documentation

friend class CAttrTranslator
friend

Definition at line 410 of file attributes.hh.


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