public class ZigbeeBinaryLight extends AbstractDevice implements BinaryLight, ZigbeeDevice, ZigbeeDeviceTracker
loggerBINARY_LIGHT_MAX_POWER_LEVEL, BINARY_LIGHT_POWER_STATUSDEFAULT_HEIGHT, DEFAULT_WIDTH, DEVICE_SERIAL_NUMBER, FAULT_NO, FAULT_PROPERTY_NAME, FAULT_UNKNOWN, FAULT_YES, LOCATION_PROPERTY_NAME, LOCATION_UNKNOWN, STATE_ACTIVATED, STATE_DEACTIVATED, STATE_PROPERTY_NAME, STATE_UNKNOWNBATTERY_LEVELFILTER_PROP_NAME| Constructor and Description |
|---|
ZigbeeBinaryLight() |
| Modifier and Type | Method and Description |
|---|---|
void |
deviceAdded(DeviceInfo deviceInfo)
Called when a new device has been discovered by the driver.
|
void |
deviceBatteryLevelChanged(String address,
float oldBatteryLevel,
float newBatteryLevel)
Called when a device battery level has changed.
|
void |
deviceDataChanged(String address,
Data oldData,
Data newData)
Called when a device data has changed.
|
void |
deviceRemoved(DeviceInfo deviceInfo)
Called when a device has been discovered by the driver.
|
double |
getMaxPowerLevel()
Return the current power level of this binary light
|
boolean |
getPowerStatus()
Return the current power state of this binary light.
|
String |
getSerialNumber()
Return the serial number of the device.
|
boolean |
setPowerStatus(boolean status)
Change the power status of this binary light.
|
void |
setPropertyValue(String propertyName,
Object value)
If the given propertyName is the power status, it will set it to the device;
the value will not change, if is not changed in the device.
|
void |
start() |
void |
stop() |
void |
turnOff()
Change the power status to false
|
void |
turnOn()
Change the power status to true
|
addListener, constainsProperty, enterInZones, equals, getFault, getProperties, getPropertyValue, getState, hashCode, hasPropertyValue, leavingZones, notifyListeners, removeListener, removeProperty, setFault, setStateclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitaddListener, constainsProperty, enterInZones, getFault, getProperties, getPropertyValue, getState, hasPropertyValue, leavingZones, removeListener, removeProperty, setFault, setStatepublic String getSerialNumber()
GenericDevicegetSerialNumber in interface GenericDeviceGenericDevice.DEVICE_SERIAL_NUMBERpublic boolean getPowerStatus()
BinaryLightgetPowerStatus in interface BinaryLightBinaryLight.setPowerStatus(boolean),
BinaryLight.BINARY_LIGHT_POWER_STATUSpublic boolean setPowerStatus(boolean status)
BinaryLightsetPowerStatus in interface BinaryLightstatus - the new power state of this binary light.BinaryLight.getPowerStatus(),
BinaryLight.BINARY_LIGHT_POWER_STATUSpublic double getMaxPowerLevel()
BinaryLightgetMaxPowerLevel in interface BinaryLightBinaryLight.BINARY_LIGHT_MAX_POWER_LEVELpublic void turnOn()
BinaryLightturnOn in interface BinaryLightpublic void turnOff()
BinaryLightturnOff in interface BinaryLightpublic void start()
public void stop()
public void setPropertyValue(String propertyName, Object value)
setPropertyValue in interface GenericDevicesetPropertyValue in class AbstractDevicepropertyName - value - public void deviceAdded(DeviceInfo deviceInfo)
deviceAdded in interface ZigbeeDeviceTrackerdeviceInfo - information about the devicepublic void deviceRemoved(DeviceInfo deviceInfo)
deviceRemoved in interface ZigbeeDeviceTrackerdeviceInfo - information about the devicepublic void deviceDataChanged(String address, Data oldData, Data newData)
deviceDataChanged in interface ZigbeeDeviceTrackeraddress - a device module addressoldData - previous device datanewData - new device datapublic void deviceBatteryLevelChanged(String address, float oldBatteryLevel, float newBatteryLevel)
deviceBatteryLevelChanged in interface ZigbeeDeviceTrackeraddress - a device module addressoldBatteryLevel - previous device battery levelnewBatteryLevel - new device battery levelCopyright © 2012-2013 ADELE Research Group. All Rights Reserved.