
Own fork of MbedSmartRestMain
Dependencies: C027_Support C12832 LM75B MMA7660 MbedSmartRest mbed-rtos mbed
Fork of MbedSmartRestMain by
Diff: operation/OperationExecutor.cpp
- Revision:
- 62:86a04c5bda18
- Child:
- 63:010bbbb4732a
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/operation/OperationExecutor.cpp Wed Oct 29 21:09:29 2014 +0000 @@ -0,0 +1,30 @@ +#include "OperationExecutor.h" +#include "ComposedRecord.h" +#include "CharValue.h" +#include "IntegerValue.h" + +OperationExecutor::OperationExecutor(AbstractSmartRest& client, SmartRestTemplate& tpl, long& deviceId) : + _client(client), + _tpl(tpl), + _deviceId(deviceId) +{ + _init = false; +} + +bool OperationExecutor::init() +{ + if (_init) + return false; + + // Get operation + // USAGE: 110,<OPERATION/ID>,<STATE> + if (!_tpl.add("10,112,GET,/devicecontrol/operations/%%,,application/vnd.com.nsn.cumulocity.operation+json,%%,UNSIGNED,\r\n")) + return false; + + _init = true; + return true; +} + +bool OperationExecutor::executeOperation(OperationStore::Operation& op) +{ +}