![]() |
LIMA
Libre Multilingual Analyzer — C++ API
|
Provide tools to manage a specific property. More...
#include <linguisticProcessing/common/PropertyCode/PropertyManager.h>
Public Member Functions | |
| PropertyManager (const std::string &name, const LinguisticCode &mask, const LinguisticCode &emptyNessMask, const std::map< std::string, LinguisticCode > symbol2code) | |
| constructor | |
| ~PropertyManager () | |
| PropertyManager (const PropertyManager &) | |
| PropertyManager & | operator= (const PropertyManager &) |
| const PropertyAccessor & | getPropertyAccessor () const |
| give the corresponding PropertyAccessor | |
| LinguisticCode | getMask () const |
| Get the property mask. | |
| LinguisticCode | getEmptyNessMask () const |
| The emptyNessMask is the mask use to check if property is empty. | |
| LinguisticCode | getPropertyValue (const std::string &symbolicValue) const |
| Get the coded property value from the symbolic value. | |
| const std::string & | getPropertySymbolicValue (const LinguisticCode &value) const |
| The coded property value can hold several property data. | |
| const std::map< LinguisticCode, std::string > & | getCode2Symbol () const |
| Get the Code -> Symbol mapping. | |
| const std::map< std::string, LinguisticCode > & | getSymbol2Code () const |
| Get the Symbol -> Code mapping. | |
| size_t | getNbValues () const |
| give the number of values for this property | |
Friends | |
| class | PropertyManagerPrivate |
Provide tools to manage a specific property.
The PropertyManager provide the PropertyAccessor for read/write operation. It also offers convertion function from symbolic values to numeric values.
Holds data about coding of a specific Property
Definition at line 33 of file PropertyManager.h.
| Lima::Common::PropertyCode::PropertyManager::PropertyManager | ( | const std::string & | name, |
| const LinguisticCode & | mask, | ||
| const LinguisticCode & | emptyNessMask, | ||
| const std::map< std::string, LinguisticCode > | symbol2code | ||
| ) |
constructor
| name | Name of the property |
| mask | Mask of the property |
| emptyMask | Mask for emptyness of the property |
| symbol2code | Mapping from symbolicValues to values for this properties |
Definition at line 96 of file PropertyManager.cpp.
| Lima::Common::PropertyCode::PropertyManager::~PropertyManager | ( | ) |
Definition at line 104 of file PropertyManager.cpp.
| Lima::Common::PropertyCode::PropertyManager::PropertyManager | ( | const PropertyManager & | pm | ) |
Definition at line 108 of file PropertyManager.cpp.
| const std::map< LinguisticCode, std::string > & Lima::Common::PropertyCode::PropertyManager::getCode2Symbol | ( | ) | const |
Get the Code -> Symbol mapping.
Definition at line 163 of file PropertyManager.cpp.
| LinguisticCode Lima::Common::PropertyCode::PropertyManager::getEmptyNessMask | ( | ) | const |
The emptyNessMask is the mask use to check if property is empty.
In the case of a 'property', emptyNessMask and mask are the same. But in the case of a 'subproperty', emptyNessMask is the part of the mask used to code the subproperty itself, so the mask is the union of emptyNessMask and parent property mask.
Get the property emptyness mask
Definition at line 158 of file PropertyManager.cpp.
| LinguisticCode Lima::Common::PropertyCode::PropertyManager::getMask | ( | ) | const |
| size_t Lima::Common::PropertyCode::PropertyManager::getNbValues | ( | ) | const |
give the number of values for this property
Definition at line 173 of file PropertyManager.cpp.
| const PropertyAccessor & Lima::Common::PropertyCode::PropertyManager::getPropertyAccessor | ( | ) | const |
give the corresponding PropertyAccessor
Definition at line 120 of file PropertyManager.cpp.
| const std::string & Lima::Common::PropertyCode::PropertyManager::getPropertySymbolicValue | ( | const LinguisticCode & | value | ) | const |
The coded property value can hold several property data.
Get the symbolic value for a coded property value
| value | coded property value. This coded value can code several properties. |
Definition at line 138 of file PropertyManager.cpp.
| LinguisticCode Lima::Common::PropertyCode::PropertyManager::getPropertyValue | ( | const std::string & | symbolicValue | ) | const |
Get the coded property value from the symbolic value.
| symbolicValue | symbolic value |
Definition at line 125 of file PropertyManager.cpp.
| const std::map< std::string, LinguisticCode > & Lima::Common::PropertyCode::PropertyManager::getSymbol2Code | ( | ) | const |
Get the Symbol -> Code mapping.
Definition at line 168 of file PropertyManager.cpp.
| PropertyManager & Lima::Common::PropertyCode::PropertyManager::operator= | ( | const PropertyManager & | pm | ) |
Definition at line 113 of file PropertyManager.cpp.
|
friend |
Definition at line 35 of file PropertyManager.h.