mirror of
https://github.com/Fishwaldo/qt-openzwave.git
synced 2025-07-07 13:48:19 +00:00
forgot these files
This commit is contained in:
parent
77f792cb00
commit
f8e01864d8
2 changed files with 32 additions and 0 deletions
15
qt-ozwdaemon/mqttcommands/close.cpp
Normal file
15
qt-ozwdaemon/mqttcommands/close.cpp
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
#include "mqttcommands/close.h"
|
||||||
|
|
||||||
|
MqttCommand_Close::MqttCommand_Close(QObject *parent) :
|
||||||
|
MqttCommand(parent)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
MqttCommand* MqttCommand_Close::Create(QObject *parent) {
|
||||||
|
return new MqttCommand_Close(parent);
|
||||||
|
}
|
||||||
|
|
||||||
|
bool MqttCommand_Close::processMessage(rapidjson::Document &msg) {
|
||||||
|
Q_UNUSED(msg);
|
||||||
|
QTOZWManager *mgr = getOZWManager();
|
||||||
|
return this->sendSimpleStatus(mgr->close());
|
||||||
|
}
|
17
qt-ozwdaemon/mqttcommands/close.h
Normal file
17
qt-ozwdaemon/mqttcommands/close.h
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
#ifndef CLOSE_H
|
||||||
|
#define CLOSE_H
|
||||||
|
|
||||||
|
#include "mqttcommands/mqttcommands.h"
|
||||||
|
|
||||||
|
class MqttCommand_Close : public MqttCommand {
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
static MqttCommand *Create(QObject *parent = nullptr);
|
||||||
|
static QString StaticGetCommand() { return "Close";};
|
||||||
|
QString GetCommand() override { return StaticGetCommand(); };
|
||||||
|
bool processMessage(rapidjson::Document &) override;
|
||||||
|
private:
|
||||||
|
MqttCommand_Close(QObject *parent = nullptr);
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // CLOSE_H
|
Loading…
Add table
Add a link
Reference in a new issue