public interface Node extends NodeOperations
DeviceGroup,
DeviceNode| Modifier and Type | Method and Description |
|---|---|
void |
addListener(NodeListener listener)
Adds listener, which will be notified about changes occurred in this node and in its direct members (if this node
is a device group).
|
int |
countDevices(java.lang.String deviceType,
java.lang.String filter,
boolean wholeSubTree)
Counts devices of given type, potentially filtered by some search criteria.
|
Enumerator |
findControlUnits(java.lang.String type,
java.lang.String finderId,
java.lang.Object finderArgs,
java.lang.String filter,
boolean wholeSubTree)
Returns ids of the control units with a given component type and satisfying a given finder
method with the supplied argument(s).
|
Enumerator |
getControlUnits(java.lang.String type,
java.lang.String filter,
boolean wholeSubTree)
Lists control units.
|
Enumerator |
getControlUnits(java.lang.String type,
java.lang.String finderId,
java.lang.Object finderArgs,
java.lang.String filter,
boolean states,
java.lang.String[] stateInterface,
boolean wholeSubTree,
boolean retrieveExtendingTypes)
Retrieves control units by various filtering and retrieving options.
|
Enumerator |
getControlUnitStates(java.lang.String type,
java.lang.String[] stateInterface,
java.lang.String filter,
boolean wholeSubTree)
Lists control unit states.
|
java.util.Date |
getCreateDate()
Returns the node create date
|
java.lang.String |
getDisplayName()
Returns user-friendly name of this node.
|
InheritableProperty |
getInheritableProperty(java.lang.String propertyName)
This method has similar behavior as invoking
getProperty(propertyName, true),
but it returns not only the value of the property, but also information whether this property is associated
with the node itself or is inherited from some of its parent nodes. |
java.util.Dictionary |
getNodeProperties()
Returns all generic properties associated with this node.
|
java.lang.String |
getNodeType()
Returns the type of this Node object.
|
DeviceGroup |
getParent()
Returns the parent object of this tree object.
|
java.lang.String |
getPath()
Returns the full path of this node.
|
java.lang.Object |
getProperty(java.lang.String propertyName,
boolean searchInParents)
Returns the value of a generic property with the supplied
propertyName associated with this
tree node. |
java.lang.String |
getRelativeName()
Returns the relative path ot this node.
|
void |
removeListener(NodeListener listener)
Removes a listener.
|
void |
setDisplayName(java.lang.String displayName)
Changes the user-friendly name of this node.
|
void |
setProperties(java.util.Dictionary props)
Assigns generic properties contained in the
props paramater with
this node. |
void |
setProperty(java.lang.String propertyName,
java.lang.Object propertyValue)
Assigns a generic property with the supplied
propertyName and propertyValue with
this node. |
createControlUnits, destroyControlUnits, invokeAction, synchronizeStatesjava.lang.String getPath()
java.lang.String getDisplayName()
void setDisplayName(java.lang.String displayName)
throws ManagementException
displayName - new displayName of node.ManagementException - it is thrown if an error while updating the display name of the node occurs.DeviceGroup getParent() throws ManagementException
null is returned.ManagementException - is thrown if a system error occurs.java.util.Dictionary getNodeProperties()
throws ManagementException
Dictionary containing (name, value)
pairs.ManagementException - is thrown if a system error occurs.java.lang.Object getProperty(java.lang.String propertyName,
boolean searchInParents)
throws ManagementException
propertyName associated with this
tree node. If the property is not present in the current node and searchInParents parameter is
set to true then the parent nodes are recursively searched for the property and the method
returns the first non-null value found. If the property does not present the method returns
null.propertyName - the name of the node property.searchInParents - specifies whether the property should be searched only in this node or also in
its parent nodes.null if there is no such property associated with this node
and its parent nodes.ManagementException - is thrown if a system error occurs.void setProperty(java.lang.String propertyName,
java.lang.Object propertyValue)
throws ManagementException
propertyName and propertyValue with
this node. Passing null as a property value removes the property from the set of
generic node properties. Note that deleting a property using this method means that invoking
getProperty(propertyName, true) shall return the default value (if there is such) associated
with the closest node parent.propertyName - the name of the node property.propertyValue - the value of the property.ManagementException - is thrown if a system error occurs.void setProperties(java.util.Dictionary props)
throws ManagementException
props paramater with
this node.props - the properties to be set.ManagementException - is thrown if a system error occurs.InheritableProperty getInheritableProperty(java.lang.String propertyName) throws java.lang.Exception
getProperty(propertyName, true),
but it returns not only the value of the property, but also information whether this property is associated
with the node itself or is inherited from some of its parent nodes. This information is encapsulated in a
InheritableProperty instance.propertyName - the name of the generic property.InheritableProperty instance for that property or null if there is no such property
associated with this node and its parent nodes.java.lang.Exception - is thrown if a system error occurs.void addListener(NodeListener listener) throws ManagementException
listener - the application defined listener being added.ManagementException - if a system error occurs.void removeListener(NodeListener listener)
listener - the application defined listener being removed.java.lang.String getRelativeName()
java.lang.String getNodeType()
DeviceGroup its type is null.
DeviceNode its type the control unit type itself.
Enumerator getControlUnits(java.lang.String type, java.lang.String filter, boolean wholeSubTree) throws ManagementException
type - type of control units to be retrievedfilter - control units search filter in mPRM script syntaxwholeSubTree - if true then the method will search in the whole subtree,
otherwise only direct mprm tree descendants will be evaluated for criteria compliance.Enumerator of ControlUnitID objectsManagementExceptionint countDevices(java.lang.String deviceType,
java.lang.String filter,
boolean wholeSubTree)
throws ManagementException
deviceType - type of device root control units to be counted.filter - control units search filter in mPRM script syntax.wholeSubTree - if true then the method will search in the whole subtree,
otherwise only direct mprm tree descendants will be evaluated for criteria compliance.Enumerator of ControlUnitID objectsManagementExceptionEnumerator getControlUnitStates(java.lang.String type, java.lang.String[] stateInterface, java.lang.String filter, boolean wholeSubTree) throws ManagementException
type - type of control units to be retrievedstateInterface - state interface of control units to be retrievedfilter - control units search filter in mPRM script syntaxwholeSubTree - if true then the method will search in the whole subtree,
otherwise only direct mprm tree descendants will be evaluated for criteria compliance.Enumerator of DeviceControlUnit objectsManagementExceptionEnumerator findControlUnits(java.lang.String type, java.lang.String finderId, java.lang.Object finderArgs, java.lang.String filter, boolean wholeSubTree) throws ManagementException
type - type of control units to be retrievedfinderId - the id of the finder method. Must start with "$find.".finderArgs - the finder argument(s). If the argument is only
one this is the argument itself. If the arguments are more then one, the
value must be a Object[] and arguments are retrieved from that array.filter - control units search filter in mPRM script syntax.
The control units returned by the finder
argument will be secondary filtered by the supplied filter.wholeSubTree - if true then the method will search in the whole subtree,
otherwise only direct mprm tree descendants will be evaluated for criteria compliance.Enumerator of ControlUnitID objectsManagementException - if a system error occurs.Enumerator getControlUnits(java.lang.String type, java.lang.String finderId, java.lang.Object finderArgs, java.lang.String filter, boolean states, java.lang.String[] stateInterface, boolean wholeSubTree, boolean retrieveExtendingTypes) throws ManagementException
type - control unit type.finderId - id of finder action. Value of null should be specified if searching is not by finder action.finderArgs - arguments of the finder action specified by finderId. Value of null should be specified if searching is not by finder action.filter - control unit filter in mPRM Script lexical syntax.states - boolean flag specifying whether the result Enumerator to retrieve states (valid of true) or just control unit ids (value of false).stateInterface - in combination with value of true for the states arguments, this argument may specify a list of state variables defining sub-state of the control unit states to be retieved. Value of null will retrieve the whole control unit states.wholeSubTree - if true then the method will search in the whole subtree,
otherwise only direct mprm tree descendants will be evaluated for criteria compliance.retrieveExtendingTypes - if true, the method will retrieve the control units of the specified type as well as the control units of its extending types.
Value of false will not return the control units of the extending types.
Default behavior is when listing control unit of given type - to retrieve the control units of the extension types, too.true is passed as value of the states parameter, the result is Enumerator of DeviceControlUnit object,
otherwise the result is Enumerator if ControlUnitID objects.ManagementException - if system error occurs.java.util.Date getCreateDate()
Copyright © 2019 Bosch Software Innovations GmbH. All Rights Reserved.