Darc Library
2012.11
|
Manager class to store, Read and Write single or array attributes. More...
#include <cr_attribute.h>
Public Member Functions | |
CR_AttributeManager () | |
CR_AttributeManager (UInt _nAttribute) | |
CR_AttributeManager (const CR_AttributeManager &_src) | |
~CR_AttributeManager () | |
CR_AttributeManager & | operator= (const CR_AttributeManager &_src) |
UInt | GetSize () const |
template<typename T > | |
void | SetValue (UInt _i, const T &_value) |
Template setter method. Creates, recreates or modifies a single attribute. | |
template<typename T > | |
const T * | GetValue (UInt _i) const |
Template getter method without type checking. | |
template<typename T , UInt N> | |
void | SetArray (UInt _i, const T *_value) |
Template setter method. Creates, recreates or modifies multiple attributes. | |
template<typename T , UInt N> | |
const T * | GetArray (UInt _i) const |
Template getter method without type checking. | |
template<typename T , UInt N> | |
const T * | GetArrayValue (UInt _i, UInt _j) const |
Template getter method without type checking. | |
CR_PIAttribute | GetAttribute (UInt _i) const |
DCR | Write (const char *_file) |
DCR | Read (const char *_file) |
UInt | GetNBytes () |
Returns the accumulated size of all attributes in bytes. | |
Friends | |
CR_API std::ostream & | operator<< (std::ostream &_o, const CR_AttributeManager &_obj) |
Manager class to store, Read and Write single or array attributes.
Attributes support arrays of values by default. For single values, use the respective getter and setter functions for N = 1.
darc::core::CR_AttributeManager::CR_AttributeManager | ( | ) | [inline] |
darc::core::CR_AttributeManager::CR_AttributeManager | ( | UInt | _nAttribute | ) | [inline] |
darc::core::CR_AttributeManager::CR_AttributeManager | ( | const CR_AttributeManager & | _src | ) | [inline] |
const T* darc::core::CR_AttributeManager::GetArray | ( | UInt | _i | ) | const [inline] |
Template getter method without type checking.
The function returns the pointer to the attribute array or NULL if it's undefined.
T | CR_Attribute_TN type. |
const T* darc::core::CR_AttributeManager::GetArrayValue | ( | UInt | _i, |
UInt | _j | ||
) | const [inline] |
Template getter method without type checking.
The function returns the pointer to the attribute array or NULL if it's undefined.
T | CR_Attribute_TN type. |
_i | CR_Attribute_TN index. |
_j | CR_Attribute_TN array index. |
CR_PIAttribute darc::core::CR_AttributeManager::GetAttribute | ( | UInt | _i | ) | const [inline] |
UInt darc::core::CR_AttributeManager::GetNBytes | ( | ) | [inline] |
Returns the accumulated size of all attributes in bytes.
UInt darc::core::CR_AttributeManager::GetSize | ( | ) | const [inline] |
const T* darc::core::CR_AttributeManager::GetValue | ( | UInt | _i | ) | const [inline] |
Template getter method without type checking.
The function returns the pointer to the attribute value or NULL if it's undefined.
T | CR_Attribute_TN type. |
CR_AttributeManager& darc::core::CR_AttributeManager::operator= | ( | const CR_AttributeManager & | _src | ) | [inline] |
Operator "Assignment".
DCR darc::core::CR_AttributeManager::Read | ( | const char * | _file | ) |
void darc::core::CR_AttributeManager::SetArray | ( | UInt | _i, |
const T * | _value | ||
) | [inline] |
Template setter method. Creates, recreates or modifies multiple attributes.
T | CR_Attribute_TN type. |
N | Number of attributes. |
void darc::core::CR_AttributeManager::SetValue | ( | UInt | _i, |
const T & | _value | ||
) | [inline] |
Template setter method. Creates, recreates or modifies a single attribute.
T | CR_Attribute_TN type. |
DCR darc::core::CR_AttributeManager::Write | ( | const char * | _file | ) |
CR_API std::ostream& operator<< | ( | std::ostream & | _o, |
const CR_AttributeManager & | _obj | ||
) | [friend] |