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

Class defining a Homegear device. More...

#include <HomegearDevice.h>

Classes

struct  ReceiveModes
 

Public Member Functions

 HomegearDevice (BaseLib::SharedObjects *baseLib)
 
 HomegearDevice (BaseLib::SharedObjects *baseLib, xml_node *node)
 
 HomegearDevice (BaseLib::SharedObjects *baseLib, std::string xmlFilename, bool &oldFormat)
 
 HomegearDevice (BaseLib::SharedObjects *baseLib, std::string xmlFilename, std::vector< char > &xml)
 
virtual ~HomegearDevice ()
 
bool loaded () const
 
void setPath (std::string &value)
 
std::string getPath ()
 
void setFilename (std::string &value)
 
std::string getFilename ()
 
int32_t getDynamicChannelCount ()
 
void setDynamicChannelCount (int32_t value)
 
PSupportedDevice getType (uint64_t typeNumber)
 
PSupportedDevice getType (uint64_t typeNumber, int32_t firmwareVersion)
 
void save (std::string &filename)
 

Public Attributes

int32_t dynamicChannelCountIndex = -1
 
double dynamicChannelCountSize = 1
 
int32_t version = 0
 
ReceiveModes::Enum receiveModes = ReceiveModes::none
 
bool encryption = false
 
uint32_t timeout = 0
 
uint32_t memorySize = 0
 
uint32_t memorySize2 = 0
 
bool visible = true
 
bool deletable = true
 
bool internal = false
 
bool needsTime = false
 
bool hasBattery = false
 
uint32_t addressSize = 0
 
std::string pairingMethod
 
std::string interface
 
SupportedDevices supportedDevices
 
PRunProgram runProgram
 
Functions functions
 
PVariable metadata
 
PacketsByMessageType packetsByMessageType
 
PacketsById packetsById
 
PacketsByFunction packetsByFunction1
 
PacketsByFunction packetsByFunction2
 
ValueRequestPackets valueRequestPackets
 
PHomegearDevice group
 

Protected Member Functions

void load (std::string xmlFilename, bool &oldFormat)
 
void load (std::string xmlFilename, std::vector< char > &xml)
 
void postProcessFunction (PFunction &function, std::map< std::string, PConfigParameters > &configParameters, std::map< std::string, PVariables > &variables, std::map< std::string, PLinkParameters > &linkParameters)
 
void parseXML (xml_node *node)
 
void postLoad ()
 
void saveDevice (xml_document *doc, xml_node *parentNode, HomegearDevice *device)
 
void saveFunction (xml_document *doc, xml_node *parentNode, PFunction &function, std::map< std::string, PConfigParameters > &configParameters, std::map< std::string, PVariables > &variables, std::map< std::string, PLinkParameters > &linkParameters)
 
void saveParameter (xml_document *doc, xml_node *parentNode, PParameter &parameter)
 
void saveScenario (xml_document *doc, xml_node *parentNode, PScenario &scenario)
 
void saveParameterPacket (xml_document *doc, xml_node *parentNode, std::shared_ptr< Parameter::Packet > &packet)
 

Protected Attributes

BaseLib::SharedObjects_bl = nullptr
 
bool _loaded = false
 
std::string _path
 
std::string _filename
 
int32_t _dynamicChannelCount = -1
 

Detailed Description

Class defining a Homegear device.

It is a direct representation of the device description XML file.

Constructor & Destructor Documentation

§ HomegearDevice() [1/4]

BaseLib::DeviceDescription::HomegearDevice::HomegearDevice ( BaseLib::SharedObjects baseLib)
explicit

§ HomegearDevice() [2/4]

BaseLib::DeviceDescription::HomegearDevice::HomegearDevice ( BaseLib::SharedObjects baseLib,
xml_node node 
)

§ HomegearDevice() [3/4]

BaseLib::DeviceDescription::HomegearDevice::HomegearDevice ( BaseLib::SharedObjects baseLib,
std::string  xmlFilename,
bool &  oldFormat 
)

§ HomegearDevice() [4/4]

BaseLib::DeviceDescription::HomegearDevice::HomegearDevice ( BaseLib::SharedObjects baseLib,
std::string  xmlFilename,
std::vector< char > &  xml 
)

§ ~HomegearDevice()

BaseLib::DeviceDescription::HomegearDevice::~HomegearDevice ( )
virtual

Member Function Documentation

§ getDynamicChannelCount()

int32_t BaseLib::DeviceDescription::HomegearDevice::getDynamicChannelCount ( )

§ getFilename()

std::string BaseLib::DeviceDescription::HomegearDevice::getFilename ( )

§ getPath()

std::string BaseLib::DeviceDescription::HomegearDevice::getPath ( )

§ getType() [1/2]

PSupportedDevice BaseLib::DeviceDescription::HomegearDevice::getType ( uint64_t  typeNumber)

§ getType() [2/2]

PSupportedDevice BaseLib::DeviceDescription::HomegearDevice::getType ( uint64_t  typeNumber,
int32_t  firmwareVersion 
)

§ load() [1/2]

void BaseLib::DeviceDescription::HomegearDevice::load ( std::string  xmlFilename,
bool &  oldFormat 
)
protected

§ load() [2/2]

void BaseLib::DeviceDescription::HomegearDevice::load ( std::string  xmlFilename,
std::vector< char > &  xml 
)
protected

§ loaded()

bool BaseLib::DeviceDescription::HomegearDevice::loaded ( ) const
inline

§ parseXML()

