public final class Or extends CompositeQueryExpression
Or
class is a composite dynamic query expression that
successfully matches with a profile if any of the nested query expressions
match with the profile.Constructor and Description |
---|
Or(QueryExpression[] exprs)
Create an
Or query expression initially populated with the
expressions contained in the specified array. |
Or(QueryExpression expr1,
QueryExpression expr2)
Create an
Or query expression initially populated with the two
specified query expressions. |
Modifier and Type | Method and Description |
---|---|
Or |
or(QueryExpression expr)
Add the specified query expression to this composite expression.
|
protected void |
toString(StringBuffer buf)
Get a string representation for this query expression.
|
add, getExpressions
toString
public Or(QueryExpression expr1, QueryExpression expr2)
Or
query expression initially populated with the two
specified query expressions.expr1
- the first query expression to add.expr2
- the second query expression to add.NullPointerException
- if either argument is null
.public Or(QueryExpression[] exprs)
Or
query expression initially populated with the
expressions contained in the specified array.exprs
- the query expressions to add.NullPointerException
- if exprs
is null
or
contains null
elements.IllegalArgumentException
- if the length of exprs
is
less than 2.public Or or(QueryExpression expr) throws NullPointerException, IllegalArgumentException
expr
- the query expression to add.this
.NullPointerException
- if expr
is null
.IllegalArgumentException
- if adding the query expression to this
composite expression would generate a cyclic expression.protected void toString(StringBuffer buf)
QueryExpression
toString
in class QueryExpression
buf
- a string buffer the string representation should be appended to.