|
OpenStructure
|
#include <info_item.hh>
Public Member Functions | |
| InfoGroup | GetParent () const |
| String | GetName () const |
| void | SetName (const String &n) |
| String | GetValue () const |
| void | SetValue (const String &val) |
| Type | GetType () const |
| void | SetType (Type t) |
| void | SetType (int t) |
| Real | AsFloat () const |
| int | AsInt () const |
| bool | AsBool () const |
| geom::Vec3 | AsVector () const |
| void | SetFloat (Real d) |
| void | SetInt (int i) |
| void | SetBool (bool b) |
| void | SetVector (const geom::Vec3 &v) |
| String | GetAttribute (const String &name) const |
| void | SetAttribute (const String &name, const String &value) |
| bool | HasAttribute (const String &name) const |
| void | RemoveAttribute (const String &name) |
| std::vector< String > | GetAttributeList () const |
| bool | operator== (const InfoItem &rhs) const |
| bool | operator!= (const InfoItem &rhs) const |
Friends | |
| class | InfoGroup |
Definition at line 44 of file info_item.hh.
| bool AsBool | ( | ) | const |
return item value as boolean
| Real AsFloat | ( | ) | const |
return item value as floating point
| int AsInt | ( | ) | const |
return item value as integer
| geom::Vec3 AsVector | ( | ) | const |
return item value as 3d vector
| std::vector<String> GetAttributeList | ( | ) | const |
returns a list with all attribute names
| String GetName | ( | ) | const |
retrieve item name
| InfoGroup GetParent | ( | ) | const |
retrieve parent info group
| Type GetType | ( | ) | const |
retrieve type
type refers to the encoding of the item, which is one of STRING (default), INT, FLOAT, BOOL or VECTOR (see InfoItem::Type)
| String GetValue | ( | ) | const |
retrieve value of item
returns the String representation of the value
| bool HasAttribute | ( | const String & | name | ) | const |
returns true if attribute of this names exists
| bool operator!= | ( | const InfoItem & | rhs | ) | const |
| bool operator== | ( | const InfoItem & | rhs | ) | const |
| void RemoveAttribute | ( | const String & | name | ) |
remove attribute of given name
set attribute of given name, will be created if it does not yet exist
| void SetBool | ( | bool | b | ) |
set item value as bool
| void SetFloat | ( | Real | d | ) |
set item value as floating point
| void SetInt | ( | int | i | ) |
set item value as integer
| void SetName | ( | const String & | n | ) |
rename item
| void SetType | ( | Type | t | ) |
force type
| void SetType | ( | int | t | ) |
| void SetValue | ( | const String & | val | ) |
set value of item
this sets the value as a String
| void SetVector | ( | const geom::Vec3 & | v | ) |
set item value as 3d vector
|
friend |
Definition at line 45 of file info_item.hh.
1.8.1.1