public class TimeseriesClient extends MindsphereAPIClient
| Modifier and Type | Class and Description |
|---|---|
static class |
TimeseriesClient.ClientBuilder |
MindsphereAPIClient.Builder<T extends MindsphereAPIClient.Builder<T>>credentials, restClientConfig, restTemplate| Constructor and Description |
|---|
TimeseriesClient(TimeseriesClient.ClientBuilder builder) |
| Modifier and Type | Method and Description |
|---|---|
static TimeseriesClient.ClientBuilder |
builder() |
boolean |
deleteTimeseries(String entity,
String propertySetName,
Date from,
Date to,
Boolean sync)
Invoking Service API to :
Delete time series data for a single entity and propertyset within a given time range. |
boolean |
deleteTimeseries(String entity,
String propertySetName,
String from,
String to,
Boolean sync)
Invoking Service API to :
Delete time series data for a single entity and propertyset within a given time range. |
TimeseriesData |
getLatestTimeseries(String entity,
String propertySetName)
Invokes Service API to :
Read time series data for a single entity and propertyset. |
List<TimeseriesData> |
getTimeseries(String entity,
String propertySetName,
Date from,
Date to,
Integer limit,
String select)
Invokes Service API to :
Read time series data for a single entity and propertyset. |
List<TimeseriesData> |
getTimeseries(String entity,
String propertySetName,
String from,
String to,
Integer limit,
String select)
Invokes Service API to :
Read time series data for a single entity and propertyset. |
boolean |
importTimeseries(String entity,
String propertySetName,
File timeSeriesDataFile,
Boolean sync)
Invokes Service API to :
Write or update time series data for a single entity and propertyset. |
boolean |
putTimeseries(String entity,
String propertySetName,
List<TimeseriesData> timeSeriesList,
Boolean sync)
Invokes Service API to :
Write or update time series data for a single entity and propertyset. |
boolean |
putTimeseries(String entity,
String propertySetName,
String timeSeriesList,
Boolean sync)
Invokes Service API to :
Write or update time series data for a single entity and propertyset. |
public TimeseriesClient(TimeseriesClient.ClientBuilder builder)
public static TimeseriesClient.ClientBuilder builder()
public List<TimeseriesData> getTimeseries(String entity, String propertySetName, String from, String to, Integer limit, String select) throws MindsphereException
Response Status Codes
200 - Array of time series
400 - Bad request, in case of invalid parameters
401 - Unauthorized
404 - Entity not found
500 - Server error, for more information see errorcode and message
entity - Unique identifier of the entitypropertySetName - Name of the propertysetfrom - Beginning of the time range to read (exclusive)to - End of the time range to read (inclusive)limit - Maximum number of entries to readselect - Select fields to returnMindsphereException - thrown if an error occurs while attempting to invoke the APIpublic TimeseriesData getLatestTimeseries(String entity, String propertySetName) throws MindsphereException
Response Status Codes
200 - Array of time series
400 - Bad request, in case of invalid parameters
401 - Unauthorized
404 - Entity not found
500 - Server error, for more information see errorcode and message
entity - Unique identifier of the entitypropertySetName - Name of the propertysetMindsphereException - thrown if an error occurs while attempting to invoke the APIpublic List<TimeseriesData> getTimeseries(String entity, String propertySetName, Date from, Date to, Integer limit, String select) throws MindsphereException
Response Status Codes
200 - Array of time series
400 - Bad request, in case of invalid parameters
401 - Unauthorized
404 - Entity not found
500 - Server error, for more information see errorcode and message
entity - Unique identifier of the entitypropertySetName - Name of the propertysetfrom - Beginning of the time range to read in Date format(exclusive)to - End of the time range to read Date format (inclusive)limit - Maximum number of entries to readselect - Select fields to returnMindsphereException - thrown if an error occurs while attempting to invoke the APIpublic boolean putTimeseries(String entity,
String propertySetName,
String timeSeriesList,
Boolean sync)
throws MindsphereException
Response Status Codes
204 - timeseries written successfully
400 - Bad request, in case the resource is invalid
401 - Unauthorized
404 - Entity not found
500 - Server error, for more information see errorcode and message
entity - Unique identifier of the entitypropertySetName - Name of the propertysettimeSeriesList - JSON Stringsync - set this parameter to true for direct write to db storeMindsphereException - thrown if an error occurs while attempting to invoke the APIpublic boolean putTimeseries(String entity,
String propertySetName,
List<TimeseriesData> timeSeriesList,
Boolean sync)
throws MindsphereException
Response Status Codes
204 - timeseries written successfully
400 - Bad request, in case the resource is invalid
401 - Unauthorized
404 - Entity not found
500 - Server error, for more information see errorcode and message
entity - Unique identifier of the entitypropertySetName - Name of the propertysettimeSeriesList - List of TimeSeriesData objectssync - set this parameter to true for direct write to db storeMindsphereException - thrown if an error occurs while attempting to invoke the APIpublic boolean importTimeseries(String entity,
String propertySetName,
File timeSeriesDataFile,
Boolean sync)
throws MindsphereException
Response Status Codes
204 - timeseries written successfully
400 - Bad request, in case the resource is invalid
401 - Unauthorized
404 - Entity not found
500 - Server error, for more information see errorcode and message
entity - Unique identifier of the entitypropertySetName - Name of the propertysettimeSeriesDataFile - timeseries data as a Filesync - set this parameter to true for direct write to db storeMindsphereException - thrown if an error occurs while attempting to invoke the APIpublic boolean deleteTimeseries(String entity,
String propertySetName,
String from,
String to,
Boolean sync)
throws MindsphereException
Response Status Codes
204 - timeseries deleted successfully
400 - Bad request, in case the resource is invalid
401 - Unauthorized
404 - Entity not found
500 - Server error, for more information see errorcode and message
entity - Unique identifier of the entitypropertySetName - Name of the propertysetfrom - Beginning of the timerange to delete (exclusive)to - End of the timerange to delete (inclusive)sync - set this parameter to true for direct write to db storeMindsphereException - thrown if an error occurs while attempting to invoke the APIpublic boolean deleteTimeseries(String entity,
String propertySetName,
Date from,
Date to,
Boolean sync)
throws MindsphereException
Response Status Codes
204 - timeseries deleted successfully
400 - Bad request, in case the resource is invalid
401 - Unauthorized
404 - Entity not found
500 - Server error, for more information see errorcode and message
entity - Unique identifier of the entitypropertySetName - Name of the propertysetfrom - Beginning of the timerange in Date format to delete (exclusive)to - End of the timerange in Date format to delete (inclusive)sync - set this parameter to true for direct write to db storeMindsphereException - thrown if an error occurs while attempting to invoke the API