#include <ulxr_value.h>
Inheritance diagram for ulxr::Boolean:
Public Member Functions | |
Boolean () | |
Default constructor for a Boolean. | |
Boolean (bool b) | |
Constructs a Boolean. | |
Boolean (const CppString &s) | |
Constructs a Boolean. | |
virtual | ~Boolean () |
Destroys the Value. | |
bool | getBoolean () const |
Returns the current value. | |
void | setBoolean (const bool newval) |
Sets the current value. | |
virtual ValueBase * | cloneValue () const |
Creates a copy of the actual object. | |
virtual CppString | getSignature (bool deep=false) const |
Returns the signature of value. | |
virtual std::string | getWbXml () const |
Returns the call as binary xml string. | |
virtual CppString | getXml (int indent=0) const |
Returns the value as xml string. | |
Static Public Member Functions | |
static CppString | getValueName () |
Returns the xml name of the Value. | |
Private Attributes | |
bool | val |
Boolean values can either be "true" or "false".
Definition at line 572 of file ulxr_value.h.
ulxr::Boolean::Boolean | ( | ) |
ulxr::Boolean::Boolean | ( | bool | b | ) |
Constructs a Boolean.
b | value for the construction |
Definition at line 607 of file ulxr_value.cpp.
ulxr::Boolean::Boolean | ( | const CppString & | s | ) |
Constructs a Boolean.
s | value as string (true, on and 1 count as TRUE) |
Definition at line 618 of file ulxr_value.cpp.
References ULXR_PCHAR, and val.
ulxr::Boolean::~Boolean | ( | ) | [virtual] |
bool ulxr::Boolean::getBoolean | ( | ) | const |
Returns the current value.
Definition at line 684 of file ulxr_value.cpp.
References ulxr::RpcBoolean, and ULXR_ASSERT_RPCTYPE.
void ulxr::Boolean::setBoolean | ( | const bool | newval | ) |
Sets the current value.
newval | new value |
Definition at line 691 of file ulxr_value.cpp.
References ulxr::RpcBoolean, and ULXR_ASSERT_RPCTYPE.
ValueBase * ulxr::Boolean::cloneValue | ( | ) | const [virtual] |
Creates a copy of the actual object.
Implements ulxr::ValueBase.
Definition at line 629 of file ulxr_value.cpp.
References ulxr::RpcBoolean, and ULXR_ASSERT_RPCTYPE.
CppString ulxr::Boolean::getSignature | ( | bool | deep = false |
) | const [virtual] |
Returns the signature of value.
The signature consists of its type name.
deep | if nested types exist, include them |
Implements ulxr::ValueBase.
Definition at line 636 of file ulxr_value.cpp.
References ulxr::RpcBoolean, and ULXR_ASSERT_RPCTYPE.
CppString ulxr::Boolean::getValueName | ( | ) | [static] |
Returns the xml name of the Value.
Definition at line 643 of file ulxr_value.cpp.
References ULXR_PCHAR.
std::string ulxr::Boolean::getWbXml | ( | ) | const [virtual] |
Returns the call as binary xml string.
The method call is converted to a wbxml sequence. It is prepended with the necessary xml procession instruction with version and encoding set to UTF-8.
Implements ulxr::ValueBase.
Definition at line 649 of file ulxr_value.cpp.
References ulxr::getWbXmlString(), ulxr::RpcBoolean, ULXR_ASSERT_RPCTYPE, ULXR_PCHAR, ulxr::ValueParserWb::wbToken_Boolean, ulxr::ValueParserWb::wbToken_Value, and ulxr::WbXmlParser::wbxml_END.
CppString ulxr::Boolean::getXml | ( | int | indent = 0 |
) | const [virtual] |
Returns the value as xml string.
The content and its type name is converted to an xml text. The structure of the text is indented to facilitate easy reading of larger blocks.
indent | current indentation level |
Implements ulxr::ValueBase.
Definition at line 668 of file ulxr_value.cpp.
References ulxr::getXmlIndent(), ulxr::RpcBoolean, ULXR_ASSERT_RPCTYPE, and ULXR_PCHAR.
bool ulxr::Boolean::val [private] |