public interface DeviceService
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
PROP_CYCLE_COUNTER |
static java.lang.String |
PROP_DATA_ENTRY |
static java.lang.String |
PROP_DEVICE_ID |
static java.lang.String |
PROP_DEVICE_STATUS |
static java.lang.String |
TOPIC_ALL_DATA_ENTRY |
static java.lang.String |
TOPIC_CHANGE_DATA_ENTRY |
static java.lang.String |
TOPIC_DATA_ENTRY |
static java.lang.String |
TOPIC_DEVICE |
static java.lang.String |
TOPIC_DEVICE_ALL_ENTRIES |
static java.lang.String |
TOPIC_DEVICE_LIFECYCLE |
static java.lang.String |
TOPIC_DEVICE_REMOVE |
static java.lang.String |
TOPIC_DEVICE_UPDATE |
| Modifier and Type | Method and Description |
|---|---|
DeviceConfiguration |
getConfiguration() |
java.util.List<DeviceConfiguration> |
getConfigurations() |
DataEntry |
getCurrentDataEntry(java.util.Date timestamp) |
java.util.List<DataEntry> |
getDataEntries(java.util.Date startDate,
java.util.Date endDate)
Retrieves the list of DataEntry within the provided time range for the Device associated with the DeviceService
instance.
|
Device |
getDevice() |
java.lang.String |
getDeviceId() |
LifeCycleDeviceType |
getStatus() |
void |
initialize(boolean forceReload,
boolean forceRestart)
Initializes the device manually.
|
boolean |
isRunning() |
boolean |
startDevice()
Starts the Device associated with the DeviceService instance, if it is not running yet, and if it was possible
to start.
|
boolean |
stopDevice()
Stops the Device associated with the DeviceService instance, in case it was running.
|
Device |
updateDevice(Device device)
Updates the Device associated with the DeviceService instance with the given Device.
|
DeviceConfiguration |
updateDeviceConfiguration(DeviceConfiguration configuration)
Updates the DeviceConfiguration associated with the current device.
|
DeviceInfo |
updateDeviceInformation(DeviceInfo info)
Updates the DeviceInfo associated with the current device.
|
static final java.lang.String TOPIC_DEVICE
static final java.lang.String TOPIC_DEVICE_UPDATE
static final java.lang.String TOPIC_DEVICE_REMOVE
static final java.lang.String TOPIC_DEVICE_LIFECYCLE
static final java.lang.String PROP_DEVICE_ID
static final java.lang.String PROP_DEVICE_STATUS
static final java.lang.String TOPIC_DATA_ENTRY
static final java.lang.String TOPIC_ALL_DATA_ENTRY
static final java.lang.String TOPIC_CHANGE_DATA_ENTRY
static final java.lang.String TOPIC_DEVICE_ALL_ENTRIES
static final java.lang.String PROP_DATA_ENTRY
static final java.lang.String PROP_CYCLE_COUNTER
LifeCycleDeviceType getStatus()
Device getDevice()
java.lang.String getDeviceId()
void initialize(boolean forceReload,
boolean forceRestart)
throws DeviceException
forceReload - forces to reload all data, independent from current running stateforceRestart - forces to restart a simulation, if it currently runningDeviceExceptionDevice updateDevice(Device device)
device - the updated Device to be savedDeviceConfiguration updateDeviceConfiguration(DeviceConfiguration configuration)
configuration - the new ConfigurationDeviceInfo updateDeviceInformation(DeviceInfo info)
info - the new DeviceInfoDeviceConfiguration getConfiguration()
java.util.List<DeviceConfiguration> getConfigurations()
boolean isRunning()
true if the Device associated with the DeviceService instance is running, false
otherwiseboolean startDevice()
throws DeviceException
DeviceExceptionboolean stopDevice()
throws DeviceException
DeviceExceptionjava.util.List<DataEntry> getDataEntries(java.util.Date startDate,
java.util.Date endDate)
startDate - the start dateendDate - the end dateDataEntry getCurrentDataEntry(java.util.Date timestamp)
timestamp - the DateData In Motion GmbH all rights reserved