Package de.espirit.or.query
Class ComposedConstraint
java.lang.Object
de.espirit.or.query.ComposedConstraint
- All Implemented Interfaces:
Constraint
,Serializable
,Cloneable
The base class of all composed constraints.
- Since:
- 4.0.17
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface de.espirit.or.query.Constraint
Constraint.Type
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
add
(@NotNull Constraint constraint) Add a new sub constraint to this composed constraint.Return an unmodifiable list of all sub contraints contained in this composed constraint.boolean
isEmpty()
Check if this is an empty constraint.int
size()
Returns the number of sub constraints.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface de.espirit.or.query.Constraint
getType
-
Constructor Details
-
ComposedConstraint
public ComposedConstraint()
-
-
Method Details
-
getConstraints
Return an unmodifiable list of all sub contraints contained in this composed constraint.- Since:
- 4.0.17
-
add
Add a new sub constraint to this composed constraint.- Since:
- 4.0.17
-
size
public int size()Returns the number of sub constraints.- Since:
- 4.0.17
-
isEmpty
public boolean isEmpty()Check if this is an empty constraint. Empty constraints could be omitted without changing the query result.- Specified by:
isEmpty
in interfaceConstraint
- Returns:
true
if the constraint is empty, i.e. removing the constraint would not change the query result.- Since:
- 5.0.102
-