ist.palcom.hgraph
Interface IHgraphNode
- All Known Subinterfaces:
- Compass, DeviceContext, HgraphProxy, IAssemblyManager, IVisualizationEngine, RoutingManager, Service
- All Known Implementing Classes:
- AbstractAccompliceService, AbstractDeviceContext, AbstractRoutingManager, AbstractRoutingManager2, AbstractService, AbstractServiceDecl, Action, ActionWithParams, AddressUse, AISReaderService, AlarmHRHRService, AlarmService, AltServiceDecl, AltServiceDeclList, Assembly, AssemblyDeviceContext, AssemblyLauncherService, AssemblyManager, AssemblyWindowHgraphProxy, AssignAction, AxisControllerService, BasicRoutingManager, BioBeltService, BreathingInspectionService, BTCompass, CliHgraphBrowserService, CommandInfo, CommunicationManager, CompassService, ConfigureHRHRAlarmService, Connection, ConnectionDecl, ConnectionDeclList, ConnectionHgraphProxy, ConnectionsManager, ConnectivityService, ConstantUse, ContingencyDeviceContext, ContingencyManager, ContingencyMonitor, ControlInfo, CoordinateStufferService, DeviceDecl, DeviceDeclList, DeviceUse, DeviceWindowHgraphProxy, DiabetesService, DiscoveryManager, DisplayerControlProvider, DisplayerCustomer, DisplayService, DisplayService, DisplayService, DSDVRoutingManager, EchoService, EclipseAssemblyManager, EventHandlerClause, EventHandlerList, EventHandlerScript, GeneratorControlProvider, GeoConverterService, GoogleEarthService, GPSParserService, GpsService, GroupInfo, HeartrateInspectionService, HgraphBrowserService, HgraphManager, HgraphManagerService, HgraphNode, Identifier, ImageProvider, ImageViewerCustomer, IncubatorController, InvokeAction, IRDeviceContext, LEDService, MattressService, MirrorNode, MissingUse, MStoneService, NewResourceManager, NodeHgraphProxy, PalBoxAssemblyManager, PalcomResourceDescriptor, PalOverviewBrowserAccompliceService, PalOverviewBrowserDeviceContext, ParamInfo, ParamUse, PhotoDBService, PhotoService, PictureService, PoetryProvider, PointToPointManager, PositionService, PRDAssemblyD, PRDAssemblyVer, PRDBroadcastConnection, PRDConnection, PRDConnectionList, PRDData, PRDDevice, PRDFirstOrder, PRDFunctionalMetadata, PRDGroupcastConnection, PRDRadiocastConnection, PRDSecondOrder, PRDSecondOrderList, PRDService, PRDServiceFMDescription, PRDServiceList, PRDServiceListItem, PRDSubList, PRDSynthesizedService, PRDUnicastConnection, ProximityService, PubSubManager, PuzzleAssembler, PuzzleGame, RadiocastConnection, RemoteConnectManager, ResourceDirectory, RespiratorService, RFIDService, SaturimeterService, ScriptedAssembly, SelfTestAction, SelfTestProvider, SendMessageAction, ServiceDecl, ServiceDeclList, ServiceExp, ServiceManager, ServiceUse, ServiceWindowHgraphProxy, SimpleMulticastRoutingManager, SimpleRoutingManager, SingleServiceDecl, SMURFRoutingManager, StorageService, StreamInfo, SwingDisplayUDPDeviceContext, SwingVisualizationEngine, ThisProviderService, ThisService, TimerService, TouchService, TypeManager, UDPDeviceContext, UnicastConnection, Use, VariableDecl, VariableList, VariableUse, VisualizationManager
public interface IHgraphNode
The IHgraphNode is the key identity in relation to Hgraphs. For more information, see the package specification
ERROR
static final int ERROR
- See Also:
- Constant Field Values
STATUS_OK
static final int STATUS_OK
- See Also:
- Constant Field Values
CHILD_NAME_CLASH
static final int CHILD_NAME_CLASH
- See Also:
- Constant Field Values
NODE_NOT_CHILD
static final int NODE_NOT_CHILD
- See Also:
- Constant Field Values
CIRCULARITY_CLASH
static final int CIRCULARITY_CLASH
- See Also:
- Constant Field Values
COMMAND_OR_NODE_MISSING
static final int COMMAND_OR_NODE_MISSING
- See Also:
- Constant Field Values
VALUE_NOT_PRESENT
static final int VALUE_NOT_PRESENT
- See Also:
- Constant Field Values
VALUE_ALREADY_EXISTS
static final int VALUE_ALREADY_EXISTS
- See Also:
- Constant Field Values
SIBLING_NONEXISTENT
static final int SIBLING_NONEXISTENT
- See Also:
- Constant Field Values
SIBLING_ALREADY_EXISTS
static final int SIBLING_ALREADY_EXISTS
- See Also:
- Constant Field Values
SIBLING_REFERENCE_ALREADY_EXISTS
static final int SIBLING_REFERENCE_ALREADY_EXISTS
- See Also:
- Constant Field Values
SIBLING_REFERENCE_NONEXISTENT
static final int SIBLING_REFERENCE_NONEXISTENT
- See Also:
- Constant Field Values
PATH_MISSING
static final int PATH_MISSING
- See Also:
- Constant Field Values
LISTENER_MISSING
static final int LISTENER_MISSING
- See Also:
- Constant Field Values
HANDLER_MISSING
static final int HANDLER_MISSING
- See Also:
- Constant Field Values
INVOKATOR_MISSING
static final int INVOKATOR_MISSING
- See Also:
- Constant Field Values
getNodeName
java.lang.String getNodeName()
- Returns:
- The name of the node.
setNodeName
int setNodeName(java.lang.String name,
Path callerPath)
- Sets the name of the node. If a sibling already has the name, an error control message is returned
- Parameters:
name - The new name
- Returns:
- IHgraphNode.STATUS_OK if the change succeeded. IHgraphNode.CHILD_NAME_CLASH if a sibling with the given name already exists.
getPath
Path getPath()
- Returns:
- the Path object pertaining to the path of the node
updatePath
void updatePath()
- Updates the path of the H-Graph node along with its offspring recursively.
The path is updated when the node name and the node parent is sat.
getNodeParent
IHgraphNode getNodeParent()
- Returns:
- The parent of the node. null if the parent is root
setNodeParent
int setNodeParent(IHgraphNode newParent,
Path callerPath)
- Sets the parent of the HgraphNode. This triggers a recalculation of the path of the node and its offspring
- Parameters:
newParent - the new parent
- Returns:
- IHgraphNode.STATUS_OK if the operation succeeds. IHgraphNode.CIRCULARITY_CLASH if the operation causes a circularity.
getChildIterator
java.util.Iterator getChildIterator()
- Returns:
- An Iterator over the children of the node
addNodeChild
int addNodeChild(IHgraphNode node,
Path callerPath)
- Adds a child to the node's private list of children.
Ensures that names amongst children are unique
- Parameters:
node - The new child to be added
- Returns:
- IHgraphNode.STATUS_OK if the change succeeded. IHgraphNode.CHILD_NAME_CLASH if a sibling with the given name already exists.
removeNodeChild
int removeNodeChild(java.lang.String name,
Path callerPath)
- Removes a child based on its name.
- Parameters:
name - The name of the child to be removed
- Returns:
- IHgraphNode.STATUS_OK if the operation succeeds
hasChildNamed
boolean hasChildNamed(java.lang.String name)
- Checks whether the node has a child with a given name
- Parameters:
name - The name to check
- Returns:
- True iff the node has an actual child with the given name. False if not.
isAncestorOf
boolean isAncestorOf(IHgraphNode node)
- Checks whether this node is an ancestor of the parameter node.
It does so with a depth-first sharch of its offspring (children etc.)
- Returns:
- true if this node is an ancestor of the parameter node. false if not.
getSiblingFunc
SiblingFunc getSiblingFunc()
- Returns:
- The SiblingFunc Sibling functionality object for the given node.
getValueFunc
ValueFunc getValueFunc()
- Returns:
- The ValueFunc Value functionality object for the given node.
getFuncFunc
FuncFunc getFuncFunc()
- Returns:
- The FuncFunc functional functionality (ie. handlers, invokators and listeners) object for the given node.
toXML
java.lang.String toXML()
- Returns:
- A simple xml'ified String of the node (type, name, path, children)
toXMLFull
java.lang.String toXMLFull()
- Returns:
- A complete xml'ified String of the node (same as simple + handlers, invokators, listeners, values)
toXMLRecursively
java.lang.String toXMLRecursively()
- Returns:
- A simple recursive xml'ified String of the node (type, name, path, children)
toXMLFullRecursively
java.lang.String toXMLFullRecursively()
- Returns:
- A complete recursive xml'ified String of the node (same as simple + handlers, invokators, listeners, values)
HEAVY!!!