public interface GenericDevice
AbstractDevice
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_HEIGHT
Default icon height, in px.
|
static int |
DEFAULT_WIDTH
Default icon width, in px.
|
static String |
DEVICE_SERIAL_NUMBER
Service property indicating the hardware serial number of the device.
|
static String |
FAULT_NO |
static String |
FAULT_PROPERTY_NAME |
static String |
FAULT_UNKNOWN |
static String |
FAULT_YES |
static String |
LOCATION_PROPERTY_NAME |
static String |
LOCATION_UNKNOWN |
static String |
STATE_ACTIVATED |
static String |
STATE_DEACTIVATED |
static String |
STATE_PROPERTY_NAME |
static String |
STATE_UNKNOWN |
Modifier and Type | Method and Description |
---|---|
void |
addListener(DeviceListener<?> listener)
Add the specified listener to the list of this device's listeners.
|
boolean |
constainsProperty(String propertyName)
Determines if the device contains a property definition with this name
|
void |
enterInZones(List<Zone> zones)
Callback notifying this device enters in one or more zones
|
String |
getFault()
Returns fault state of this device.
|
Set<String> |
getProperties()
Returns names of all properties which define the device state.
|
Object |
getPropertyValue(String propertyName)
Returns the specified property value.
|
String |
getSerialNumber()
Return the serial number of the device.
|
String |
getState()
Returns activation state of this device.
|
boolean |
hasPropertyValue(String propertyName)
Determines if a property has been set.
|
void |
leavingZones(List<Zone> zones)
Callback notifying this device leaves one or more zones
|
void |
removeListener(DeviceListener<?> listener)
Remove the specified listener from the list of this device's listeners.
|
boolean |
removeProperty(String propertyName)
Removes a property on this device.
|
void |
setFault(String fault)
Sets fault state of this device.
|
void |
setPropertyValue(String propertyName,
Object value)
Sets specified property value.
|
void |
setState(String state)
Sets activation state of this device.
|
static final String DEVICE_SERIAL_NUMBER
java.lang.String
getSerialNumber()
,
Constant Field Valuesstatic final String STATE_PROPERTY_NAME
static final String STATE_ACTIVATED
static final String STATE_DEACTIVATED
static final String STATE_UNKNOWN
static final String FAULT_PROPERTY_NAME
static final String FAULT_YES
static final String FAULT_NO
static final String FAULT_UNKNOWN
static final String LOCATION_PROPERTY_NAME
static final String LOCATION_UNKNOWN
static final int DEFAULT_WIDTH
static final int DEFAULT_HEIGHT
String getSerialNumber()
DEVICE_SERIAL_NUMBER
void addListener(DeviceListener<?> listener)
listener
- the listener to addvoid removeListener(DeviceListener<?> listener)
listener
- the listener to removeString getState()
void setState(String state)
state
- activation state to setString getFault()
void setFault(String fault)
fault
- Set<String> getProperties()
Object getPropertyValue(String propertyName)
propertyName
- void setPropertyValue(String propertyName, Object value)
propertyName
- value
- boolean constainsProperty(String propertyName)
propertyName
- the property nameboolean hasPropertyValue(String propertyName)
propertyName
- the property nameboolean removeProperty(String propertyName)
propertyName
- the property namevoid enterInZones(List<Zone> zones)
zones
- The list of zones where the device has enteredCopyright © 2012-2013 ADELE Research Group. All Rights Reserved.