public class CriteriaSetHierarchyNode extends Object implements Serializable
criterion and its getChildren().| Constructor and Description |
|---|
CriteriaSetHierarchyNode(CriteriaSet aCriteriaSet)
Builds a new node.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
addChild(CriteriaSet aCriteriaSet)
Adds a child to this node if the criterion is not already registered as a child.
|
boolean |
addChild(CriteriaSetHierarchyNode aNode)
Adds a child to this node if its criteriaSet is not already registered as a child.
|
CriteriaSetHierarchyNode |
deepCopy()
Returns a deep copy of this node.
|
CriteriaSetHierarchyNode |
getChild(CriteriaSet aCriteriaSet)
Returns the child node for the supplied criteria set.
|
CriteriaSetHierarchyNode |
getChild(String aCriteriaSetID)
Returns the child node with the supplied criteria set ID.
|
Set<CriteriaSetHierarchyNode> |
getChildren()
Returns the children of this node.
|
CriteriaSet |
getCriteriaSet()
Returns the criteriaSet attached to this node.
|
boolean |
isLeaf() |
boolean |
removeChild(CriteriaSet aCriteriaSet)
Removes from this node's children the child whose criteriaSet is the one supplied.
|
boolean |
removeChild(CriteriaSetHierarchyNode aChild)
Removes a child from this node's children.
|
String |
toString() |
protected String |
toString(String start,
String end) |
public static final String TAG
public CriteriaSetHierarchyNode(CriteriaSet aCriteriaSet)
aCriteriaSet - the criteriaSet attached to the new nodepublic CriteriaSet getCriteriaSet()
public boolean addChild(CriteriaSetHierarchyNode aNode)
aNode - the node to be addedpublic boolean addChild(CriteriaSet aCriteriaSet)
aNode - the node to be addedpublic boolean removeChild(CriteriaSetHierarchyNode aChild)
aChild - the node to be removed.true if the element was removed, false if it was not in this node's children.public boolean removeChild(CriteriaSet aCriteriaSet)
aChild - the criteriaSet for the node to be removed.true if the corresponding child could be found and removed.public Set<CriteriaSetHierarchyNode> getChildren()
add or remove children from one of the returned set's nodes, this will
directly change the sub-hierarchy held by this node as well. If you want to manipulate the hierarchy of the
returned nodes without affecting this node's hierarchy, call deepCopy() on this object and then call
this method on the copy instead.public CriteriaSetHierarchyNode getChild(CriteriaSet aCriteriaSet)
aCriteriaSet - the criterion to search in this node's childrennull if no such child could be found.public CriteriaSetHierarchyNode getChild(String aCriteriaSetID)
aCriterionSetID - the ID of a criteriaSet to search in this node's childrennull if no such child could be found.public boolean isLeaf()
public CriteriaSetHierarchyNode deepCopy()
Copyright © 2013–2021 Sébastien Bigaret, Patrick Meyer. All rights reserved.