fix typos as reported by Krazy2
This commit is contained in:
parent
2fec19e17d
commit
67a535619f
@ -43,7 +43,7 @@
|
||||
\list
|
||||
\li \b 1. | The main setup of the device in the plugin.
|
||||
\li \b 2. | If something goes wrong during the setup return \l{DeviceManager::DeviceSetupStatusFailure}, otherwise \l{DeviceManager::DeviceSetupStatusSuccess}.
|
||||
\li \b 3. | If the device setup succeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\li \b 3. | If the device setup succeeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\endlist
|
||||
\endlist
|
||||
|
||||
@ -57,7 +57,7 @@
|
||||
\li \b 1. | The main setup of the device in the plugin.
|
||||
\li \b 2. | If the status can not be determined immediately, we have to tell the \l{DeviceManager} that the status will be communicated later.
|
||||
\li \b 3. | Once the setup status is determined, the plugin can emit the signal \l{DevicePlugin::deviceSetupFinished} to inform the \l{DeviceManager} about the result.
|
||||
\li \b 4. | If the device setup succeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\li \b 4. | If the device setup succeeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\endlist
|
||||
\endlist
|
||||
|
||||
@ -75,7 +75,7 @@
|
||||
\list
|
||||
\li \b 3. | The plugin will be set up with the params of the auto discovered \l{DeviceDescriptor}.
|
||||
\li \b 4. | If something goes wrong during the setup return \l{DeviceManager::DeviceSetupStatusFailure}, otherwise \l{DeviceManager::DeviceSetupStatusSuccess}.
|
||||
\li \b 5. | If the device setup succeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\li \b 5. | If the device setup succeeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\endlist
|
||||
\endlist
|
||||
|
||||
@ -95,7 +95,7 @@
|
||||
\list
|
||||
\li \b 4. | The plugin will be set up with the params of the discovered \l{DeviceDescriptor}.
|
||||
\li \b 5. | If something goes wrong during the setup return \l{DeviceManager::DeviceSetupStatusFailure}, otherwise \l{DeviceManager::DeviceSetupStatusSuccess}.
|
||||
\li \b 6. | If the device setup succeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\li \b 6. | If the device setup succeeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\endlist
|
||||
\endlist
|
||||
|
||||
@ -120,7 +120,7 @@
|
||||
\list
|
||||
\li \b 7. | The plugin will be set up with the params of the paired \l{Device}.
|
||||
\li \b 8. | If something goes wrong during the setup return \l{DeviceManager::DeviceSetupStatusFailure}, otherwise \l{DeviceManager::DeviceSetupStatusSuccess}.
|
||||
\li \b 9. | If the device setup succeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\li \b 9. | If the device setup succeeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\endlist
|
||||
\endlist
|
||||
|
||||
@ -145,7 +145,7 @@
|
||||
\list
|
||||
\li \b 7. | The plugin will be set up with the params of the paired \l{Device}.
|
||||
\li \b 8. | If something goes wrong during the setup return \l{DeviceManager::DeviceSetupStatusFailure}, otherwise \l{DeviceManager::DeviceSetupStatusSuccess}.
|
||||
\li \b 9. | If the device setup succeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\li \b 9. | If the device setup succeeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\endlist
|
||||
\endlist
|
||||
|
||||
@ -176,7 +176,7 @@
|
||||
\list
|
||||
\li \b 9. | The plugin will be set up with the params (i.e. containing a \tt pin param) of the paired \l{Device}.
|
||||
\li \b 10. | If something goes wrong during the setup return \l{DeviceManager::DeviceSetupStatusFailure}, otherwise \l{DeviceManager::DeviceSetupStatusSuccess}.
|
||||
\li \b 11. | If the device setup succeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\li \b 11. | If the device setup succeeded and the device is in the system, the \l{DeviceManager} will call the \l{DevicePlugin::postSetupDevice()}{postSetupDevice()} method.
|
||||
\endlist
|
||||
\endlist
|
||||
*/
|
||||
|
||||
@ -1800,7 +1800,7 @@ Add a rule. You can describe rules by one or many EventDesciptors and a StateEva
|
||||
\endcode
|
||||
See also: \l{RuleError}, \l{RuleAction}, \l{TimeDescriptor}, \l{RuleAction}, \l{EventDescriptor}, \l{StateEvaluator}
|
||||
\section3 Rules.DisableRule
|
||||
Disable a rule. The rule won't be triggered by it's events or state changes while it is disabled. If successfull, the notification "Rule.RuleConfigurationChanged" will be emitted.
|
||||
Disable a rule. The rule won't be triggered by it's events or state changes while it is disabled. If successful, the notification "Rule.RuleConfigurationChanged" will be emitted.
|
||||
\section4 Params
|
||||
\code
|
||||
{
|
||||
@ -1815,7 +1815,7 @@ Disable a rule. The rule won't be triggered by it's events or state changes whil
|
||||
\endcode
|
||||
See also: \l{RuleError}
|
||||
\section3 Rules.EditRule
|
||||
Edit the parameters of a rule. The configuration of the rule with the given ruleId will be replaced with the new given configuration. In ordert to enable or disable a Rule, please use the methods "Rules.EnableRule" and "Rules.DisableRule". If successfull, the notification "Rule.RuleConfigurationChanged" will be emitted.
|
||||
Edit the parameters of a rule. The configuration of the rule with the given ruleId will be replaced with the new given configuration. In ordert to enable or disable a Rule, please use the methods "Rules.EnableRule" and "Rules.DisableRule". If successful, the notification "Rule.RuleConfigurationChanged" will be emitted.
|
||||
\section4 Params
|
||||
\code
|
||||
{
|
||||
@ -1845,7 +1845,7 @@ Edit the parameters of a rule. The configuration of the rule with the given rule
|
||||
\endcode
|
||||
See also: \l{RuleError}, \l{Rule}, \l{RuleAction}, \l{TimeDescriptor}, \l{RuleAction}, \l{EventDescriptor}, \l{StateEvaluator}
|
||||
\section3 Rules.EnableRule
|
||||
Enabled a rule that has previously been disabled.If successfull, the notification "Rule.RuleConfigurationChanged" will be emitted.
|
||||
Enabled a rule that has previously been disabled.If successful, the notification "Rule.RuleConfigurationChanged" will be emitted.
|
||||
\section4 Params
|
||||
\code
|
||||
{
|
||||
@ -2889,7 +2889,7 @@ Emitted whenever a Rule was removed.
|
||||
}
|
||||
},
|
||||
"Rules.DisableRule": {
|
||||
"description": "Disable a rule. The rule won't be triggered by it's events or state changes while it is disabled. If successfull, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"description": "Disable a rule. The rule won't be triggered by it's events or state changes while it is disabled. If successful, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"params": {
|
||||
"ruleId": "Uuid"
|
||||
},
|
||||
@ -2898,7 +2898,7 @@ Emitted whenever a Rule was removed.
|
||||
}
|
||||
},
|
||||
"Rules.EditRule": {
|
||||
"description": "Edit the parameters of a rule. The configuration of the rule with the given ruleId will be replaced with the new given configuration. In ordert to enable or disable a Rule, please use the methods \"Rules.EnableRule\" and \"Rules.DisableRule\". If successfull, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"description": "Edit the parameters of a rule. The configuration of the rule with the given ruleId will be replaced with the new given configuration. In ordert to enable or disable a Rule, please use the methods \"Rules.EnableRule\" and \"Rules.DisableRule\". If successful, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"params": {
|
||||
"actions": [
|
||||
"$ref:RuleAction"
|
||||
@ -2922,7 +2922,7 @@ Emitted whenever a Rule was removed.
|
||||
}
|
||||
},
|
||||
"Rules.EnableRule": {
|
||||
"description": "Enabled a rule that has previously been disabled.If successfull, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"description": "Enabled a rule that has previously been disabled.If successful, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"params": {
|
||||
"ruleId": "Uuid"
|
||||
},
|
||||
|
||||
@ -61,7 +61,7 @@
|
||||
|
||||
\section1 Handshake
|
||||
|
||||
Once connected to the socket, the server will send immediatly a handshake message. The handshake message
|
||||
Once connected to the socket, the server will send immediately a handshake message. The handshake message
|
||||
is a JSON object and contains all relevant information about the server and the API in order to start
|
||||
communicationg with the server.
|
||||
|
||||
@ -92,7 +92,7 @@
|
||||
The field represents the API version of the server you are connected to. This should be used for API
|
||||
compatibility checks.
|
||||
\li \code "authenticationRequired": bool \endcode
|
||||
If this property is true, a client must perform the authentication process before beeing able to interact with the API. See section \l{Authentication} for more information.
|
||||
If this property is true, a client must perform the authentication process before being able to interact with the API. See section \l{Authentication} for more information.
|
||||
\li \code "initialSetupRequired": bool \endcode
|
||||
This property indicates if the server was set up already. A server is set up if a user has been created. If the \tt authenticationRequired property is \tt{false}, this field can be ignored.
|
||||
\li \code "pushButtonAuthAvailable": bool \endcode
|
||||
@ -115,7 +115,7 @@
|
||||
|
||||
The JSON content should always be sent as a compack JSON Object (without spaces, tabs and new line characters within the object \tt{{...}}).
|
||||
At the end of this compact JSON string the payload must be terminated with the \tt{\n} character. This makes sure, that the parsing of the
|
||||
message is easier and a single message can be splitted in multiple cunckes during the transport. The client parsing should work the same way.
|
||||
message is easier and a single message can be split in multiple cunckes during the transport. The client parsing should work the same way.
|
||||
|
||||
In order to demonstrate this with an example, the \l{JSONRPC.Hello} request could look like this:
|
||||
|
||||
@ -154,7 +154,7 @@
|
||||
\li \code "notification": string \endcode
|
||||
The notification field holds the name of this notification. Notifications are grouped into namespaces like the methods.
|
||||
The notification string consists of two parts, the namespace and the notification name, separated by a dot.
|
||||
This property can be used to check if a recived message is a response to a request or a notification.
|
||||
This property can be used to check if a received message is a response to a request or a notification.
|
||||
\li \code "params": object \endcode
|
||||
The params contains any JSON object. This parameter is optional and differs according to each \l{Notifications}{notification}.
|
||||
\endlist
|
||||
@ -184,7 +184,7 @@
|
||||
\li \l{Push-button authentication}
|
||||
\endlist
|
||||
|
||||
If both authentication methods are available, the \l{Push-button authentication} should be prefered.
|
||||
If both authentication methods are available, the \l{Push-button authentication} should be preferred.
|
||||
|
||||
\section1 Username and password
|
||||
|
||||
|
||||
@ -44,7 +44,7 @@
|
||||
\list
|
||||
\li \l{JSON-RPC API}{The API description}
|
||||
\li \l{Interfaces for DeviceClasses}
|
||||
\li \l{Paramtypes and the coresponding UI elements}
|
||||
\li \l{Paramtypes and the corresponding UI elements}
|
||||
\endlist
|
||||
|
||||
\section1 Quicklinks
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
/*!
|
||||
\page paramtypes-ui-elements.html
|
||||
\title Paramtypes and the coresponding UI elements
|
||||
\title Paramtypes and the corresponding UI elements
|
||||
|
||||
On this page you can find different examples how a \l{ParamType} can be displayed in a client application.
|
||||
The images used for this examples were created with the Ubuntu SDK and are ment as an example, not as a directive.
|
||||
|
||||
@ -91,9 +91,9 @@
|
||||
qCWarning(dcExample()) << "Warning the world!";
|
||||
\endcode
|
||||
|
||||
Please start allways with a capital letter i.e. \tt {"idName": "Example"}. The logging category allowes you to categorise the debug output. It can be configured with the \tt -d argument of nymead (see \tt {$ man nymead}).
|
||||
Please start always with a capital letter i.e. \tt {"idName": "Example"}. The logging category allowes you to categorise the debug output. It can be configured with the \tt -d argument of nymead (see \tt {$ man nymead}).
|
||||
\li - \underline{\e id:} The actual uuid (\l{PluginId}) of the plugin \unicode{0x2192} \l{DevicePlugin::pluginId()}
|
||||
\li - \underline{\e paramTypes:} Optionl: A list of \l{ParamType}{ParamTypes} which define the paramters of this plugin \unicode{0x2192} \l{DevicePlugin::configuration()} (see section "\l{The ParamType definition}").
|
||||
\li - \underline{\e paramTypes:} Optionl: A list of \l{ParamType}{ParamTypes} which define the parameters of this plugin \unicode{0x2192} \l{DevicePlugin::configuration()} (see section "\l{The ParamType definition}").
|
||||
\li - \underline{\e vendors:} The list of \l{Vendor}{Vendors} objects (see section "\l{The Vendor definition}");
|
||||
\endlist
|
||||
|
||||
@ -212,7 +212,7 @@
|
||||
\li - \underline{\e primaryStateTypeId:} Optional: Define which \l{StateType} is the primary \l{State} for this \l{Device}. This allowes a client developer to place the primary \l{State} value in the device overview.
|
||||
\li - \underline{\e primaryActionTypeId:} Optional: Define which \l{ActionType} is the primary \l{Action} for this \l{Device}. This allowes a client developer to place the primary \l{Action} element in the device overview.
|
||||
\li - \underline{\e discoveryParamTypes:} Optional: A list of \l{ParamType}{ParamTypes} which will be needed for discovering a device \unicode{0x2192} \l{DeviceClass::discoveryParamTypes()}. This parameter will only be used for devices with the \l{DeviceClass::CreateMethodDiscovery}{CreateMethodDiscovery} (see section "\l{The ParamType definition}").
|
||||
\li - \underline{\e paramTypes:} A list of \l{ParamType}{ParamTypes} which define the paramters of a device \unicode{0x2192} \l{DeviceClass::paramTypes()} (see section "\l{The ParamType definition}").
|
||||
\li - \underline{\e paramTypes:} A list of \l{ParamType}{ParamTypes} which define the parameters of a device \unicode{0x2192} \l{DeviceClass::paramTypes()} (see section "\l{The ParamType definition}").
|
||||
\li - \underline{\e stateTypes:} Optional: A list of \l{StateType}{StateTypes} of the device \unicode{0x2192} \l{DeviceClass::stateTypes()} (see section "\l{The StateType definition}").
|
||||
\li - \underline{\e actionTypes:} Optional: A list of \l{ActionType}{ActionTypes} of the device \unicode{0x2192} \l{DeviceClass::actionTypes()} (see section "\l{The ActionType definition}").
|
||||
\li - \underline{\e eventTypes:} Optional: A list of \l{EventType}{EventTypes} of the device \unicode{0x2192} \l{DeviceClass::eventTypes()} (see section "\l{The EventType definition}").
|
||||
@ -249,8 +249,8 @@
|
||||
\li - \underline{\e id:} The actual uuid (\l{ParamTypeId}) of the \l{ParamType} \unicode{0x2192} \l{ParamType::id()}.
|
||||
\li - \underline{\e name:} This parameter will be used to define the ParamTypeId variable named deviceClassName<Name>ParamTypeId in the plugininfo.h, so it can be used in the code.
|
||||
\li - \underline{\e displayName:} The visible name of the \l{ParamType} \unicode{0x2192} \l{ParamType::displayName()}.
|
||||
\li - \underline{\e type:} The data type of this paramter \unicode{0x2192} \l{ParamType::type()}.
|
||||
\li - \underline{\e inputType:} Optional: A paramter for clients to know which kind of \l{Types::InputType}{InputType} this. See enum \l{Types::InputType} for more information. The expected value for the \e inputType parameter matches the enum name like this:
|
||||
\li - \underline{\e type:} The data type of this parameter \unicode{0x2192} \l{ParamType::type()}.
|
||||
\li - \underline{\e inputType:} Optional: A parameter for clients to know which kind of \l{Types::InputType}{InputType} this. See enum \l{Types::InputType} for more information. The expected value for the \e inputType parameter matches the enum name like this:
|
||||
|
||||
\tt {Types::InputTypeTextArea} \unicode{0x2192} \tt {"inputType": "TextArea"}
|
||||
|
||||
@ -303,7 +303,7 @@ A \l{StateType} has following parameters:
|
||||
"value"
|
||||
],
|
||||
"o:writable": true,
|
||||
"o:displayNameAction": "Name of the the created ActionType (translatable)"
|
||||
"o:displayNameAction": "Name of the created ActionType (translatable)"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
||||
@ -5,9 +5,9 @@
|
||||
|
||||
\b{\unicode{0x2192} \underline{\l{https://www.youtube.com/watch?v=7a_k0C1Ib1A}{Video for this tutorial}}}
|
||||
|
||||
Assuming you are working on an Ubuntu system here are the steps how to set up the build environment. Basically you can choose your prefered SDK but all tutorials are based on the Qt Creator and we recommand to use that one. You can also use the Ubuntu SDK, which is basically a modified Qt Creator.
|
||||
Assuming you are working on an Ubuntu system here are the steps how to set up the build environment. Basically you can choose your preferred SDK but all tutorials are based on the Qt Creator and we reccommend to use that one. You can also use the Ubuntu SDK, which is basically a modified Qt Creator.
|
||||
|
||||
\note Please take care that you are using the Qt version from the system for building. The nymea server will allways be built with the official Qt version for the appropriate system version. The plugin \underline{must} have the same version like the nymea server.
|
||||
\note Please take care that you are using the Qt version from the system for building. The nymea server will always be built with the official Qt version for the appropriate system version. The plugin \underline{must} have the same version like the nymea server.
|
||||
|
||||
\section2 Install Qt
|
||||
In the first step you need to install the Qt libraries:
|
||||
@ -56,7 +56,7 @@
|
||||
\list
|
||||
\li \underline{\e nymea} \unicode{0x2192} the \tt nymea package is a meta package and will install the \tt nymead, \tt libnymea1 and \tt nymea-plugins package so you can start the nymea daemon.
|
||||
\li \underline{\e nymea-webinterface} \unicode{0x2192} the \tt nymea-webinterface package will install the webinterface for nymea, which is accessable on \l{http://localhost:3333}.
|
||||
\li \underline{\e nymea-cli} \unicode{0x2192} the \tt nymea-cli package will install the command line interface for the nymea JSON-RPC API. You can find more infomation \l{https://github.com/guh/nymea/wiki/nymea-cli}{here}.
|
||||
\li \underline{\e nymea-cli} \unicode{0x2192} the \tt nymea-cli package will install the command line interface for the nymea JSON-RPC API. You can find more information \l{https://github.com/guh/nymea/wiki/nymea-cli}{here}.
|
||||
\li \underline{\e nymea-doc} \unicode{0x2192} the \tt nymea-doc package will install the offline documentation on your system (this homepage). You can access the documentation in your brwoser with \l{file:///usr/share/doc/nymea/html/index.html}{file:///usr/share/doc/nymea/html/index.html}.
|
||||
\li \underline{\e libnymea1-dev} \unicode{0x2192} the \tt libnymea1-dev package brings all development files of nymea (header files and lib) which will be needed to write a plugin.
|
||||
\endlist
|
||||
|
||||
@ -48,7 +48,7 @@
|
||||
|
||||
As you can see, there is only one \tt bool \l State which has the property \e {"writable"}. This property indicates, that this \l State is writable and we need an \l Action for doing that. You can find more details about this property in \l {The StateType definition} documentation.
|
||||
|
||||
We learnend in the previouse tutorial that a \l State will allways generate an \l Event when he changes his \e {value}. This \l Event has the same UUID as the \l State which generated the \l Event. The same thing happens with the \l Action if you make a \l State writable. The device manager defines a new \l ActionType which has the same UUID as the \l State which will be changed with the \l Action.
|
||||
We learnend in the previouse tutorial that a \l State will always generate an \l Event when he changes his \e {value}. This \l Event has the same UUID as the \l State which generated the \l Event. The same thing happens with the \l Action if you make a \l State writable. The device manager defines a new \l ActionType which has the same UUID as the \l State which will be changed with the \l Action.
|
||||
|
||||
\tt {\l{StateTypeId} == \l{EventTypeId} == \l{ActionTypeId}}
|
||||
|
||||
|
||||
@ -369,7 +369,7 @@ In order to get started with our new \b {"Network Info"} plugin we use the minim
|
||||
|
||||
\section1 Writing the plugin
|
||||
|
||||
Now we have our basic for starting to implement the new defined plugin. If you install the current plugin, start \tt nymead and add the a \b {Info about Network} device whith \b {\tt nymea-cli} you can check the device states and should see something like this:
|
||||
Now we have our basic for starting to implement the new defined plugin. If you install the current plugin, start \tt nymead and add the a \b {Info about Network} device with \b {\tt nymea-cli} you can check the device states and should see something like this:
|
||||
|
||||
\code
|
||||
========================================================
|
||||
@ -427,7 +427,7 @@ parameter from \l{The Plugin JSON file}.
|
||||
// Call the GET method from the NetworkManager
|
||||
QNetworkReply *reply = networkManagerGet(locationRequest);
|
||||
|
||||
// Hash the reply, because we dont get the result immediately
|
||||
// Hash the reply, because we don't get the result immediately
|
||||
m_asyncActionReplies.insert(reply, action.id());
|
||||
|
||||
// Hash the device for this action
|
||||
@ -477,7 +477,7 @@ parameter from \l{The Plugin JSON file}.
|
||||
return;
|
||||
}
|
||||
|
||||
// The request was successfull, lets read the payload
|
||||
// The request was successful, lets read the payload
|
||||
QByteArray data = reply->readAll();
|
||||
|
||||
// Important -> delete the reply to prevent a memory leak!
|
||||
@ -496,7 +496,7 @@ parameter from \l{The Plugin JSON file}.
|
||||
void actionDataReady(const ActionId &actionId, const QByteArray &data);
|
||||
\endcode
|
||||
|
||||
First we have to check if the received data is a vaild JSON document. If not, the action execution \b "update" was not successfull and we have to report the error. Otherwise we read the data and set the state values of our device.
|
||||
First we have to check if the received data is a valid JSON document. If not, the action execution \b "update" was not successful and we have to report the error. Otherwise we read the data and set the state values of our device.
|
||||
|
||||
\code
|
||||
void DevicePluginNetworkInfo::actionDataReady(const ActionId &actionId, const QByteArray &data)
|
||||
@ -555,7 +555,7 @@ parameter from \l{The Plugin JSON file}.
|
||||
|
||||
qCDebug(dcNetworkInfo) << "Action" << actionId << "execution finished successfully.";
|
||||
|
||||
// Emit the successfull action execution result to the device manager
|
||||
// Emit the successful action execution result to the device manager
|
||||
emit actionExecutionFinished(actionId, DeviceManager::DeviceErrorNoError);
|
||||
}
|
||||
\endcode
|
||||
@ -580,7 +580,7 @@ parameter from \l{The Plugin JSON file}.
|
||||
\li Use nymea-cli to execute the \b update action:
|
||||
|
||||
\tt "Devices" \unicode{0x2192} \tt "Execute action" \unicode{0x2192} \tt {"Your device name"} \unicode{0x2192} \tt {update}
|
||||
\li Use nymea-cli to check if the device states were updated sucessfully:
|
||||
\li Use nymea-cli to check if the device states were updated successfully:
|
||||
|
||||
\tt "Devices" \unicode{0x2192} \tt "List..." \unicode{0x2192} \tt {"List device states"} \unicode{0x2192} \tt {"Your device name"}.
|
||||
|
||||
|
||||
@ -212,7 +212,7 @@
|
||||
url.setPath("/.well-known/core");
|
||||
CoapReply *reply = m_coap->get(CoapRequest(url));
|
||||
|
||||
// Check imediatly if the there occured any error
|
||||
// Check immediately if the there occurred any error
|
||||
if (reply->error() != CoapReply::NoError) {
|
||||
qCWarning(dcCoapClient) << "Could not discover CoAP server:" << reply->errorString();
|
||||
reply->deleteLater();
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
\nextpage {Tutorial 1 - The "Minimal" plugin}
|
||||
\previouspage {Write your own plugin}
|
||||
|
||||
In order to getting started with your own \l DevicePlugin it is recommanded to walk trough following tutorials to understand how the mechanism works:
|
||||
In order to getting started with your own \l DevicePlugin it is reccommended to walk trough following tutorials to understand how the mechanism works:
|
||||
|
||||
\annotatedlist tutorials
|
||||
\annotatedlist tutorials
|
||||
*/
|
||||
|
||||
@ -51,7 +51,7 @@ void BluetoothDiscoveryReplyImplementation::setError(const BluetoothDiscoveryRep
|
||||
{
|
||||
m_error = error;
|
||||
if (m_error != BluetoothDiscoveryReplyErrorNoError) {
|
||||
emit errorOccured(m_error);
|
||||
emit errorOccurred(m_error);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -157,7 +157,7 @@ void BluetoothLowEnergyDeviceImplementation::onDeviceError(const QLowEnergyContr
|
||||
if (connected())
|
||||
qCWarning(dcBluetooth()) << "Device error:" << name() << address().toString() << ": " << error << m_controller->errorString();
|
||||
|
||||
emit errorOccured(error);
|
||||
emit errorOccurred(error);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -32,7 +32,7 @@
|
||||
This enum type specifies the state of a \l{QtAvahiService}.
|
||||
|
||||
\value QtAvahiServiceStateUncomitted
|
||||
The group has not yet been commited, the user must still call avahi_entry_group_commit().
|
||||
The group has not yet been committed, the user must still call avahi_entry_group_commit().
|
||||
\value QtAvahiServiceStateRegistering
|
||||
The entries of the group are currently being registered.
|
||||
\value QtAvahiServiceStateEstablished
|
||||
@ -211,7 +211,7 @@ bool QtAvahiService::updateTxtRecord(const QHash<QString, QString> &txtRecords)
|
||||
return true;
|
||||
}
|
||||
|
||||
/*! Returns true if the service group was added and commited to the network without errors. */
|
||||
/*! Returns true if the service group was added and committed to the network without errors. */
|
||||
bool QtAvahiService::isValid() const
|
||||
{
|
||||
return (d_ptr->group && !d_ptr->error);
|
||||
|
||||
@ -69,7 +69,7 @@ void UpnpDiscoveryReplyImplementation::setError(const UpnpDiscoveryReplyImplemen
|
||||
{
|
||||
m_error = error;
|
||||
if (m_error != UpnpDiscoveryReplyErrorNoError) {
|
||||
emit errorOccured(m_error);
|
||||
emit errorOccurred(m_error);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -56,7 +56,7 @@ void UpnpDiscoveryRequest::discover(int timeout)
|
||||
|
||||
void UpnpDiscoveryRequest::addDeviceDescriptor(const UpnpDeviceDescriptor &deviceDescriptor)
|
||||
{
|
||||
// check if we allready have the device in the list
|
||||
// check if we already have the device in the list
|
||||
bool isAlreadyInList = false;
|
||||
foreach (UpnpDeviceDescriptor upnpDeviceDescriptor, m_deviceList) {
|
||||
if (upnpDeviceDescriptor.uuid() == deviceDescriptor.uuid()) {
|
||||
|
||||
@ -26,9 +26,9 @@
|
||||
|
||||
namespace nymeaserver {
|
||||
|
||||
PluginTimerImplementation::PluginTimerImplementation(int intervall, QObject *parent) :
|
||||
PluginTimerImplementation::PluginTimerImplementation(int interval, QObject *parent) :
|
||||
PluginTimer(parent),
|
||||
m_interval(intervall)
|
||||
m_interval(interval)
|
||||
{
|
||||
connect(NymeaCore::instance()->timeManager(), &TimeManager::tick, this, &PluginTimerImplementation::tick);
|
||||
}
|
||||
|
||||
@ -38,7 +38,7 @@ class PluginTimerImplementation : public PluginTimer
|
||||
friend class PluginTimerManagerImplementation;
|
||||
|
||||
public:
|
||||
explicit PluginTimerImplementation(int intervall, QObject *parent = nullptr);
|
||||
explicit PluginTimerImplementation(int interval, QObject *parent = nullptr);
|
||||
|
||||
int interval() const override;
|
||||
int currentTick() const override;
|
||||
|
||||
@ -39,7 +39,7 @@
|
||||
important part.
|
||||
|
||||
The second possibility to sent data to a 433 MHz device is the \l{http://www.brennenstuhl.de/de-DE/steckdosenleisten-schaltgeraete-und-adapter/brematic-hausautomation/brematic-home-automation-gateway-gwy-433-1.html}
|
||||
{Brennenstuhl 433 MHz LAN Gateway}. If there is a Gateway in the local network, this class will automaticaly detect
|
||||
{Brennenstuhl 433 MHz LAN Gateway}. If there is a Gateway in the local network, this class will automatically detect
|
||||
it and will be used. If both transmitter are available (Gateway + GPIO), each signal will be transmitted over both sender.
|
||||
|
||||
\note: Radio 433 on GPIO's is by default disabled. If you want to enable it, you need to compile the source with the qmake config \tt{CONFIG+=radio433gpio}
|
||||
|
||||
@ -40,7 +40,7 @@
|
||||
\value Ok
|
||||
The request was understood and everything is Ok.
|
||||
\value Created
|
||||
The resource was created sucessfully.
|
||||
The resource was created successfully.
|
||||
\value Accepted
|
||||
The resource was accepted.
|
||||
\value NoContent
|
||||
@ -278,7 +278,7 @@ QByteArray HttpReply::rawHeader() const
|
||||
return m_rawHeader;
|
||||
}
|
||||
|
||||
/*! Sets the \a close paramter of this \l{HttpReply}. If \a close is true,
|
||||
/*! Sets the \a close parameter of this \l{HttpReply}. If \a close is true,
|
||||
the connection of the client will be closed after this reply was sent.
|
||||
*/
|
||||
void HttpReply::setCloseConnection(const bool &close)
|
||||
@ -286,7 +286,7 @@ void HttpReply::setCloseConnection(const bool &close)
|
||||
m_closeConnection = close;
|
||||
}
|
||||
|
||||
/*! Returns the connection close paramter of this \l{HttpReply}. If close is true, the connection
|
||||
/*! Returns the connection close parameter of this \l{HttpReply}. If close is true, the connection
|
||||
of the client will be closed after this reply was sent.
|
||||
*/
|
||||
bool HttpReply::closeConnection() const
|
||||
|
||||
@ -87,7 +87,7 @@ QByteArray HttpRequest::rawHeader() const
|
||||
return m_rawHeader;
|
||||
}
|
||||
|
||||
/*! Returns the list of raw header splitted into key and value.*/
|
||||
/*! Returns the list of raw header as key and value pairs.*/
|
||||
QHash<QByteArray, QByteArray> HttpRequest::rawHeaderList() const
|
||||
{
|
||||
return m_rawHeaderList;
|
||||
@ -235,7 +235,7 @@ void HttpRequest::validate()
|
||||
m_isComplete = false;
|
||||
return;
|
||||
}
|
||||
// check if the content lenght bigger than header Content-Length
|
||||
// check if the content length bigger than header Content-Length
|
||||
if (m_payload.size() > contentLength) {
|
||||
qCWarning(dcWebServer) << "Payload size greater than header Content-Length:";
|
||||
qCWarning(dcWebServer) << " -> Content-Length:" << contentLength;
|
||||
|
||||
@ -359,7 +359,7 @@ JsonReply *JsonRPCServer::KeepAlive(const QVariantMap ¶ms)
|
||||
return createReply(resultMap);
|
||||
}
|
||||
|
||||
/*! Returns the list of registred \l{JsonHandler}{JsonHandlers} and their name.*/
|
||||
/*! Returns the list of registered \l{JsonHandler}{JsonHandlers} and their name.*/
|
||||
QHash<QString, JsonHandler *> JsonRPCServer::handlers() const
|
||||
{
|
||||
return m_handlers;
|
||||
|
||||
@ -103,7 +103,7 @@ RulesHandler::RulesHandler(QObject *parent) :
|
||||
params.clear(); returns.clear();
|
||||
setDescription("EditRule", "Edit the parameters of a rule. The configuration of the rule with the given ruleId "
|
||||
"will be replaced with the new given configuration. In ordert to enable or disable a Rule, please use the "
|
||||
"methods \"Rules.EnableRule\" and \"Rules.DisableRule\". If successfull, the notification \"Rule.RuleConfigurationChanged\" "
|
||||
"methods \"Rules.EnableRule\" and \"Rules.DisableRule\". If successful, the notification \"Rule.RuleConfigurationChanged\" "
|
||||
"will be emitted.");
|
||||
params.insert("ruleId", JsonTypes::basicTypeToString(JsonTypes::Uuid));
|
||||
params.insert("name", JsonTypes::basicTypeToString(JsonTypes::String));
|
||||
@ -135,7 +135,7 @@ RulesHandler::RulesHandler(QObject *parent) :
|
||||
|
||||
params.clear(); returns.clear();
|
||||
setDescription("EnableRule", "Enabled a rule that has previously been disabled."
|
||||
"If successfull, the notification \"Rule.RuleConfigurationChanged\" will be emitted.");
|
||||
"If successful, the notification \"Rule.RuleConfigurationChanged\" will be emitted.");
|
||||
params.insert("ruleId", JsonTypes::basicTypeToString(JsonTypes::Uuid));
|
||||
setParams("EnableRule", params);
|
||||
returns.insert("ruleError", JsonTypes::ruleErrorRef());
|
||||
@ -143,7 +143,7 @@ RulesHandler::RulesHandler(QObject *parent) :
|
||||
|
||||
params.clear(); returns.clear();
|
||||
setDescription("DisableRule", "Disable a rule. The rule won't be triggered by it's events or state changes while it is disabled. "
|
||||
"If successfull, the notification \"Rule.RuleConfigurationChanged\" will be emitted.");
|
||||
"If successful, the notification \"Rule.RuleConfigurationChanged\" will be emitted.");
|
||||
params.insert("ruleId", JsonTypes::basicTypeToString(JsonTypes::Uuid));
|
||||
setParams("DisableRule", params);
|
||||
returns.insert("ruleError", JsonTypes::ruleErrorRef());
|
||||
|
||||
@ -27,7 +27,7 @@
|
||||
\inmodule core
|
||||
|
||||
The \l{LogEngine} creates a \l{https://sqlite.org/}{SQLite3} database to stores everything what's
|
||||
happening in the system. The database can be accessed from the API's. To controll the size of the database the
|
||||
happening in the system. The database can be accessed from the API's. To control the size of the database the
|
||||
limit of the databse are 8000 entries.
|
||||
|
||||
|
||||
@ -68,7 +68,7 @@
|
||||
\value LoggingErrorLogEntryNotFound
|
||||
The requested \l{LogEntry} could not be found.
|
||||
\value LoggingErrorInvalidFilterParameter
|
||||
The given \l{LogFilter} contains an invalid paramter.
|
||||
The given \l{LogFilter} contains an invalid parameter.
|
||||
*/
|
||||
|
||||
/*! \enum nymeaserver::Logging::LoggingEventType
|
||||
|
||||
@ -124,7 +124,7 @@ NymeaCore::~NymeaCore()
|
||||
{
|
||||
m_logger->logSystemEvent(m_timeManager->currentDateTime(), false);
|
||||
|
||||
// Make sure DeviceManager is teared down at first so plugins don't access any ressources any more.
|
||||
// Make sure DeviceManager is teared down at first so plugins don't access any resources any more.
|
||||
qCDebug(dcApplication) << "Shutting down \"Device Manager\"";
|
||||
delete m_deviceManager;
|
||||
|
||||
|
||||
@ -27,7 +27,7 @@
|
||||
|
||||
The \l{RestServer} class provides the server interface for a REST API call. The \l{RestServer}
|
||||
will create a \l{WebServer} object. The \l{WebServer} will parse the \l{HttpRequest} and emits
|
||||
the signal \l{WebServer::httpRequestReady()}. This signal will be catched from this \l{RestServer}
|
||||
the signal \l{WebServer::httpRequestReady()}. This signal will be handled by this \l{RestServer}
|
||||
and processed by the corresponding \l{RestResource}. Once the \l{HttpRequest} is finished, the
|
||||
\l{RestServer} will send a \l{HttpReply} back to the client using \l{WebServer::sendHttpReply()}.
|
||||
|
||||
|
||||
@ -256,7 +256,7 @@ bool UserManager::verifyToken(const QByteArray &token)
|
||||
return false;
|
||||
}
|
||||
if (!result.first()) {
|
||||
qCDebug(dcUserManager) << "Authorisation failed for token" << token;
|
||||
qCDebug(dcUserManager) << "Authorization failed for token" << token;
|
||||
return false;
|
||||
}
|
||||
//qCDebug(dcUserManager) << "Token authorized for user" << result.value("username").toString();
|
||||
|
||||
@ -66,7 +66,7 @@
|
||||
*/
|
||||
|
||||
/*! \fn void Coap::notificationReceived(const CoapObserveResource &resource, const int ¬ificationNumber, const QByteArray &payload);
|
||||
This signal is emitted when a value of an observed \a resource changed. The \a notificationNumber specifies the the count of the notification
|
||||
This signal is emitted when a value of an observed \a resource changed. The \a notificationNumber specifies the count of the notification
|
||||
to keep the correct order. The value can be parsed from the \a payload parameter.
|
||||
*/
|
||||
|
||||
|
||||
@ -62,7 +62,7 @@ public:
|
||||
// Methods: https://tools.ietf.org/html/rfc7252#section-5.8
|
||||
// Respond codes: https://tools.ietf.org/html/rfc7252#section-12.1.2
|
||||
enum StatusCode {
|
||||
Empty = 0x00, // Empty mesage (ping)
|
||||
Empty = 0x00, // Empty message (ping)
|
||||
Get = 0x01, // Method GET
|
||||
Post = 0x02, // Method POST
|
||||
Put = 0x03, // Method PUT
|
||||
|
||||
@ -67,7 +67,7 @@
|
||||
*/
|
||||
|
||||
/*! \fn void CoapReply::error(const Error &code);
|
||||
This signal is emitted when an error occured. The given \a code represents the \l{CoapReply::Error}.
|
||||
This signal is emitted when an error occurred. The given \a code represents the \l{CoapReply::Error}.
|
||||
|
||||
\sa error(), errorString()
|
||||
*/
|
||||
@ -75,7 +75,7 @@
|
||||
/*! \enum CoapReply::Error
|
||||
|
||||
\value NoError
|
||||
No error occured. Everything ok.
|
||||
No error occurred. Everything ok.
|
||||
\value HostNotFoundError
|
||||
The remote host name was not found (invalid hostname).
|
||||
\value TimeoutError
|
||||
|
||||
@ -534,7 +534,7 @@ DeviceManager::DeviceError DeviceManager::reconfigureDevice(const DeviceId &devi
|
||||
DeviceSetupStatus status = plugin->setupDevice(device);
|
||||
switch (status) {
|
||||
case DeviceSetupStatusFailure:
|
||||
qCWarning(dcDeviceManager) << "Device reconfiguration failed. Not saving changes of device paramters. Device setup incomplete.";
|
||||
qCWarning(dcDeviceManager) << "Device reconfiguration failed. Not saving changes of device parameters. Device setup incomplete.";
|
||||
return DeviceErrorSetupFailed;
|
||||
case DeviceSetupStatusAsync:
|
||||
m_asyncDeviceReconfiguration.append(device);
|
||||
|
||||
@ -50,7 +50,7 @@ public:
|
||||
|
||||
signals:
|
||||
void finished();
|
||||
void errorOccured(const BluetoothDiscoveryReplyError &error);
|
||||
void errorOccurred(const BluetoothDiscoveryReplyError &error);
|
||||
|
||||
};
|
||||
|
||||
|
||||
@ -58,7 +58,7 @@ signals:
|
||||
void connectedChanged(const bool &connected);
|
||||
void autoConnectingChanged(const bool &autoConnecting);
|
||||
void stateChanged(const QLowEnergyController::ControllerState &state);
|
||||
void errorOccured(const QLowEnergyController::Error &error);
|
||||
void errorOccurred(const QLowEnergyController::Error &error);
|
||||
void servicesDiscoveryFinished();
|
||||
|
||||
};
|
||||
|
||||
@ -69,7 +69,7 @@
|
||||
*/
|
||||
|
||||
/*! \fn void GpioMonitor::valueChanged(const bool &value);
|
||||
* This signal will be emited, if the monitored \l{Gpio}{Gpios} changed his \a value. */
|
||||
* This signal will be emitted, if the monitored \l{Gpio}{Gpios} changed his \a value. */
|
||||
|
||||
#include "gpiomonitor.h"
|
||||
#include "loggingcategories.h"
|
||||
|
||||
@ -39,7 +39,7 @@
|
||||
important part.
|
||||
|
||||
The second possibility to sent data to a 433 MHz device is the \l{http://www.brennenstuhl.de/de-DE/steckdosenleisten-schaltgeraete-und-adapter/brematic-hausautomation/brematic-home-automation-gateway-gwy-433-1.html}
|
||||
{Brennenstuhl 433 MHz LAN Gateway}. If there is a Gateway in the local network, this class will automaticaly detect
|
||||
{Brennenstuhl 433 MHz LAN Gateway}. If there is a Gateway in the local network, this class will automatically detect
|
||||
it and will be used. If both transmitter are available (Gateway + GPIO), each signal will be transmitted over both sender.
|
||||
|
||||
\note: Radio 433 on GPIO's is by default disabled. If you want to enable it, you need to compile the source with the qmake config \tt{CONFIG+=radio433gpio}
|
||||
@ -51,7 +51,7 @@
|
||||
*/
|
||||
|
||||
/*! \fn bool Radio433::sendData(int delay, QList<int> rawData, int repetitions);
|
||||
Returns true if the given \a rawData can be sent to a RF 433MHz device with the given \a delay. The amount of packages to send can be configured with the paramter \a repetitions.
|
||||
Returns true if the given \a rawData can be sent to a RF 433MHz device with the given \a delay. The amount of packages to send can be configured with the parameter \a repetitions.
|
||||
*/
|
||||
|
||||
|
||||
|
||||
@ -54,11 +54,11 @@
|
||||
|
||||
// Signals
|
||||
/*! \fn bool HardwareResource::enabledChanged(bool enabled);
|
||||
This signal will be emited if the hardware resource was \a enabled or disabled.
|
||||
This signal will be emitted if the hardware resource was \a enabled or disabled.
|
||||
*/
|
||||
|
||||
/*! \fn bool HardwareResource::availableChanged(bool available);
|
||||
This signal will be emited if the hardware resource \a available changed.
|
||||
This signal will be emitted if the hardware resource \a available changed.
|
||||
*/
|
||||
|
||||
#include "hardwareresource.h"
|
||||
|
||||
@ -72,7 +72,7 @@
|
||||
*/
|
||||
|
||||
/*! \fn QList<UpnpDeviceDescriptor> UpnpDiscoveryReply::deviceDescriptors() const;
|
||||
Returns the list of found \l{UpnpDeviceDescriptor}{UpnpDeviceDescriptors}. This list will be empty if an error occured.
|
||||
Returns the list of found \l{UpnpDeviceDescriptor}{UpnpDeviceDescriptors}. This list will be empty if an error occurred.
|
||||
|
||||
\sa finished()
|
||||
*/
|
||||
@ -82,8 +82,8 @@
|
||||
This signal will be emitted once the UpnpDiscoveryReply is finished.
|
||||
*/
|
||||
|
||||
/*! \fn void UpnpDiscoveryReply::errorOccured(const UpnpDiscoveryReplyError &error);
|
||||
This signal will be emitted once an UpnpDiscoveryReply \a error occured.
|
||||
/*! \fn void UpnpDiscoveryReply::errorOccurred(const UpnpDiscoveryReplyError &error);
|
||||
This signal will be emitted once an UpnpDiscoveryReply \a error occurred.
|
||||
*/
|
||||
|
||||
#include "upnpdiscoveryreply.h"
|
||||
|
||||
@ -53,7 +53,7 @@ public:
|
||||
|
||||
signals:
|
||||
void finished();
|
||||
void errorOccured(const UpnpDiscoveryReplyError &error);
|
||||
void errorOccurred(const UpnpDiscoveryReplyError &error);
|
||||
|
||||
};
|
||||
|
||||
|
||||
@ -98,23 +98,23 @@
|
||||
|
||||
// Signals
|
||||
/*! \fn void PluginTimer::timeout();
|
||||
This signal will be emited if the timer timeouted.
|
||||
This signal will be emitted if the timer timeouted.
|
||||
*/
|
||||
|
||||
/*! \fn void PluginTimer::currentTickChanged(const int ¤tTick);
|
||||
This signal will be emited whenever the \a currentTick of this PluginTimer changed.
|
||||
This signal will be emitted whenever the \a currentTick of this PluginTimer changed.
|
||||
|
||||
\sa currentTick()
|
||||
*/
|
||||
|
||||
/*! \fn void PluginTimer::runningChanged(const bool &running);
|
||||
This signal will be emited whenever the \a running status of this PluginTimer changed.
|
||||
This signal will be emitted whenever the \a running status of this PluginTimer changed.
|
||||
|
||||
\sa running()
|
||||
*/
|
||||
|
||||
/*! \fn void PluginTimer::pausedChanged(const bool &paused);
|
||||
This signal will be emited whenever the \a paused status of this PluginTimer changed.
|
||||
This signal will be emitted whenever the \a paused status of this PluginTimer changed.
|
||||
|
||||
\sa running()
|
||||
*/
|
||||
|
||||
@ -85,7 +85,7 @@ ParamList Action::params() const
|
||||
return m_params;
|
||||
}
|
||||
|
||||
/*! Set the the parameters for this Action. \a params must match the template in the \l{ActionType}
|
||||
/*! Set the parameters for this Action. \a params must match the template in the \l{ActionType}
|
||||
* referred by \l{Action::actionTypeId()}. */
|
||||
void Action::setParams(const ParamList ¶ms)
|
||||
{
|
||||
|
||||
@ -43,7 +43,7 @@
|
||||
\value CreateMethodUser
|
||||
The user will specify the \l{Param}s.
|
||||
\value CreateMethodAuto
|
||||
The device will be created automaticaly.
|
||||
The device will be created automatically.
|
||||
\value CreateMethodDiscovery
|
||||
The device will be discovered and added by the user by selecting the DeviceDescriptorId from the list of discovered possible ones.
|
||||
*/
|
||||
|
||||
@ -35,7 +35,7 @@
|
||||
|
||||
#include <QDebug>
|
||||
|
||||
/*! Constructs a \l Param with the given \a paramTypeId and \a value of the paramter. */
|
||||
/*! Constructs a \l Param with the given \a paramTypeId and \a value of the parameter. */
|
||||
Param::Param(const ParamTypeId ¶mTypeId, const QVariant &value):
|
||||
m_paramTypeId(paramTypeId),
|
||||
m_value(value)
|
||||
|
||||
@ -205,7 +205,7 @@ void ParamType::setReadOnly(const bool &readOnly)
|
||||
m_readOnly = readOnly;
|
||||
}
|
||||
|
||||
/*! Returns true if this ParamType is valid. A ParamType is valid, if the the id, the name and the data type is set. */
|
||||
/*! Returns true if this ParamType is valid. A ParamType is valid, if the id, the name and the data type is set. */
|
||||
bool ParamType::isValid() const
|
||||
{
|
||||
return !m_id.isNull() && !m_name.isEmpty() && m_type != QVariant::Invalid;
|
||||
|
||||
@ -6,7 +6,7 @@ NYMEA_PLUGINS_PATH=/usr/lib/$$system('dpkg-architecture -q DEB_HOST_MULTIARCH')/
|
||||
|
||||
# define protocol versions
|
||||
JSON_PROTOCOL_VERSION_MAJOR=1
|
||||
JSON_PROTOCOL_VERSION_MINOR=3
|
||||
JSON_PROTOCOL_VERSION_MINOR=4
|
||||
REST_API_VERSION=1
|
||||
|
||||
DEFINES += NYMEA_VERSION_STRING=\\\"$${NYMEA_VERSION_STRING}\\\" \
|
||||
|
||||
@ -570,7 +570,7 @@ int QtServiceBasePrivate::run(bool asService, const QStringList &argList)
|
||||
\row \li -e \li -exec
|
||||
\li Execute the service as a standalone application (useful for debug purposes).
|
||||
This is a blocking call, the service will be executed like a normal application.
|
||||
In this mode you will not be able to communicate with the service from the contoller.
|
||||
In this mode you will not be able to communicate with the service from the controller.
|
||||
\row \li -t \li -terminate \li Stop the service.
|
||||
\row \li -p \li -pause \li Pause the service.
|
||||
\row \li -r \li -resume \li Resume a paused service.
|
||||
|
||||
@ -145,7 +145,7 @@ void TestActions::getActionType()
|
||||
verifyDeviceError(response, error);
|
||||
|
||||
if (error == DeviceManager::DeviceErrorNoError) {
|
||||
QVERIFY2(ActionTypeId(response.toMap().value("params").toMap().value("actionType").toMap().value("id").toString()) == actionTypeId, "Didnt get reply for same actionTypeId as requested.");
|
||||
QVERIFY2(ActionTypeId(response.toMap().value("params").toMap().value("actionType").toMap().value("id").toString()) == actionTypeId, "Didn't get a reply for the same actionTypeId as requested.");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
1.3
|
||||
1.4
|
||||
{
|
||||
"methods": {
|
||||
"Actions.ExecuteAction": {
|
||||
@ -681,7 +681,7 @@
|
||||
}
|
||||
},
|
||||
"Rules.DisableRule": {
|
||||
"description": "Disable a rule. The rule won't be triggered by it's events or state changes while it is disabled. If successfull, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"description": "Disable a rule. The rule won't be triggered by it's events or state changes while it is disabled. If successful, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"params": {
|
||||
"ruleId": "Uuid"
|
||||
},
|
||||
@ -690,7 +690,7 @@
|
||||
}
|
||||
},
|
||||
"Rules.EditRule": {
|
||||
"description": "Edit the parameters of a rule. The configuration of the rule with the given ruleId will be replaced with the new given configuration. In ordert to enable or disable a Rule, please use the methods \"Rules.EnableRule\" and \"Rules.DisableRule\". If successfull, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"description": "Edit the parameters of a rule. The configuration of the rule with the given ruleId will be replaced with the new given configuration. In ordert to enable or disable a Rule, please use the methods \"Rules.EnableRule\" and \"Rules.DisableRule\". If successful, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"params": {
|
||||
"actions": [
|
||||
"$ref:RuleAction"
|
||||
@ -714,7 +714,7 @@
|
||||
}
|
||||
},
|
||||
"Rules.EnableRule": {
|
||||
"description": "Enabled a rule that has previously been disabled.If successfull, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"description": "Enabled a rule that has previously been disabled.If successful, the notification \"Rule.RuleConfigurationChanged\" will be emitted.",
|
||||
"params": {
|
||||
"ruleId": "Uuid"
|
||||
},
|
||||
|
||||
@ -448,7 +448,7 @@ void CoapTests::largeCreate()
|
||||
reply->deleteLater();
|
||||
spy.clear();
|
||||
|
||||
// check if the upload was realy successfull
|
||||
// check if the upload was really successful
|
||||
reply = m_coap->get(request);
|
||||
spy.wait(20000);
|
||||
|
||||
@ -482,7 +482,7 @@ void CoapTests::largeUpdate()
|
||||
reply->deleteLater();
|
||||
spy.clear();
|
||||
|
||||
// check if the upload was successfull
|
||||
// check if the upload was successful
|
||||
reply = m_coap->get(request);
|
||||
spy.wait(20000);
|
||||
|
||||
|
||||
@ -246,7 +246,7 @@ void TestConfigurations::testLanguages()
|
||||
response = injectAndWait("Configuration.GetAvailableLanguages");
|
||||
QVERIFY2(response.toMap().value("params").toMap().contains("languages"), "Did not get list of languages");
|
||||
QVariantMap responseMap = response.toMap().value("params").toMap();
|
||||
QVERIFY2(responseMap.value("languages").toList().count() >= 2, "Avaliable languages list to short: " + responseMap.value("languages").toList().count());
|
||||
QVERIFY2(responseMap.value("languages").toList().count() >= 2, "Available languages list to short: " + responseMap.value("languages").toList().count());
|
||||
|
||||
QVariantList languageVariantList = responseMap.value("languages").toList();
|
||||
foreach (const QVariant &languageVariant, languageVariantList) {
|
||||
@ -263,7 +263,7 @@ void TestConfigurations::testLanguages()
|
||||
notificationSpy.wait(500);
|
||||
QVariantList languageChangedNotifications = checkNotifications(notificationSpy, "Configuration.LanguageChanged");
|
||||
|
||||
// If the language did not change no notification should be emited
|
||||
// If the language did not change no notification should be emitted
|
||||
if (basicConfigurationMap.value("language").toString() == languageVariant.toString()) {
|
||||
QVERIFY2(languageChangedNotifications.count() == 0, "Got Configuration.LanguageChanged notification but should have not.");
|
||||
} else {
|
||||
|
||||
@ -951,7 +951,7 @@ void TestDevices::reconfigureDevices()
|
||||
response = injectAndWait("Devices.ReconfigureDevice", editParams);
|
||||
verifyDeviceError(response, deviceError);
|
||||
|
||||
// if the edit should have been successfull
|
||||
// if the edit should have been successful
|
||||
if (deviceError == DeviceManager::DeviceErrorNoError) {
|
||||
response = injectAndWait("Devices.GetConfiguredDevices", QVariantMap());
|
||||
|
||||
@ -1167,7 +1167,7 @@ void TestDevices::reconfigureByDiscovery()
|
||||
QVERIFY2(reply->error(), "The old daemon is still running");
|
||||
reply->deleteLater();
|
||||
|
||||
// check if the daemon is realy running on the new port
|
||||
// check if the daemon is really running on the new port
|
||||
request = QNetworkRequest(QUrl(QString("http://localhost:%1").arg(55556)));
|
||||
reply = nam.get(request);
|
||||
spy.wait();
|
||||
|
||||
@ -141,7 +141,7 @@ void TestEvents::getEventType()
|
||||
verifyDeviceError(response, error);
|
||||
|
||||
if (error == DeviceManager::DeviceErrorNoError) {
|
||||
QVERIFY2(EventTypeId(response.toMap().value("params").toMap().value("eventType").toMap().value("id").toString()) == eventTypeId, "Didnt get reply for same actionTypeId as requested.");
|
||||
QVERIFY2(EventTypeId(response.toMap().value("params").toMap().value("eventType").toMap().value("id").toString()) == eventTypeId, "Didn't get a reply for the same actionTypeId as requested.");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -90,7 +90,7 @@ void TestRestDeviceClasses::getSupportedDevices()
|
||||
QUrl url("https://localhost:3333/api/v1/deviceclasses");
|
||||
QVariant response = getAndWait(QNetworkRequest(url));
|
||||
QVariantList deviceClassesList = response.toList();
|
||||
QVERIFY2(deviceClassesList.count() > 0, "Not enought deviceclasses.");
|
||||
QVERIFY2(deviceClassesList.count() > 0, "Not enough deviceclasses.");
|
||||
|
||||
// Get each of thouse devices individualy
|
||||
foreach (const QVariant &deviceClass, deviceClassesList) {
|
||||
@ -110,7 +110,7 @@ void TestRestDeviceClasses::getSupportedDevices()
|
||||
|
||||
response = getAndWait(QNetworkRequest(url));
|
||||
deviceClassesList = response.toList();
|
||||
QVERIFY2(deviceClassesList.count() > 0, "Not enought deviceclasses.");
|
||||
QVERIFY2(deviceClassesList.count() > 0, "Not enough deviceclasses.");
|
||||
|
||||
// get with invalid vendor filter
|
||||
query.clear();
|
||||
|
||||
@ -99,7 +99,7 @@ void TestRestDevices::getConfiguredDevices()
|
||||
QVariant response = getAndWait(QNetworkRequest(QUrl("https://localhost:3333/api/v1/devices")));
|
||||
QVERIFY2(!response.isNull(), "Could not get device");
|
||||
QVariantList deviceList = response.toList();
|
||||
QVERIFY2(deviceList.count() >= 2, "not enought devices.");
|
||||
QVERIFY2(deviceList.count() >= 2, "not enough devices.");
|
||||
|
||||
// Get each of those devices individualy
|
||||
foreach (const QVariant &device, deviceList) {
|
||||
@ -682,7 +682,7 @@ void TestRestDevices::reconfigureDevices()
|
||||
response = putAndWait(request, editParams, expectedStatusCode);
|
||||
QVERIFY2(!response.isNull(), "Could not read edit device response");
|
||||
|
||||
// if the reconfigure should have been successfull
|
||||
// if the reconfigure should have been successful
|
||||
if (expectedStatusCode == 200) {
|
||||
request.setUrl(QUrl(QString("https://localhost:3333/api/v1/devices/%1").arg(deviceId.toString())));
|
||||
request.setHeader(QNetworkRequest::ContentTypeHeader, "text/json");
|
||||
|
||||
@ -82,7 +82,7 @@ void TestRestPlugins::getPlugins()
|
||||
// Get all plugins
|
||||
QVariant response = getAndWait(QNetworkRequest(QUrl("https://localhost:3333/api/v1/plugins")));
|
||||
QVariantList pluginList = response.toList();
|
||||
QVERIFY2(pluginList.count() > 0, "Not enought plugins.");
|
||||
QVERIFY2(pluginList.count() > 0, "Not enough plugins.");
|
||||
|
||||
// Get each of thouse plugins individualy
|
||||
foreach (const QVariant &plugin, pluginList) {
|
||||
|
||||
@ -221,7 +221,7 @@ void TestRestRules::getRules()
|
||||
// Get all rules
|
||||
QVariant response = getAndWait(QNetworkRequest(QUrl("https://localhost:3333/api/v1/rules")));
|
||||
QVariantList rulesList = response.toList();
|
||||
QVERIFY2(rulesList.count() == 0, "Not enought rules");
|
||||
QVERIFY2(rulesList.count() == 0, "Not enough rules");
|
||||
|
||||
foreach (const QVariant &rule, rulesList) {
|
||||
QVariantMap ruleMap = rule.toMap();
|
||||
@ -491,7 +491,7 @@ void TestRestRules::addRemoveRules_data()
|
||||
|
||||
// Rules without exit actions
|
||||
QTest::newRow("valid rule. enabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << true << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << 200 << true << "TestRule";
|
||||
QTest::newRow("valid rule. diabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << false << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << 200 << true << "TestRule";
|
||||
QTest::newRow("valid rule. disabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << false << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << 200 << true << "TestRule";
|
||||
QTest::newRow("valid rule. 2 EventDescriptors, 1 Action, name") << true << validActionNoParams << QVariantMap() << QVariantMap() << eventDescriptorList << validStateEvaluator << 200 << true << "TestRule";
|
||||
QTest::newRow("invalid action") << true << invalidAction << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << 400 << false << "TestRule";
|
||||
QTest::newRow("invalid event descriptor") << true << validActionNoParams << QVariantMap() << invalidEventDescriptor << QVariantList() << validStateEvaluator << 400 << false << "TestRule";
|
||||
@ -723,7 +723,7 @@ void TestRestRules::editRules_data()
|
||||
|
||||
// Rules without exit actions
|
||||
QTest::newRow("valid rule. enabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << true << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << 200 << "TestRule";
|
||||
QTest::newRow("valid rule. diabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << false << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << 200 << "TestRule";
|
||||
QTest::newRow("valid rule. disabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << false << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << 200 << "TestRule";
|
||||
QTest::newRow("valid rule. 2 EventDescriptors, 1 Action, name") << true << validActionNoParams << QVariantMap() << QVariantMap() << eventDescriptorList << validStateEvaluator << 200 << "TestRule";
|
||||
}
|
||||
|
||||
|
||||
@ -77,7 +77,7 @@ void TestRestVendors::getVendors()
|
||||
// Get all vendors
|
||||
QVariant response = getAndWait(QNetworkRequest(QUrl("https://localhost:3333/api/v1/vendors")));
|
||||
QVariantList vendorList = response.toList();
|
||||
QVERIFY2(vendorList.count() > 0, "Not enought vendors.");
|
||||
QVERIFY2(vendorList.count() > 0, "Not enough vendors.");
|
||||
|
||||
// Get each of thouse vendors individualy
|
||||
foreach (const QVariant &vendor, vendorList) {
|
||||
|
||||
@ -492,7 +492,7 @@ void TestRules::addRemoveRules_data()
|
||||
|
||||
// Rules without exit actions
|
||||
QTest::newRow("valid rule. enabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << true << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << RuleEngine::RuleErrorNoError << true << "TestRule";
|
||||
QTest::newRow("valid rule. diabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << false << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << RuleEngine::RuleErrorNoError << true << "TestRule";
|
||||
QTest::newRow("valid rule. disabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << false << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << RuleEngine::RuleErrorNoError << true << "TestRule";
|
||||
QTest::newRow("valid rule. 2 EventDescriptors, 1 Action, name") << true << validActionNoParams << QVariantMap() << QVariantMap() << eventDescriptorList << validStateEvaluator << RuleEngine::RuleErrorNoError << true << "TestRule";
|
||||
QTest::newRow("invalid action") << true << invalidAction << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << RuleEngine::RuleErrorActionTypeNotFound << false << "TestRule";
|
||||
QTest::newRow("invalid event descriptor") << true << validActionNoParams << QVariantMap() << invalidEventDescriptor << QVariantList() << validStateEvaluator << RuleEngine::RuleErrorEventTypeNotFound << false << "TestRule";
|
||||
@ -560,10 +560,10 @@ void TestRules::addRemoveRules()
|
||||
QVERIFY2(rule.value("enabled").toBool() == enabled, "Rule enabled state doesn't match");
|
||||
QVariantList eventDescriptors = rule.value("eventDescriptors").toList();
|
||||
if (!eventDescriptor.isEmpty()) {
|
||||
QVERIFY2(eventDescriptors.count() == 1, "There shoud be exactly one eventDescriptor");
|
||||
QVERIFY2(eventDescriptors.count() == 1, "There should be exactly one eventDescriptor");
|
||||
QVERIFY2(eventDescriptors.first().toMap() == eventDescriptor, "Event descriptor doesn't match");
|
||||
} else if (eventDescriptorList.isEmpty()){
|
||||
QVERIFY2(eventDescriptors.count() == eventDescriptorList.count(), QString("There shoud be exactly %1 eventDescriptor").arg(eventDescriptorList.count()).toLatin1().data());
|
||||
QVERIFY2(eventDescriptors.count() == eventDescriptorList.count(), QString("There should be exactly %1 eventDescriptor").arg(eventDescriptorList.count()).toLatin1().data());
|
||||
foreach (const QVariant &eventDescriptorVariant, eventDescriptorList) {
|
||||
bool found = false;
|
||||
foreach (const QVariant &replyEventDescriptorVariant, eventDescriptors) {
|
||||
@ -733,7 +733,7 @@ void TestRules::editRules_data()
|
||||
|
||||
// Rules without exit actions
|
||||
QTest::newRow("valid rule. enabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << true << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << RuleEngine::RuleErrorNoError << "TestRule";
|
||||
QTest::newRow("valid rule. diabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << false << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << RuleEngine::RuleErrorNoError << "TestRule";
|
||||
QTest::newRow("valid rule. disabled, 1 EventDescriptor, StateEvaluator, 1 Action, name") << false << validActionNoParams << QVariantMap() << validEventDescriptor1 << QVariantList() << validStateEvaluator << RuleEngine::RuleErrorNoError << "TestRule";
|
||||
QTest::newRow("valid rule. 2 EventDescriptors, 1 Action, name") << true << validActionNoParams << QVariantMap() << QVariantMap() << eventDescriptorList << validStateEvaluator << RuleEngine::RuleErrorNoError << "TestRule";
|
||||
}
|
||||
|
||||
@ -891,10 +891,10 @@ void TestRules::editRules()
|
||||
QVERIFY2(rule.value("enabled").toBool() == enabled, "Rule enabled state doesn't match");
|
||||
QVariantList eventDescriptors = rule.value("eventDescriptors").toList();
|
||||
if (!eventDescriptor.isEmpty()) {
|
||||
QVERIFY2(eventDescriptors.count() == 1, "There shoud be exactly one eventDescriptor");
|
||||
QVERIFY2(eventDescriptors.count() == 1, "There should be exactly one eventDescriptor");
|
||||
QVERIFY2(eventDescriptors.first().toMap() == eventDescriptor, "Event descriptor doesn't match");
|
||||
} else if (eventDescriptorList.isEmpty()){
|
||||
QVERIFY2(eventDescriptors.count() == eventDescriptorList.count(), QString("There shoud be exactly %1 eventDescriptor").arg(eventDescriptorList.count()).toLatin1().data());
|
||||
QVERIFY2(eventDescriptors.count() == eventDescriptorList.count(), QString("There should be exactly %1 eventDescriptor").arg(eventDescriptorList.count()).toLatin1().data());
|
||||
foreach (const QVariant &eventDescriptorVariant, eventDescriptorList) {
|
||||
bool found = false;
|
||||
foreach (const QVariant &replyEventDescriptorVariant, eventDescriptors) {
|
||||
@ -1202,7 +1202,7 @@ void TestRules::loadStoreConfig()
|
||||
QVariantMap rule1 = response.toMap().value("params").toMap().value("rule").toMap();
|
||||
|
||||
QVariantList eventDescriptors = rule1.value("eventDescriptors").toList();
|
||||
QVERIFY2(eventDescriptors.count() == 2, "There shoud be exactly 2 eventDescriptors");
|
||||
QVERIFY2(eventDescriptors.count() == 2, "There should be exactly 2 eventDescriptors");
|
||||
foreach (const QVariant &expectedEventDescriptorVariant, eventDescriptorList) {
|
||||
bool found = false;
|
||||
foreach (const QVariant &replyEventDescriptorVariant, eventDescriptors) {
|
||||
@ -1221,7 +1221,7 @@ void TestRules::loadStoreConfig()
|
||||
QVERIFY2(rule1.value("name").toString() == "TestRule", "Loaded wrong name for rule");
|
||||
QVariantMap replyStateEvaluator= rule1.value("stateEvaluator").toMap();
|
||||
QVariantList replyChildEvaluators = replyStateEvaluator.value("childEvaluators").toList();
|
||||
QVERIFY2(replyChildEvaluators.count() == 2, "There shoud be exactly 2 childEvaluators");
|
||||
QVERIFY2(replyChildEvaluators.count() == 2, "There should be exactly 2 childEvaluators");
|
||||
QVERIFY2(replyStateEvaluator.value("operator") == "StateOperatorAnd", "There should be the AND operator.");
|
||||
|
||||
foreach (const QVariant &childEvaluator, replyChildEvaluators) {
|
||||
@ -1262,7 +1262,7 @@ void TestRules::loadStoreConfig()
|
||||
QVariantMap replyStateEvaluator2= rule2.value("stateEvaluator").toMap();
|
||||
QVariantList replyChildEvaluators2 = replyStateEvaluator.value("childEvaluators").toList();
|
||||
QVERIFY2(replyStateEvaluator2.value("operator") == "StateOperatorAnd", "There should be the AND operator.");
|
||||
QVERIFY2(replyChildEvaluators2.count() == 2, "There shoud be exactly 2 childEvaluators");
|
||||
QVERIFY2(replyChildEvaluators2.count() == 2, "There should be exactly 2 childEvaluators");
|
||||
|
||||
foreach (const QVariant &childEvaluator, replyChildEvaluators2) {
|
||||
QVERIFY2(childEvaluator.toMap().contains("stateDescriptor"), "StateDescriptor missing in StateEvaluator");
|
||||
@ -1322,7 +1322,7 @@ void TestRules::loadStoreConfig()
|
||||
qDebug() << rule3;
|
||||
|
||||
QVariantList eventDescriptors3 = rule3.value("eventDescriptors").toList();
|
||||
QVERIFY2(eventDescriptors3.count() == 1, "There shoud be exactly 1 eventDescriptor");
|
||||
QVERIFY2(eventDescriptors3.count() == 1, "There should be exactly 1 eventDescriptor");
|
||||
QVariantMap eventDescriptor = eventDescriptors3.first().toMap();
|
||||
QVERIFY2(eventDescriptor.value("eventTypeId").toString() == mockEvent2Id.toString(), "Loaded the wrong eventTypeId in rule 3");
|
||||
QVERIFY2(eventDescriptor.value("deviceId").toString() == m_mockDeviceId.toString(), "Loaded the wrong deviceId from eventDescriptor in rule 3");
|
||||
@ -1958,7 +1958,7 @@ void TestRules::testEventBasedAction()
|
||||
reply->deleteLater();
|
||||
|
||||
verifyRuleExecuted(mockActionIdWithParams);
|
||||
// TODO: check if this action was realy executed with the int state value 42
|
||||
// TODO: check if this action was really executed with the int state value 42
|
||||
}
|
||||
|
||||
void TestRules::removePolicyUpdate()
|
||||
|
||||
@ -1696,7 +1696,7 @@ void TestTimeManager::testEventItemYearly()
|
||||
NymeaCore::instance()->timeManager()->setTime(dateTime.addSecs(60));
|
||||
verifyRuleNotExecuted();
|
||||
|
||||
// Tick next year, one minute bofore, on time, one minute after
|
||||
// Tick next year, one minute before, on time, one minute after
|
||||
QDateTime nextYear = dateTime.addYears(1);
|
||||
|
||||
// not triggering
|
||||
|
||||
Reference in New Issue
Block a user