Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 803e3a95f9
Fetching contributors…

Cannot retrieve contributors at this time

1069 lines (924 sloc) 39.535 kb
// Automatically generated OpenZWave::Manager_server wrapper
// (c) 2011 Elias Karakoulakis <elias.karakoulakis@gmail.com>
#include "RemoteManager.h"
#include <thrift/protocol/TBinaryProtocol.h>
#include <thrift/server/TSimpleServer.h>
#include <thrift/transport/TServerSocket.h>
#include <thrift/transport/TBufferTransports.h>
using namespace ::apache::thrift;
using namespace ::apache::thrift::protocol;
using namespace ::apache::thrift::transport;
using namespace ::apache::thrift::server;
using boost::shared_ptr;
using namespace ::OpenZWave;
void BeginControllerCommand_callback(OpenZWave::Driver::ControllerState arg1, void* arg2) {
// FIXME: fill in the blanks (sorry!)
}
class RemoteManagerHandler : virtual public RemoteManagerIf {
public:
RemoteManagerHandler() {
// Your initialization goes here
}
void WriteConfig(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->WriteConfig((::uint32 const) _homeId);
g_criticalSection.unlock();
}
int8_t GetControllerNodeId(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetControllerNodeId((::uint32 const) _homeId);
g_criticalSection.unlock();
return(function_result);
}
bool IsPrimaryController(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsPrimaryController((::uint32 const) _homeId);
g_criticalSection.unlock();
return(function_result);
}
bool IsStaticUpdateController(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsStaticUpdateController((::uint32 const) _homeId);
g_criticalSection.unlock();
return(function_result);
}
bool IsBridgeController(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsBridgeController((::uint32 const) _homeId);
g_criticalSection.unlock();
return(function_result);
}
void GetLibraryVersion(std::string& _return, const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetLibraryVersion((::uint32 const) _homeId);
g_criticalSection.unlock();
}
void GetLibraryTypeName(std::string& _return, const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetLibraryTypeName((::uint32 const) _homeId);
g_criticalSection.unlock();
}
int32_t GetSendQueueCount(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int32_t function_result = mgr->GetSendQueueCount((::uint32 const) _homeId);
g_criticalSection.unlock();
return(function_result);
}
void LogDriverStatistics(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->LogDriverStatistics((::uint32 const) _homeId);
g_criticalSection.unlock();
}
int32_t GetPollInterval() {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int32_t function_result = mgr->GetPollInterval();
g_criticalSection.unlock();
return(function_result);
}
void SetPollInterval(const int32_t _milliseconds, const bool _bIntervalBetweenPolls) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetPollInterval((::int32) _milliseconds, (bool) _bIntervalBetweenPolls);
g_criticalSection.unlock();
}
bool EnablePoll(const RemoteValueID& _valueId, const int8_t _intensity) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->EnablePoll(_valueId.toValueID(), (::uint8 const) _intensity);
g_criticalSection.unlock();
return(function_result);
}
bool DisablePoll(const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->DisablePoll(_valueId.toValueID());
g_criticalSection.unlock();
return(function_result);
}
bool isPolled(const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->isPolled(_valueId.toValueID());
g_criticalSection.unlock();
return(function_result);
}
void SetPollIntensity(const RemoteValueID& _valueId, const int8_t _intensity) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetPollIntensity(_valueId.toValueID(), (::uint8 const) _intensity);
g_criticalSection.unlock();
}
bool RefreshNodeInfo(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->RefreshNodeInfo((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
bool RequestNodeState(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->RequestNodeState((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
bool RequestNodeDynamic(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->RequestNodeDynamic((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
bool IsNodeListeningDevice(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsNodeListeningDevice((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
bool IsNodeFrequentListeningDevice(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsNodeFrequentListeningDevice((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
bool IsNodeBeamingDevice(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsNodeBeamingDevice((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
bool IsNodeRoutingDevice(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsNodeRoutingDevice((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
bool IsNodeSecurityDevice(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsNodeSecurityDevice((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
int32_t GetNodeMaxBaudRate(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int32_t function_result = mgr->GetNodeMaxBaudRate((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
int8_t GetNodeVersion(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetNodeVersion((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
int8_t GetNodeSecurity(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetNodeSecurity((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
int8_t GetNodeBasic(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetNodeBasic((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
int8_t GetNodeGeneric(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetNodeGeneric((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
int8_t GetNodeSpecific(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetNodeSpecific((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
void GetNodeType(std::string& _return, const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetNodeType((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void GetNodeNeighbors(UInt32_ListByte& _return, const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetNodeNeighbors((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8**) &_return._nodeNeighbors);
g_criticalSection.unlock();
}
void GetNodeManufacturerName(std::string& _return, const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetNodeManufacturerName((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void GetNodeProductName(std::string& _return, const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetNodeProductName((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void GetNodeName(std::string& _return, const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetNodeName((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void GetNodeLocation(std::string& _return, const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetNodeLocation((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void GetNodeManufacturerId(std::string& _return, const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetNodeManufacturerId((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void GetNodeProductType(std::string& _return, const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetNodeProductType((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void GetNodeProductId(std::string& _return, const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetNodeProductId((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void SetNodeManufacturerName(const int32_t _homeId, const int8_t _nodeId, const std::string& _manufacturerName) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetNodeManufacturerName((::uint32 const) _homeId, (::uint8 const) _nodeId, (const std::string&) _manufacturerName);
g_criticalSection.unlock();
}
void SetNodeProductName(const int32_t _homeId, const int8_t _nodeId, const std::string& _productName) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetNodeProductName((::uint32 const) _homeId, (::uint8 const) _nodeId, (const std::string&) _productName);
g_criticalSection.unlock();
}
void SetNodeName(const int32_t _homeId, const int8_t _nodeId, const std::string& _nodeName) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetNodeName((::uint32 const) _homeId, (::uint8 const) _nodeId, (const std::string&) _nodeName);
g_criticalSection.unlock();
}
void SetNodeLocation(const int32_t _homeId, const int8_t _nodeId, const std::string& _location) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetNodeLocation((::uint32 const) _homeId, (::uint8 const) _nodeId, (const std::string&) _location);
g_criticalSection.unlock();
}
void SetNodeOn(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetNodeOn((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void SetNodeOff(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetNodeOff((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
void SetNodeLevel(const int32_t _homeId, const int8_t _nodeId, const int8_t _level) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetNodeLevel((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8 const) _level);
g_criticalSection.unlock();
}
bool IsNodeInfoReceived(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsNodeInfoReceived((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
void GetNodeClassInformation(Bool_GetNodeClassInformation& _return, const int32_t _homeId, const int8_t _nodeId, const int8_t _commandClassId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetNodeClassInformation((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8 const) _commandClassId, (std::string*) &_return._className, (::uint8*) &_return._classVersion);
g_criticalSection.unlock();
}
void GetValueLabel(std::string& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetValueLabel(_id.toValueID());
g_criticalSection.unlock();
}
void SetValueLabel(const RemoteValueID& _id, const std::string& _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetValueLabel(_id.toValueID(), (const std::string&) _value);
g_criticalSection.unlock();
}
void GetValueUnits(std::string& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetValueUnits(_id.toValueID());
g_criticalSection.unlock();
}
void SetValueUnits(const RemoteValueID& _id, const std::string& _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetValueUnits(_id.toValueID(), (const std::string&) _value);
g_criticalSection.unlock();
}
void GetValueHelp(std::string& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetValueHelp(_id.toValueID());
g_criticalSection.unlock();
}
void SetValueHelp(const RemoteValueID& _id, const std::string& _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetValueHelp(_id.toValueID(), (const std::string&) _value);
g_criticalSection.unlock();
}
int32_t GetValueMin(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int32_t function_result = mgr->GetValueMin(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
int32_t GetValueMax(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int32_t function_result = mgr->GetValueMax(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
bool IsValueReadOnly(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsValueReadOnly(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
bool IsValueWriteOnly(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsValueWriteOnly(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
bool IsValueSet(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsValueSet(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
bool IsValuePolled(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->IsValuePolled(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
void GetValueAsBool(Bool_Bool& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueAsBool(_id.toValueID(), (bool*) &_return.o_value);
g_criticalSection.unlock();
}
void GetValueAsByte(Bool_UInt8& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueAsByte(_id.toValueID(), (::uint8*) &_return.o_value);
g_criticalSection.unlock();
}
void GetValueAsFloat(Bool_Float& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueAsFloat(_id.toValueID(), (float*) &_return.o_value);
g_criticalSection.unlock();
}
void GetValueAsInt(Bool_Int& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueAsInt(_id.toValueID(), (::int32*) &_return.o_value);
g_criticalSection.unlock();
}
void GetValueAsShort(Bool_Int16& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueAsShort(_id.toValueID(), (::int16*) &_return.o_value);
g_criticalSection.unlock();
}
void GetValueAsString(Bool_String& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueAsString(_id.toValueID(), (std::string*) &_return.o_value);
g_criticalSection.unlock();
}
void GetValueListSelection_String(Bool_String& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueListSelection(_id.toValueID(), (std::string*) &_return.o_value);
g_criticalSection.unlock();
}
void GetValueListSelection_Int32(Bool_Int& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueListSelection(_id.toValueID(), (::int32*) &_return.o_value);
g_criticalSection.unlock();
}
void GetValueListItems(Bool_ListString& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueListItems(_id.toValueID(), (std::vector<std::string, std::allocator<std::string> >*) &_return.o_value);
g_criticalSection.unlock();
}
void GetValueFloatPrecision(Bool_UInt8& _return, const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetValueFloatPrecision(_id.toValueID(), (::uint8*) &_return.o_value);
g_criticalSection.unlock();
}
bool SetValue_Bool(const RemoteValueID& _id, const bool _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetValue(_id.toValueID(), (bool const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetValue_UInt8(const RemoteValueID& _id, const int8_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetValue(_id.toValueID(), (::uint8 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetValue_Float(const RemoteValueID& _id, const double _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetValue(_id.toValueID(), (float const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetValue_Int32(const RemoteValueID& _id, const int32_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetValue(_id.toValueID(), (::int32 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetValue_Int16(const RemoteValueID& _id, const int16_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetValue(_id.toValueID(), (::int16 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetValue_String(const RemoteValueID& _id, const std::string& _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetValue(_id.toValueID(), (const std::string&) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetValueListSelection(const RemoteValueID& _id, const std::string& _selectedItem) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetValueListSelection(_id.toValueID(), (const std::string&) _selectedItem);
g_criticalSection.unlock();
return(function_result);
}
bool RefreshValue(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->RefreshValue(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
void SetChangeVerified(const RemoteValueID& _id, const bool _verify) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetChangeVerified(_id.toValueID(), (bool) _verify);
g_criticalSection.unlock();
}
bool PressButton(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->PressButton(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
bool ReleaseButton(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->ReleaseButton(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
int8_t GetNumSwitchPoints(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetNumSwitchPoints(_id.toValueID());
g_criticalSection.unlock();
return(function_result);
}
bool SetSwitchPoint(const RemoteValueID& _id, const int8_t _hours, const int8_t _minutes, const int8_t _setback) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetSwitchPoint(_id.toValueID(), (::uint8 const) _hours, (::uint8 const) _minutes, (::int8 const) _setback);
g_criticalSection.unlock();
return(function_result);
}
bool RemoveSwitchPoint(const RemoteValueID& _id, const int8_t _hours, const int8_t _minutes) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->RemoveSwitchPoint(_id.toValueID(), (::uint8 const) _hours, (::uint8 const) _minutes);
g_criticalSection.unlock();
return(function_result);
}
void ClearSwitchPoints(const RemoteValueID& _id) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->ClearSwitchPoints(_id.toValueID());
g_criticalSection.unlock();
}
void GetSwitchPoint(GetSwitchPointReturnStruct& _return, const RemoteValueID& _id, const int8_t _idx) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetSwitchPoint(_id.toValueID(), (::uint8 const) _idx, (::uint8*) &_return.o_hours, (::uint8*) &_return.o_minutes, (::int8*) &_return.o_setback);
g_criticalSection.unlock();
}
void SwitchAllOn(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SwitchAllOn((::uint32 const) _homeId);
g_criticalSection.unlock();
}
void SwitchAllOff(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SwitchAllOff((::uint32 const) _homeId);
g_criticalSection.unlock();
}
bool SetConfigParam(const int32_t _homeId, const int8_t _nodeId, const int8_t _param, const int32_t _value, const int8_t _size) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetConfigParam((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8 const) _param, (::int32) _value, (::uint8 const) _size);
g_criticalSection.unlock();
return(function_result);
}
void RequestConfigParam(const int32_t _homeId, const int8_t _nodeId, const int8_t _param) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->RequestConfigParam((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8 const) _param);
g_criticalSection.unlock();
}
void RequestAllConfigParams(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->RequestAllConfigParams((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
}
int8_t GetNumGroups(const int32_t _homeId, const int8_t _nodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetNumGroups((::uint32 const) _homeId, (::uint8 const) _nodeId);
g_criticalSection.unlock();
return(function_result);
}
void GetAssociations(GetAssociationsReturnStruct& _return, const int32_t _homeId, const int8_t _nodeId, const int8_t _groupIdx) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetAssociations((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8 const) _groupIdx, (::uint8**) &_return.o_associations);
g_criticalSection.unlock();
}
int8_t GetMaxAssociations(const int32_t _homeId, const int8_t _nodeId, const int8_t _groupIdx) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetMaxAssociations((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8 const) _groupIdx);
g_criticalSection.unlock();
return(function_result);
}
void GetGroupLabel(std::string& _return, const int32_t _homeId, const int8_t _nodeId, const int8_t _groupIdx) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetGroupLabel((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8 const) _groupIdx);
g_criticalSection.unlock();
}
void AddAssociation(const int32_t _homeId, const int8_t _nodeId, const int8_t _groupIdx, const int8_t _targetNodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->AddAssociation((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8 const) _groupIdx, (::uint8 const) _targetNodeId);
g_criticalSection.unlock();
}
void RemoveAssociation(const int32_t _homeId, const int8_t _nodeId, const int8_t _groupIdx, const int8_t _targetNodeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->RemoveAssociation((::uint32 const) _homeId, (::uint8 const) _nodeId, (::uint8 const) _groupIdx, (::uint8 const) _targetNodeId);
g_criticalSection.unlock();
}
void ResetController(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->ResetController((::uint32 const) _homeId);
g_criticalSection.unlock();
}
void SoftReset(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SoftReset((::uint32 const) _homeId);
g_criticalSection.unlock();
}
bool BeginControllerCommand(const int32_t _homeId, const DriverControllerCommand::type _command, const bool _highPower, const int8_t _nodeId, const int8_t _arg) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->BeginControllerCommand((::uint32 const) _homeId, (OpenZWave::Driver::ControllerCommand) _command, &BeginControllerCommand_callback, (void*) this, (bool) _highPower, (::uint8) _nodeId, (::uint8) _arg);
g_criticalSection.unlock();
return(function_result);
}
bool CancelControllerCommand(const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->CancelControllerCommand((::uint32 const) _homeId);
g_criticalSection.unlock();
return(function_result);
}
int8_t GetNumScenes() {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->GetNumScenes();
g_criticalSection.unlock();
return(function_result);
}
void GetAllScenes(GetAllScenesReturnStruct& _return) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->GetAllScenes((::uint8**) &_return._sceneIds);
g_criticalSection.unlock();
}
int8_t CreateScene() {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
::int8_t function_result = mgr->CreateScene();
g_criticalSection.unlock();
return(function_result);
}
bool RemoveScene(const int8_t _sceneId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->RemoveScene((::uint8 const) _sceneId);
g_criticalSection.unlock();
return(function_result);
}
bool AddSceneValue_Bool(const int8_t _sceneId, const RemoteValueID& _valueId, const bool _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->AddSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (bool const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool AddSceneValue_Uint8(const int8_t _sceneId, const RemoteValueID& _valueId, const int8_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->AddSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (::uint8 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool AddSceneValue_Float(const int8_t _sceneId, const RemoteValueID& _valueId, const double _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->AddSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (float const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool AddSceneValue_Int32(const int8_t _sceneId, const RemoteValueID& _valueId, const int32_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->AddSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (::int32 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool AddSceneValue_Int16(const int8_t _sceneId, const RemoteValueID& _valueId, const int16_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->AddSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (::int16 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool AddSceneValue_String(const int8_t _sceneId, const RemoteValueID& _valueId, const std::string& _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->AddSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (const std::string&) _value);
g_criticalSection.unlock();
return(function_result);
}
bool AddSceneValueListSelection_String(const int8_t _sceneId, const RemoteValueID& _valueId, const std::string& _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->AddSceneValueListSelection((::uint8 const) _sceneId, _valueId.toValueID(), (const std::string&) _value);
g_criticalSection.unlock();
return(function_result);
}
bool AddSceneValueListSelection_Int32(const int8_t _sceneId, const RemoteValueID& _valueId, const int32_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->AddSceneValueListSelection((::uint8 const) _sceneId, _valueId.toValueID(), (::int32 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool RemoveSceneValue(const int8_t _sceneId, const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->RemoveSceneValue((::uint8 const) _sceneId, _valueId.toValueID());
g_criticalSection.unlock();
return(function_result);
}
void SceneGetValues(SceneGetValuesReturnStruct& _return, const int8_t _sceneId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->SceneGetValues((::uint8 const) _sceneId, _return.o_value.toValueID());
g_criticalSection.unlock();
}
void SceneGetValueAsBool(Bool_Bool& _return, const int8_t _sceneId, const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->SceneGetValueAsBool((::uint8 const) _sceneId, _valueId.toValueID(), (bool*) &_return.o_value);
g_criticalSection.unlock();
}
void SceneGetValueAsByte(Bool_UInt8& _return, const int8_t _sceneId, const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->SceneGetValueAsByte((::uint8 const) _sceneId, _valueId.toValueID(), (::uint8*) &_return.o_value);
g_criticalSection.unlock();
}
void SceneGetValueAsFloat(Bool_Float& _return, const int8_t _sceneId, const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->SceneGetValueAsFloat((::uint8 const) _sceneId, _valueId.toValueID(), (float*) &_return.o_value);
g_criticalSection.unlock();
}
void SceneGetValueAsInt(Bool_Int& _return, const int8_t _sceneId, const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->SceneGetValueAsInt((::uint8 const) _sceneId, _valueId.toValueID(), (::int32*) &_return.o_value);
g_criticalSection.unlock();
}
void SceneGetValueAsShort(Bool_Int16& _return, const int8_t _sceneId, const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->SceneGetValueAsShort((::uint8 const) _sceneId, _valueId.toValueID(), (::int16*) &_return.o_value);
g_criticalSection.unlock();
}
void SceneGetValueAsString(Bool_String& _return, const int8_t _sceneId, const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->SceneGetValueAsString((::uint8 const) _sceneId, _valueId.toValueID(), (std::string*) &_return.o_value);
g_criticalSection.unlock();
}
void SceneGetValueListSelection_String(Bool_String& _return, const int8_t _sceneId, const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->SceneGetValueListSelection((::uint8 const) _sceneId, _valueId.toValueID(), (std::string*) &_return.o_value);
g_criticalSection.unlock();
}
void SceneGetValueListSelection_Int32(Bool_Int& _return, const int8_t _sceneId, const RemoteValueID& _valueId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return.retval = mgr->SceneGetValueListSelection((::uint8 const) _sceneId, _valueId.toValueID(), (::int32*) &_return.o_value);
g_criticalSection.unlock();
}
bool SetSceneValue_Bool(const int8_t _sceneId, const RemoteValueID& _valueId, const bool _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (bool const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetSceneValue_Uint8(const int8_t _sceneId, const RemoteValueID& _valueId, const int8_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (::uint8 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetSceneValue_Float(const int8_t _sceneId, const RemoteValueID& _valueId, const double _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (float const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetSceneValue_Int32(const int8_t _sceneId, const RemoteValueID& _valueId, const int32_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (::int32 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetSceneValue_Int16(const int8_t _sceneId, const RemoteValueID& _valueId, const int16_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (::int16 const) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetSceneValue_String(const int8_t _sceneId, const RemoteValueID& _valueId, const std::string& _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetSceneValue((::uint8 const) _sceneId, _valueId.toValueID(), (const std::string&) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetSceneValueListSelection_String(const int8_t _sceneId, const RemoteValueID& _valueId, const std::string& _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetSceneValueListSelection((::uint8 const) _sceneId, _valueId.toValueID(), (const std::string&) _value);
g_criticalSection.unlock();
return(function_result);
}
bool SetSceneValueListSelection_Int32(const int8_t _sceneId, const RemoteValueID& _valueId, const int32_t _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SetSceneValueListSelection((::uint8 const) _sceneId, _valueId.toValueID(), (::int32 const) _value);
g_criticalSection.unlock();
return(function_result);
}
void GetSceneLabel(std::string& _return, const int8_t _sceneId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
_return = mgr->GetSceneLabel((::uint8 const) _sceneId);
g_criticalSection.unlock();
}
void SetSceneLabel(const int8_t _sceneId, const std::string& _value) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->SetSceneLabel((::uint8 const) _sceneId, (const std::string&) _value);
g_criticalSection.unlock();
}
bool SceneExists(const int8_t _sceneId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->SceneExists((::uint8 const) _sceneId);
g_criticalSection.unlock();
return(function_result);
}
bool ActivateScene(const int8_t _sceneId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
bool function_result = mgr->ActivateScene((::uint8 const) _sceneId);
g_criticalSection.unlock();
return(function_result);
}
void GetDriverStatistics(GetDriverStatisticsReturnStruct& _return, const int32_t _homeId) {
Manager* mgr = Manager::Get();
g_criticalSection.lock();
mgr->GetDriverStatistics((::uint32 const) _homeId, (OpenZWave::Driver::DriverData*) &_return._data);
g_criticalSection.unlock();
}
void SendAllValues() {
// Your implementation goes here
printf("SendAllValues\n");
}
void ping() {
// Your implementation goes here
printf("ping\n");
}
};
// int main(int argc, char **argv) {
// int port = 9090;
// shared_ptr<RemoteManagerHandler> handler(new RemoteManagerHandler());
// shared_ptr<TProcessor> processor(new RemoteManagerProcessor(handler));
// shared_ptr<TServerTransport> serverTransport(new TServerSocket(port));
// shared_ptr<TTransportFactory> transportFactory(new TBufferedTransportFactory());
// shared_ptr<TProtocolFactory> protocolFactory(new TBinaryProtocolFactory());
//
// TSimpleServer server(processor, serverTransport, transportFactory, protocolFactory);
// server.serve();
// return 0;
// }
//
//
Jump to Line
Something went wrong with that request. Please try again.