public abstract class AbstractSingleCriteriaNode extends AbstractCriteria implements SingleCriteriaNode
SingleCriteriaNode functionality provided
for SingleCriteriaNode implementations.| Constructor and Description |
|---|
AbstractSingleCriteriaNode(String aName)
Constructs a
SingleCriteriaNode with the given name. |
AbstractSingleCriteriaNode(String aName,
Criteria aChild)
Constructs a
SingleCriteriaNode with the given name and the
provided Criteria child. |
| Modifier and Type | Method and Description |
|---|---|
void |
addChild(Criteria aCriteria)
Adds a child
Criteria to the CriteriaNode. |
Criteria |
getChild()
Returns the single child
Criteria being stored in this
CriteriaNode. |
List<Criteria> |
getChildren()
Returns the list of child
Criteria instances contained in the
CriteriaNode. |
void |
setChild(Criteria aChild)
Sets the single child
Criteria to be stored in this
CriteriaNode. |
getNamepublic AbstractSingleCriteriaNode(String aName)
SingleCriteriaNode with the given name.aName - The name of the SingleCriteriaNode.public AbstractSingleCriteriaNode(String aName, Criteria aChild)
SingleCriteriaNode with the given name and the
provided Criteria child.aName - The name of the SingleCriteriaNode.aChild - The Criteria child to be contained in the
SingleCriteriaNode.public Criteria getChild()
Criteria being stored in this
CriteriaNode.getChild in interface SingleCriteriaNodeCriteria.public void setChild(Criteria aChild)
Criteria to be stored in this
CriteriaNode.setChild in interface SingleCriteriaNodeaChild - The according child Criteria.public void addChild(Criteria aCriteria) throws IllegalStateException, IllegalArgumentException
Criteria to the CriteriaNode. In case a
specialized CriteriaNode applies constraints on the number or
type of Criteria which may be added, an according exception may
be thrown. For example the SingleCriteriaNode applies constraints
on this method.
-------------------------------------------------------------------------
CAUTION: Adding more than one Criteria child will result in an
IllegalStateException to be thrown!
-------------------------------------------------------------------------addChild in interface CriteriaNodeaCriteria - The child Criteria to be added.IllegalStateException - In case constraints in terms of state are
violated, implementation depended.IllegalArgumentException - In case constraints in terms of argument
are violated, implementation depended.public List<Criteria> getChildren()
Criteria instances contained in the
CriteriaNode.getChildren in interface CriteriaNodeCriteria instances contained in the
CriteriaNode.Copyright © 2015. All rights reserved.