libhomegear-base  0.7
Base library for Homegear and Homegear family modules.
BaseLib::Variable Class Reference

#include <Variable.h>

Public Member Functions

 Variable ()
 
 Variable (Variable const &rhs)
 
 Variable (VariableType variableType)
 
 Variable (uint8_t integer)
 
 Variable (int32_t integer)
 
 Variable (uint32_t integer)
 
 Variable (int64_t integer)
 
 Variable (uint64_t integer)
 
 Variable (const std::string &string)
 
 Variable (const char *string)
 
 Variable (bool boolean)
 
 Variable (double floatVal)
 
 Variable (const PArray &arrayVal)
 
 Variable (const std::vector< std::string > &arrayVal)
 
 Variable (const PStruct &structVal)
 
 Variable (const std::vector< uint8_t > &binaryVal)
 
 Variable (const uint8_t *binaryVal, size_t binaryValSize)
 
 Variable (const std::vector< char > &binaryVal)
 
 Variable (const char *binaryVal, size_t binaryValSize)
 
 Variable (DeviceDescription::ILogical::Type::Enum variableType)
 
 Variable (const xml_node *node)
 
virtual ~Variable ()
 
std::string print (bool stdout=false, bool stderr=false, bool oneLine=false)
 
void trimStrings ()
 
void setType (VariableType value)
 
void setType (DeviceDescription::ILogical::Type::Enum value)
 
std::string toString ()
 
Variableoperator= (const Variable &rhs)
 
bool operator== (const Variable &rhs)
 
bool operator< (const Variable &rhs)
 
bool operator<= (const Variable &rhs)
 
bool operator> (const Variable &rhs)
 
bool operator>= (const Variable &rhs)
 
bool operator!= (const Variable &rhs)
 
 operator bool_type () const
 

Static Public Member Functions

static PVariable createError (int32_t faultCode, const std::string &faultString, bool retry=false)
 
static std::string getTypeString (VariableType type)
 
static PVariable fromString (std::string &value, DeviceDescription::ILogical::Type::Enum type)
 
static PVariable fromString (std::string &value, DeviceDescription::IPhysical::Type::Enum type)
 
static PVariable fromString (std::string &value, VariableType type)
 

Public Attributes

bool errorStruct = false
 
VariableType type
 
std::string stringValue
 
int32_t integerValue = 0
 
int64_t integerValue64 = 0
 
double floatValue = 0
 
bool booleanValue = false
 
PArray arrayValue
 
PStruct structValue
 
std::vector< uint8_t > binaryValue
 

Constructor & Destructor Documentation

§ Variable() [1/21]

BaseLib::Variable::Variable ( )

§ Variable() [2/21]

BaseLib::Variable::Variable ( Variable const &  rhs)

§ Variable() [3/21]

BaseLib::Variable::Variable ( VariableType  variableType)
explicit

§ Variable() [4/21]

BaseLib::Variable::Variable ( uint8_t  integer)
explicit

§ Variable() [5/21]

BaseLib::Variable::Variable ( int32_t  integer)
explicit

§ Variable() [6/21]

BaseLib::Variable::Variable ( uint32_t  integer)
explicit

§ Variable() [7/21]

BaseLib::Variable::Variable ( int64_t  integer)
explicit

§ Variable() [8/21]

BaseLib::Variable::Variable ( uint64_t  integer)
explicit

§ Variable() [9/21]

BaseLib::Variable::Variable ( const std::string &  string)
explicit

§ Variable() [10/21]

BaseLib::Variable::Variable ( const char *  string)
explicit

§ Variable() [11/21]

BaseLib::Variable::Variable ( bool  boolean)
explicit

§ Variable() [12/21]

BaseLib::Variable::Variable ( double  floatVal)
explicit

§ Variable() [13/21]

BaseLib::Variable::Variable ( const PArray arrayVal)
explicit

§ Variable() [14/21]

BaseLib::Variable::Variable ( const std::vector< std::string > &  arrayVal)
explicit

§ Variable() [15/21]

BaseLib::Variable::Variable ( const PStruct structVal)
explicit

§ Variable() [16/21]

BaseLib::Variable::Variable ( const std::vector< uint8_t > &  binaryVal)
explicit

§ Variable() [17/21]

BaseLib::Variable::Variable ( const uint8_t *  binaryVal,
size_t  binaryValSize 
)
explicit

§ Variable() [18/21]

BaseLib::Variable::Variable ( const std::vector< char > &  binaryVal)
explicit

§ Variable() [19/21]

BaseLib::Variable::Variable ( const char *  binaryVal,
size_t  binaryValSize 
)
explicit

§ Variable() [20/21]

BaseLib::Variable::Variable ( DeviceDescription::ILogical::Type::Enum  variableType)
explicit

§ Variable() [21/21]

BaseLib::Variable::Variable ( const xml_node node)
explicit

§ ~Variable()

BaseLib::Variable::~Variable ( )
virtual

Member Function Documentation

§ createError()

std::shared_ptr< Variable > BaseLib::Variable::createError ( int32_t  faultCode,
const std::string &  faultString,
bool  retry = false 
)
static

§ fromString() [1/3]

PVariable BaseLib::Variable::fromString ( std::string &  value,
DeviceDescription::ILogical::Type::Enum  type 
)
static

§ fromString() [2/3]

PVariable BaseLib::Variable::fromString ( std::string &  value,
DeviceDescription::IPhysical::Type::Enum  type 
)
static

§ fromString() [3/3]

PVariable BaseLib::Variable::fromString ( std::string &  value,
VariableType  type 
)
static

§ getTypeString()

std::string BaseLib::Variable::getTypeString ( VariableType  type)
static

§ operator bool_type()

BaseLib::Variable::operator bool_type ( ) const

§ operator!=()

bool BaseLib::Variable::operator!= ( const Variable rhs)

§ operator<()

bool BaseLib::Variable::operator< ( const Variable rhs)

§ operator<=()

bool BaseLib::Variable::operator<= ( const Variable rhs)

§ operator=()

Variable & BaseLib::Variable::operator= ( const Variable rhs)

§ operator==()

bool BaseLib::Variable::operator== ( const Variable rhs)

§ operator>()

bool BaseLib::Variable::operator> ( const Variable rhs)

§ operator>=()

bool BaseLib::Variable::operator>= ( const Variable rhs)

§ print()

std::string BaseLib::Variable::print ( bool  stdout = false,
bool  stderr = false,
bool  oneLine = false 
)

§ setType() [1/2]

void BaseLib::Variable::setType ( VariableType  value)
inline

§ setType() [2/2]

void BaseLib::Variable::setType ( DeviceDescription::ILogical::Type::Enum  value)

§ toString()

std::string BaseLib::Variable::toString ( )

§ trimStrings()

void BaseLib::Variable::trimStrings ( )

Member Data Documentation

§ arrayValue

PArray BaseLib::Variable::arrayValue

§ binaryValue

std::vector<uint8_t> BaseLib::Variable::binaryValue

§ booleanValue

bool BaseLib::Variable::booleanValue = false

§ errorStruct

bool BaseLib::Variable::errorStruct = false

§ floatValue

double BaseLib::Variable::floatValue = 0

§ integerValue

int32_t BaseLib::Variable::integerValue = 0

§ integerValue64

int64_t BaseLib::Variable::integerValue64 = 0

§ stringValue

std::string BaseLib::Variable::stringValue

§ structValue

PStruct BaseLib::Variable::structValue

§ type

VariableType BaseLib::Variable::type

The documentation for this class was generated from the following files: