|
void | Name (const std::string &name) |
| Sets the name attribute in an e-tag or a tree-tag.
|
|
const std::string & | Name () const |
| Returns the name attribute.
|
|
void | Description (const std::string &desc) |
| Optional attribute in an e-tag or tree-tag.
|
|
const std::string & | Description () const |
| Description text.
|
|
void | Unit (const std::string &unit) |
| Optional unit of the value in a nn e-tag..
|
|
const std::string & | Unit () const |
| Unit of value.
|
|
void | UnitRef (const std::string &unit_ref) |
| Reference unit.
|
|
const std::string & | UnitRef () const |
| Reference unit.
|
|
void | DataType (ETagDataType type) |
| Sets the data type.
|
|
ETagDataType | DataType () const |
| Retuns the data type.
|
|
void | Type (const std::string &type) |
| Data type of the value.
|
|
const std::string & | Type () const |
| Data type of the value.
|
|
void | Language (const std::string &language) |
| Language of the value.
|
|
const std::string & | Language () const |
| Language code.
|
|
void | ReadOnly (bool read_only) |
| The value is read-only.
|
|
bool | ReadOnly () const |
| Indicates that the value is read-only.
|
|
void | CreatorIndex (int index) |
| Index to FH block.
|
|
int | CreatorIndex () const |
| Index to file history block.
|
|
template<typename T > |
void | Value (const T &value) |
| Sets the value for an e-tag.
|
|
template<typename T > |
T | Value () const |
| Returns the tag value.
|
|
void | AddTag (const ETag &tag) |
| Adds a tag and define this to be a list of tags (tree).
|
|
const std::vector< ETag > & | TreeList () const |
| Return a list of tags.
|
|
template<> |
void | Value (const bool &value) |
| Specialization of setting boolean values.
|
|
template<> |
bool | Value () const |
| Specialization of getting a boolean value.
|
|
template<> |
std::string | Value () const |
| Specialization of getting a string value.
|
|
Most of meta data related items are stored in an associated MD block which is an XML snippet. The items are stored in 'e' and 'tree' tags.
The 'tree' tag is a list of 'e' tags and shall have a unique name attribute and optional description and creator index.
The e-tag shall have a unique name attribute and a value. The other attributes are optional.
void mdf::ETag::Type |
( |
const std::string & | type | ) |
|
|
inline |
The data type is default set to a string. Standard types are according to the XML standard primitive types. Standard types are 'string', 'decimal', 'integer', 'float', 'boolean', 'date', 'time' and 'dateTime'.
- Parameters
-