Package com.hivemq.adapter.sdk.api.data
Interface ProtocolAdapterDataSample
public interface ProtocolAdapterDataSample
Interface for data collected by a protocol adapter.
One sample can contain multiple data points (= tag values).
The actual data points can be added via the addDataPoint(DataPoint) method.
-
Method Summary
Modifier and TypeMethodDescriptionvoidaddDataPoint(@NotNull DataPoint dataPoint) Adds a new data point to this sample.voidaddDataPoint(@NotNull String tagName, @NotNull Object tagValue) Adds a new data point to this sample.
-
Method Details
-
getTimestamp
- Returns:
- the timestamp when this data sample was taken.
-
addDataPoint
Adds a new data point to this sample.- Parameters:
tagName- the name for this data point.tagValue- the value for this data point.
-
addDataPoint
Adds a new data point to this sample.- Parameters:
dataPoint- the data point.
-
getDataPoints
- Returns:
- a map which maps tagName to the list of data points for this tagName
-