void BaseLib::DeviceDescription::HomegearDevice::parseXML ( xml_node node)
protected

§ postLoad()

void BaseLib::DeviceDescription::HomegearDevice::postLoad ( )
protected

§ postProcessFunction()

void BaseLib::DeviceDescription::HomegearDevice::postProcessFunction ( PFunction function,
std::map< std::string, PConfigParameters > &  configParameters,
std::map< std::string, PVariables > &  variables,
std::map< std::string, PLinkParameters > &  linkParameters 
)
protected

§ save()

void BaseLib::DeviceDescription::HomegearDevice::save ( std::string &  filename)

§ saveDevice()

void BaseLib::DeviceDescription::HomegearDevice::saveDevice ( xml_document doc,
xml_node parentNode,
HomegearDevice device 
)
protected

}}}

{{{ ParameterGroups

}}}

§ saveFunction()

void BaseLib::DeviceDescription::HomegearDevice::saveFunction ( xml_document doc,
xml_node parentNode,
PFunction function,
std::map< std::string, PConfigParameters > &  configParameters,
std::map< std::string, PVariables > &  variables,
std::map< std::string, PLinkParameters > &  linkParameters 
)
protected

§ saveParameter()

void BaseLib::DeviceDescription::HomegearDevice::saveParameter ( xml_document doc,
xml_node parentNode,
PParameter parameter 
)
protected

§ saveParameterPacket()

void BaseLib::DeviceDescription::HomegearDevice::saveParameterPacket ( xml_document doc,
xml_node parentNode,
std::shared_ptr< Parameter::Packet > &  packet 
)
protected

§ saveScenario()

void BaseLib::DeviceDescription::HomegearDevice::saveScenario ( xml_document doc,
xml_node parentNode,
PScenario scenario 
)
protected

§ setDynamicChannelCount()

void BaseLib::DeviceDescription::HomegearDevice::setDynamicChannelCount ( int32_t  value)

§ setFilename()

void BaseLib::DeviceDescription::HomegearDevice::setFilename ( std::string &  value)

§ setPath()

void BaseLib::DeviceDescription::HomegearDevice::setPath ( std::string &  value)

Member Data Documentation

§ _bl

BaseLib::SharedObjects* BaseLib::DeviceDescription::HomegearDevice::_bl = nullptr
protected

§ _dynamicChannelCount

int32_t BaseLib::DeviceDescription::HomegearDevice::_dynamicChannelCount = -1
protected

§ _filename

std::string BaseLib::DeviceDescription::HomegearDevice::_filename
protected

§ _loaded

bool BaseLib::DeviceDescription::HomegearDevice::_loaded = false
protected

§ _path

std::string BaseLib::DeviceDescription::HomegearDevice::_path
protected

§ addressSize

uint32_t BaseLib::DeviceDescription::HomegearDevice::addressSize = 0

§ deletable

bool BaseLib::DeviceDescription::HomegearDevice::deletable = true

§ dynamicChannelCountIndex

int32_t BaseLib::DeviceDescription::HomegearDevice::dynamicChannelCountIndex = -1

§ dynamicChannelCountSize

double BaseLib::DeviceDescription::HomegearDevice::dynamicChannelCountSize = 1

§ encryption

bool BaseLib::DeviceDescription::HomegearDevice::encryption = false

§ functions

Functions BaseLib::DeviceDescription::HomegearDevice::functions

§ group

PHomegearDevice BaseLib::DeviceDescription::HomegearDevice::group

§ hasBattery

bool BaseLib::DeviceDescription::HomegearDevice::hasBattery = false

§ interface

std::string BaseLib::DeviceDescription::HomegearDevice::interface

§ internal

bool BaseLib::DeviceDescription::HomegearDevice::internal = false

§ memorySize

uint32_t BaseLib::DeviceDescription::HomegearDevice::memorySize = 0

§ memorySize2

uint32_t BaseLib::DeviceDescription::HomegearDevice::memorySize2 = 0

§ metadata

PVariable BaseLib::DeviceDescription::HomegearDevice::metadata

§ needsTime

bool BaseLib::DeviceDescription::HomegearDevice::needsTime = false

§ packetsByFunction1

PacketsByFunction BaseLib::DeviceDescription::HomegearDevice::packetsByFunction1

§ packetsByFunction2

PacketsByFunction BaseLib::DeviceDescription::HomegearDevice::packetsByFunction2

§ packetsById

PacketsById BaseLib::DeviceDescription::HomegearDevice::packetsById

§ packetsByMessageType

PacketsByMessageType BaseLib::DeviceDescription::HomegearDevice::packetsByMessageType

§ pairingMethod

std::string BaseLib::DeviceDescription::HomegearDevice::pairingMethod

§ receiveModes

ReceiveModes::Enum BaseLib::DeviceDescription::HomegearDevice::receiveModes = ReceiveModes::none

§ runProgram

PRunProgram BaseLib::DeviceDescription::HomegearDevice::runProgram

§ supportedDevices

SupportedDevices BaseLib::DeviceDescription::HomegearDevice::supportedDevices

§ timeout

uint32_t BaseLib::DeviceDescription::HomegearDevice::timeout = 0

§ valueRequestPackets

ValueRequestPackets BaseLib::DeviceDescription::HomegearDevice::valueRequestPackets

§ version

int32_t BaseLib::DeviceDescription::HomegearDevice::version = 0

§ visible

bool BaseLib::DeviceDescription::HomegearDevice::visible = true

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