public class IsyInsteonClient extends ISYInsteonClient
Modifier and Type | Field and Description |
---|---|
private boolean |
debug_ |
private NetworkConfig |
isyNetworkConfig_ |
private boolean |
makingNodeChanges |
static UDProxyDevice |
myConnectedDevice_ |
private String |
myPassword |
private String |
myUserId |
private ArrayList<NodeChangeMessage> |
recentNodeChanges_ |
UD_BATCH_MODE_CHANGED_ACTION, UD_BATTERY_DEVICE_WRITE_MODE_CHANGED_ACTION, UD_CLIENT_HEART_BEAT_EVENT, UD_DEVICE_SPECIFIC_EVENT, UD_DISCOVERING_NODES_ACTION, UD_DISCOVERING_NODES_COMPLETE_ACTION, UD_FOLDER_ADDED_ACTION, UD_FOLDER_REMOVED_ACTION, UD_FOLDER_RENAMED_ACTION, UD_GROUP_ADDED_ACTION, UD_GROUP_REMOVED_ACTION, UD_GROUP_RENAMED_ACTION, UD_INTERNET_ACCESS_DISABLED_ACTION, UD_INTERNET_ACCESS_ENABLED_ACTION, UD_INTERNET_ACCESS_EVENT, UD_INTERNET_ACCESS_FAILED_ACTION, UD_LINKER_EVENT, UD_LINKER_EVENT_CLEAR, UD_LINKER_EVENT_DEVICE_STATUS, UD_NETWORK_RENAMED_ACTION, UD_NODE_ADDED_ACTION, UD_NODE_CHANGE_LINK_ACTION, UD_NODE_CLEAR_ERROR_ACTION, UD_NODE_DEVICE_ID_CHANGED, UD_NODE_DEVICE_PROPERTY_CHANGED, UD_NODE_ENABLED_ACTION, UD_NODE_HAS_PENDING_DEVICE_WRITES_ACTION, UD_NODE_IN_ERROR_ACTION, UD_NODE_MOVED_ACTION, UD_NODE_PARENT_CHANGED_ACTION, UD_NODE_POWER_INFO_CHANGED_ACTION, UD_NODE_REMOVED_ACTION, UD_NODE_REMOVED_FROM_GROUP_ACTION, UD_NODE_RENAMED_ACTION, UD_NODE_REVISED_ACTION, UD_NODE_SUPPORTED_TYPE_INFO_CHANGED, UD_NODE_WRITING_TO_DEVICE_ACTION, UD_NODES_UPDATED_EVENT, UD_NOTIFICATION_SETTINGS_UPDATED_ACTION, UD_NTP_COMM_FAILED_ACTION, UD_NTP_SETTINGS_UPDATED_ACTION, UD_PROGRESS_EVENT_UPDATE, UD_PROGRESS_UPDATED_EVENT, UD_SYS_CONFIG_UPDATED_EVENT, UD_SYSTEM_BUSY_EVENT, UD_SYSTEM_IS_BUSY_ACTION, UD_SYSTEM_IS_IDLE_ACTION, UD_SYSTEM_IS_IN_SAFE_MODE_ACTION, UD_SYSTEM_IS_NOT_BUSY_ACTION, UD_TIME_CHANGED_ACTION, UD_TIME_CONFIG_CHANGED_ACTION, UD_TRIGGER_EVENT_GET_STATUS, UD_TRIGGER_EVENT_INFO_STRING, UD_TRIGGER_EVENT_KEY_CHANGED, UD_TRIGGER_EVENT_LEARN_IR, UD_TRIGGER_EVENT_SCHEDULE, UD_TRIGGER_EVENT_STATUS, UD_TRIGGER_EVENT_VAR_INIT, UD_TRIGGER_EVENT_VAR_STATUS, UD_TRIGGER_UPDATED_EVENT
Constructor and Description |
---|
IsyInsteonClient()
Constructor
Registers this class as IModelChangeListener
|
IsyInsteonClient(boolean debugOn) |
Modifier and Type | Method and Description |
---|---|
private void |
addToChangeMessageStack(UDNode node,
UDControl control,
Object value)
This method add the latest model change message to the stack to be consumed.
|
void |
cleanUp()
Implement any cleanup Routines necessary here
|
void |
debugOff() |
void |
debugOn() |
void |
debugToggle() |
ArrayList<NodeChangeMessage> |
getRecentNodeChanges()
This method gets (and then clears) the list of recent node change messages that came in.
|
private ArrayList<NodeChangeMessage> |
getRecentNodeChanges(boolean clearList)
This method gets (and then clears) the list of recent node change messages that came in.
|
boolean |
isReadyToGo()
Helper to tell if authenticated and ready to process
|
void |
onDeviceOffLine()
This method is invoked with the library does not receive announcements from ISY and considers it offline
|
void |
onDeviceOnLine()
This method is invoked when a currently known ISY (UDProxyDevice) is back on line.
|
void |
onDeviceSpecific(String arg1,
String node,
XMLElement arg2) |
void |
onDiscoveringNodes()
This method is invoked when ISY goes into Linking mode
|
void |
onFolderRemoved(String folderAddress) |
void |
onFolderRenamed(UDFolder folder) |
void |
onGroupRemoved(String groupAddress)
This method is invoked when a group/scene is removed
|
void |
onGroupRenamed(UDGroup group)
This method is invoked when a group/scene is renamed
|
void |
onInternetAccessDisabled()
This method is invoked when internet access is disabled on ISY
|
void |
onInternetAccessEnabled(String url)
This method is invoked with internet access is enabled on ISY
|
void |
onLinkerEvent(UDProxyDevice arg0,
String arg1,
XMLElement arg2) |
void |
onModelChanged(UDControl control,
Object value,
UDNode node)
This method is invoked everytime there's a change in the state of a control for
a node (Insteon Device).
|
void |
onNetworkRenamed(String newName)
This method is invoked when the network is renamed.
|
void |
onNewDeviceAnnounced(UDProxyDevice device)
This method is called when a new ISY is announced or discovered
on the network.
|
void |
onNewFolder(UDFolder folder) |
void |
onNewGroup(UDGroup newGroup)
This method is called when a new group/scene has been created.
|
void |
onNewNode(UDNode newNode)
This method is called when a new node (Insteon Device) has been added
|
void |
onNodeDeviceIdChanged(UDProxyDevice device,
UDNode node) |
void |
onNodeDevicePropertiesRefreshed(UDProxyDevice device,
UDNode node) |
void |
onNodeDevicePropertiesRefreshedComplete(UDProxyDevice proxyDevice) |
void |
onNodeDevicePropertyChanged(UDProxyDevice device,
UDNode node,
com.universaldevices.common.properties.UDProperty<?> property) |
void |
onNodeDiscoveryStopped()
This method is invoked when ISY is no longer in Linking mode
|
void |
onNodeEnabled(UDNode node,
boolean b)
This method is called with a node is enabled or disabled
|
void |
onNodeError(UDNode node)
This method is called when an Insteon Device does not correctly communicate with ISY
|
void |
onNodeErrorCleared(UDProxyDevice arg0,
UDNode arg1) |
void |
onNodeHasPendingDeviceWrites(UDNode node,
boolean hasPending) |
void |
onNodeIsWritingToDevice(UDNode node,
boolean isWriting) |
void |
onNodeMovedAsMaster(UDNode node,
UDGroup group)
This method is invoked when a node (Insteon Device) has been moved to a scene as controller/master
|
void |
onNodeMovedAsSlave(UDNode node,
UDGroup group)
This method is invoked when a node (Insteon Device) has been moved to a scene as responder/slave
|
void |
onNodeParentChanged(UDNode node,
UDNode newParent) |
void |
onNodePowerInfoChanged(UDNode node) |
void |
onNodeRemoved(String nodeAddress)
This method is called when a node (Insteon Device) has been permanently removed from ISY
|
void |
onNodeRemovedFromGroup(UDNode node,
UDGroup group)
This method is called when a node (Insteon Device) is removed from a scene
|
void |
onNodeRenamed(UDNode node)
This method is invoked when a node (Insteon Device) is renamed
|
void |
onNodeRevised(UDProxyDevice device,
UDNode node) |
void |
onNodeSupportedTypeInfoChanged(UDProxyDevice arg0,
String arg1) |
void |
onNodeToGroupRoleChanged(UDNode node,
UDGroup group,
char new_role)
This method is called when a node's role changes in the given group (master/slave role).
|
void |
onProgress(String arg1,
XMLElement arg2) |
void |
onSystemConfigChanged(String event,
XMLElement eventInfo) |
void |
onSystemStatus(boolean busy)
This method is invoked when the state of the system (whether or not busy) is changed
|
void |
onTriggerStatus(String arg1,
XMLElement arg2)
This method is invoked when trigger status changes.
|
void |
setDebug(boolean d) |
ArrayList<NodeChangeMessage> |
snoopRecentNodeChanges()
This method snoops (retrieves) the list of recent node change messages that came in; WITHOUT removing them from the list.
|
private void |
submitSoapRequest(String serviceName)
Send SOAP request to the connected device.
|
void |
unsubscribeFromEvents() |
addNewScene, brightenDevice, brightenScene, dimDevice, dimScene, getDevicesSceneAttributesForAController, getDevicesSceneAttributesForAScene, isLinking, moveNodeToSceneAsMaster, moveNodeToSceneAsSlave, setDeviceOnLevel, setDeviceOnLevelForAScene, setDeviceOnLevelForASceneController, setDeviceRampRate, setDeviceRampRateForAScene, setDeviceRampRateForASceneController, setMasterLinkingMode, setSlaveLinkingMode, start, startDeviceManualChangeDown, startDeviceManualChangeUp, startLinking, startSceneManualChangeDown, startSceneManualChangeUp, stopDeviceManualChange, stopLinking, stopSceneManualChange, turnDeviceFastOff, turnDeviceFastOn, turnDeviceOff, turnDeviceOn, turnSceneFastOff, turnSceneFastOn, turnSceneOff, turnSceneOn
addFolder, addGroup, addNode, cancelNodesDiscovery, changeGroupState, changeNodeState, disableInternetAccess, discoverNodes, enableInternetAccess, getCurrValue, getLog, getNumPendingNotifications, getSystemDateTime, getSystemOptions, getSystemStatus, isISYReady, moveNode, onDeviceOffLine, onDeviceOnLine, onDeviceSpecific, onDiscoveringNodes, onFolderRemoved, onFolderRenamed, onGroupRemoved, onGroupRenamed, onInternetAccessUpdated, onModelChanged, onNetworkRenamed, onNewFolder, onNewGroup, onNewNode, onNodeDiscoveryStopped, onNodeEnabled, onNodeError, onNodeHasPendingDeviceWrites, onNodeIsWritingToDevice, onNodeMoved, onNodeParentChanged, onNodePowerInfoChanged, onNodeRemoved, onNodeRemovedFromGroup, onNodeRenamed, onNodeToGroupRoleChanged, onProgress, onSystemConfigChanged, onSystemStatus, onTriggerStatus, queryGroup, queryNode, reboot, removeeFolder, removeFromGroup, removeGroup, removeNode, renameFolder, renameGroup, renameNetwork, renameNode, resetAllNotifications, resetLog, saveSystemDateTime, saveSystemOptions, setParent, start, updateUserCredentials
addUDErrorListener, addUDModelChangeListener, authenticate, getControls, getDevice, getGroups, getNodes, isStarted, onNewDevice, removeUDErrorListener, removeUDModelChangeListener, setStarted, start, stop
private String myPassword
public static UDProxyDevice myConnectedDevice_
private NetworkConfig isyNetworkConfig_
private boolean debug_
private ArrayList<NodeChangeMessage> recentNodeChanges_
private boolean makingNodeChanges
public IsyInsteonClient()
IModelChangeListener
public IsyInsteonClient(boolean debugOn)
public void setDebug(boolean d)
public void debugOn()
public void debugOff()
public void debugToggle()
public void unsubscribeFromEvents()
private void submitSoapRequest(String serviceName)
urlPath
- is the soap urlpath ie "/web/nodescnf.xml"public void onNewDeviceAnnounced(UDProxyDevice device)
onNewDeviceAnnounced
in class UDClient
public void onDiscoveringNodes()
onDiscoveringNodes
in class ISYClient
public void onNodeDiscoveryStopped()
onNodeDiscoveryStopped
in class ISYClient
public void onGroupRemoved(String groupAddress)
onGroupRemoved
in class ISYClient
public void onGroupRenamed(UDGroup group)
onGroupRenamed
in class ISYClient
public ArrayList<NodeChangeMessage> snoopRecentNodeChanges()
public ArrayList<NodeChangeMessage> getRecentNodeChanges()
private ArrayList<NodeChangeMessage> getRecentNodeChanges(boolean clearList)
clearList
- flags if this method should clear the list after retrieval.private void addToChangeMessageStack(UDNode node, UDControl control, Object value)
public void onModelChanged(UDControl control, Object value, UDNode node)
onModelChanged
in class ISYClient
public void onNetworkRenamed(String newName)
onNetworkRenamed
in class ISYClient
public void onNewGroup(UDGroup newGroup)
onNewGroup
in class ISYClient
public void onNewNode(UDNode newNode)
public void onNodeError(UDNode node)
onNodeError
in class ISYClient
public void onNodeEnabled(UDNode node, boolean b)
onNodeEnabled
in class ISYClient
node
- b
- public void onNodeRemoved(String nodeAddress)
onNodeRemoved
in class ISYClient
public void onNodeRemovedFromGroup(UDNode node, UDGroup group)
onNodeRemovedFromGroup
in class ISYClient
public void onNodeToGroupRoleChanged(UDNode node, UDGroup group, char new_role)
onNodeToGroupRoleChanged
in class ISYClient
public void onNodeRenamed(UDNode node)
onNodeRenamed
in class ISYClient
public void onNodeMovedAsMaster(UDNode node, UDGroup group)
onNodeMovedAsMaster
in class ISYClient
public void onNodeMovedAsSlave(UDNode node, UDGroup group)
onNodeMovedAsSlave
in class ISYClient
public void onDeviceOffLine()
onDeviceOffLine
in class ISYClient
public void onDeviceOnLine()
onDeviceOnLine
in class ISYClient
public void onSystemStatus(boolean busy)
onSystemStatus
in class ISYClient
busy
- - whether or not ISY is busypublic void onInternetAccessDisabled()
onInternetAccessDisabled
in class ISYClient
public void onInternetAccessEnabled(String url)
onInternetAccessEnabled
in class ISYClient
url
- - the external fully qualified url through which ISY can be accessedpublic void onTriggerStatus(String arg1, XMLElement arg2)
onTriggerStatus
in class ISYClient
arg1
- - the statusarg2
- - extra informationpublic void onDeviceSpecific(String arg1, String node, XMLElement arg2)
onDeviceSpecific
in class ISYClient
public void onProgress(String arg1, XMLElement arg2)
onProgress
in class ISYClient
public boolean isReadyToGo()
public void cleanUp()
public void onSystemConfigChanged(String event, XMLElement eventInfo)
onSystemConfigChanged
in class ISYClient
public void onFolderRemoved(String folderAddress)
onFolderRemoved
in class ISYClient
public void onFolderRenamed(UDFolder folder)
onFolderRenamed
in class ISYClient
public void onNewFolder(UDFolder folder)
onNewFolder
in class ISYClient
public void onNodeHasPendingDeviceWrites(UDNode node, boolean hasPending)
onNodeHasPendingDeviceWrites
in class ISYClient
public void onNodeIsWritingToDevice(UDNode node, boolean isWriting)
onNodeIsWritingToDevice
in class ISYClient
public void onNodeParentChanged(UDNode node, UDNode newParent)
onNodeParentChanged
in class ISYClient
public void onNodePowerInfoChanged(UDNode node)
onNodePowerInfoChanged
in class ISYClient
public void onNodeDeviceIdChanged(UDProxyDevice device, UDNode node)
public void onNodeDevicePropertiesRefreshed(UDProxyDevice device, UDNode node)
public void onNodeDevicePropertiesRefreshedComplete(UDProxyDevice proxyDevice)
public void onNodeDevicePropertyChanged(UDProxyDevice device, UDNode node, com.universaldevices.common.properties.UDProperty<?> property)
public void onNodeRevised(UDProxyDevice device, UDNode node)
public void onNodeErrorCleared(UDProxyDevice arg0, UDNode arg1)
public void onLinkerEvent(UDProxyDevice arg0, String arg1, XMLElement arg2)
public void onNodeSupportedTypeInfoChanged(UDProxyDevice arg0, String arg1)
WebARTS Library Licensed Under the GNU - General Public License. Other Libraries licensed under their respective Open Source Licenses