public abstract class Condition extends Expression
Expression
that represents a condition, which specifies a combination of one or more expressions and logical (Boolean) operators and evaluates to true
, false
, null
, or UNKNOWN
. The Condition
class has methods that create a subclass that specifies a logical AND
, NOT
, or OR
condition.Modifier and Type | Method and Description |
---|---|
Condition |
and(Condition rhs)
Creates a
Condition that represents a logical AND condition. |
boolean |
isCompositeObject()
Indicates whether this
Condition contains other SyntaxObject objects. |
Condition |
not()
Creates a
Condition that represents a logical NOT condition, which reverses, or negates, the Boolean value of this Condition . |
Condition |
or(Condition rhs)
Creates a
Condition that represents a logical OR condition. |
equals, equals, fromSyntax, fromSyntax, fromSyntax, fromSyntax, fromSyntax, isValid, toSyntax, toSyntax, toSyntax, toSyntax, toSyntax, toSyntax, visit
public final Condition and(Condition rhs)
Condition
that represents a logical AND
condition. The Condition
returned by this method represents a condition that evaluates to true
if both this Condition
and the specifed right-hand-side Condition
are true, evaluates to false
if either condition is false, or evaluates to UNKNOWN
otherwise.rhs
- A Condition
that is the right-hand-side condition.Condition
that represents a logical AND
operation on this Condition
and the rhs
Condition
.public final Condition or(Condition rhs)
Condition
that represents a logical OR
condition. The Condition
returned by this method represents a condition that evaluates to true
if either this Condition
or the specifed right-hand-side Condition
is true, evaluates to false
if both conditions are false, or evaluates to UNKNOWN
otherwise.rhs
- A Condition
that is the right-hand-side condition.Condition
that represents a logical OR
operation on this Condition
and the rhs
Condition
.public final Condition not()
Condition
that represents a logical NOT
condition, which reverses, or negates, the Boolean value of this Condition
. The Condition
returned by this method represents a condition that evaluates to true
if this Condition
is false, evaluates to false
if this Condition
is true, or evaluates to UNKNOWN
if this Condition
is UNKNOWN
.Condition
that represents the negation of this Condition
.public boolean isCompositeObject()
Condition
contains other SyntaxObject
objects.boolean
that is true
if Condition
contains other SyntaxObject
objects or is false
otherwise.