Package org.zkoss.bind.tracker.impl
Class TrackerNodeImpl
- java.lang.Object
-
- org.zkoss.bind.tracker.impl.TrackerNodeImpl
-
- All Implemented Interfaces:
java.io.Serializable
,TrackerNode
public class TrackerNodeImpl extends java.lang.Object implements TrackerNode, java.io.Serializable
- Since:
- 6.0.0
- Author:
- henrichen
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description TrackerNodeImpl(java.lang.Object property)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addAssociate(TrackerNode node)
add associated TrackerNode with this nodevoid
addBinding(Binding binding)
add associated Binding with this nodevoid
addDependent(java.lang.Object script, TrackerNode dependent)
Add a dependent node of the field script.java.util.Set<TrackerNode>
getAssociates()
Returns all associate nodes of this node.java.lang.Object
getBean()
Returns associated bean of this TrackerNode.java.util.Set<Binding>
getBindings()
Returns all associated Bindings.TrackerNode
getDependent(java.lang.Object property)
Returns the associated TrackerNode of the associated field script of this tracker node.java.util.Set<TrackerNode>
getDependents()
Returns all dependent nodes of this node.java.util.Set<TrackerNode>
getDependents(java.lang.Object property)
Returns all associated TrackerNodes of the associated field script of this tracker node.java.util.Set<TrackerNode>
getDirectDependents()
Returns all direct dependent nodes of this node.java.lang.Object
getFieldScript()
Returns associated field script of this TrackerNode.java.util.Set<LoadBinding>
getLoadBindings()
Returns associated LoadBindings except ReferenceBindings.java.util.Map<java.lang.Object,?>
getPropNameMapping()
get property, tracker node mapping mapjava.util.Set<ReferenceBinding>
getReferenceBindings()
Returns associated ReferenceBindings.boolean
isPropNameNodeMapped(TrackerNode trackerNode)
Internal used onlyTrackerNode
removeDependent(java.lang.Object script)
Remove a dependent node of this node per the specified field script.void
setBean(java.lang.Object bean)
Sets associated bean of this TrackerNode.void
tieProperty(java.lang.Object property, TrackerNode trackerNode)
tie property with tracker node of this node.java.lang.String
toString()
-
-
-
Method Detail
-
addAssociate
public void addAssociate(TrackerNode node)
Description copied from interface:TrackerNode
add associated TrackerNode with this node- Specified by:
addAssociate
in interfaceTrackerNode
-
getDependent
public TrackerNode getDependent(java.lang.Object property)
Description copied from interface:TrackerNode
Returns the associated TrackerNode of the associated field script of this tracker node.- Specified by:
getDependent
in interfaceTrackerNode
- Parameters:
property
- field script to get the dependent- Returns:
- the linked TrackerNode
-
getDependents
public java.util.Set<TrackerNode> getDependents(java.lang.Object property)
Description copied from interface:TrackerNode
Returns all associated TrackerNodes of the associated field script of this tracker node.- Specified by:
getDependents
in interfaceTrackerNode
- Parameters:
property
- field script to get the dependent- Returns:
- all linked TrackerNodes
-
getDependents
public java.util.Set<TrackerNode> getDependents()
Description copied from interface:TrackerNode
Returns all dependent nodes of this node.- Specified by:
getDependents
in interfaceTrackerNode
- Returns:
- all precedent nodes of this node.
-
addDependent
public void addDependent(java.lang.Object script, TrackerNode dependent)
Description copied from interface:TrackerNode
Add a dependent node of the field script.- Specified by:
addDependent
in interfaceTrackerNode
- Parameters:
script
- the field script to link this track node to its dependent nodes.dependent
- the TrackerNode to be added
-
tieProperty
public void tieProperty(java.lang.Object property, TrackerNode trackerNode)
Description copied from interface:TrackerNode
tie property with tracker node of this node.- Specified by:
tieProperty
in interfaceTrackerNode
-
removeDependent
public TrackerNode removeDependent(java.lang.Object script)
Description copied from interface:TrackerNode
Remove a dependent node of this node per the specified field script.- Specified by:
removeDependent
in interfaceTrackerNode
- Parameters:
script
- field script that link to the to be removed dependent tracker node.- Returns:
- the removed TrackerNode
-
addBinding
public void addBinding(Binding binding)
Description copied from interface:TrackerNode
add associated Binding with this node- Specified by:
addBinding
in interfaceTrackerNode
-
getBindings
public java.util.Set<Binding> getBindings()
Description copied from interface:TrackerNode
Returns all associated Bindings.- Specified by:
getBindings
in interfaceTrackerNode
- Returns:
- associated Bindings.
-
getReferenceBindings
public java.util.Set<ReferenceBinding> getReferenceBindings()
Description copied from interface:TrackerNode
Returns associated ReferenceBindings.- Specified by:
getReferenceBindings
in interfaceTrackerNode
- Returns:
- associated ReferenceBindings.
-
getLoadBindings
public java.util.Set<LoadBinding> getLoadBindings()
Description copied from interface:TrackerNode
Returns associated LoadBindings except ReferenceBindings.- Specified by:
getLoadBindings
in interfaceTrackerNode
- Returns:
- associated LoadBindings except ReferenceBindings.
-
getDirectDependents
public java.util.Set<TrackerNode> getDirectDependents()
Description copied from interface:TrackerNode
Returns all direct dependent nodes of this node.- Specified by:
getDirectDependents
in interfaceTrackerNode
- Returns:
- all direct dependent nodes of this node.
-
getAssociates
public java.util.Set<TrackerNode> getAssociates()
Description copied from interface:TrackerNode
Returns all associate nodes of this node.- Specified by:
getAssociates
in interfaceTrackerNode
- Returns:
- all associate nodes of this node.
-
getBean
public java.lang.Object getBean()
Description copied from interface:TrackerNode
Returns associated bean of this TrackerNode.- Specified by:
getBean
in interfaceTrackerNode
- Returns:
- associated bean of this TrackerNode.
-
setBean
public void setBean(java.lang.Object bean)
Description copied from interface:TrackerNode
Sets associated bean of this TrackerNode.- Specified by:
setBean
in interfaceTrackerNode
- Parameters:
bean
- the associated bean.
-
getFieldScript
public java.lang.Object getFieldScript()
Description copied from interface:TrackerNode
Returns associated field script of this TrackerNode.- Specified by:
getFieldScript
in interfaceTrackerNode
- Returns:
- associated field script of this TrackerNode.
-
getPropNameMapping
public java.util.Map<java.lang.Object,?> getPropNameMapping()
Description copied from interface:TrackerNode
get property, tracker node mapping map- Specified by:
getPropNameMapping
in interfaceTrackerNode
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
isPropNameNodeMapped
public boolean isPropNameNodeMapped(TrackerNode trackerNode)
Description copied from interface:TrackerNode
Internal used only- Specified by:
isPropNameNodeMapped
in interfaceTrackerNode
- Returns:
- boolean is the tracker node with specific propName in bracket mapped or not
-
-