- Copyright:
- Kiwigrid GmbH 2014-2020
- Source:
Classes
Methods
- <inner> pollDevices(eventBus, queryParameters, changeEventProcessor, intervalSeconds) → {void}
- <inner> pollTagValues(eventBus, queryParameters, tagValuesProcessor, intervalSeconds) → {void}
-
<inner> pollDevices(eventBus, queryParameters, changeEventProcessor, intervalSeconds) → {void}
-
Poll devices defined by the query parameters in the specified interval.
If a device matching the query changes, an event is emitted to the processing function.
This function is intended as a temporary replacement for the removed registerDeviceSetListener endpoint of the device service.
Parameters:
Name Type Argument Default Description eventBusEventBus An event bus instance to communicate with the device service queryParametersObject An object containing the parameters for the device service endpoint to query devices changeEventProcessorfunction A function receiving an emitted device event upon a change in matching devices intervalSecondsnumber <optional>
15 The time between each query - Source:
Returns:
void -
<inner> pollTagValues(eventBus, queryParameters, tagValuesProcessor, intervalSeconds) → {void}
-
Poll tag values defined by the device query parameters in the specified interval.
If a device matching the query is added or changes, its tag values are emitted to the processing function.
This function is intended as a temporary replacement for the removed registerTagValueListener endpoint of the device service.
Parameters:
Name Type Argument Default Description eventBusEventBus An event bus instance to communicate with the device service queryParametersObject An object containing the parameters for the device service endpoint to query devices tagValuesProcessorfunction A function receiving the emitted array of tag values upon changes in matching devices intervalSecondsnumber <optional>
15 The time between each query - Source:
Returns:
void