Class LogicalPredicate
java.lang.Object
org.apache.openjpa.persistence.query.LogicalPredicate
- All Implemented Interfaces:
Serializable,Predicate,Visitable
- Direct Known Subclasses:
AndPredicate,OrPredicate
Logical Predicate combines two predicates with a logical operator.
- Author:
- Pinaki Poddar
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionLogicalPredicate(Predicate p1, ConditionalOperator op, ConditionalOperator nop, Predicate p2) -
Method Summary
Modifier and TypeMethodDescriptionCreates an AND of the predicate with the argument.asExpression(org.apache.openjpa.persistence.query.AliasContext ctx) Get a JPQL fragment as used in WHERE clause.asJoinable(org.apache.openjpa.persistence.query.AliasContext ctx) Gets the string representation in FROM clause.asProjection(org.apache.openjpa.persistence.query.AliasContext ctx) Gets the string representation in SELECT projection.getAliasHint(org.apache.openjpa.persistence.query.AliasContext ctx) Gets the hint to be used while creating alias.not()Creates a negation of the predicate with the argument.Creates an OR of the predicate with the argument.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.openjpa.persistence.query.Visitable
asJoinable, asProjection, getAliasHint
-
Field Details
-
SPACE
- See Also:
-
OPEN_BRACE
- See Also:
-
CLOSE_BRACE
- See Also:
-
COMMA
- See Also:
-
EMPTY
- See Also:
-
-
Constructor Details
-
LogicalPredicate
public LogicalPredicate(Predicate p1, ConditionalOperator op, ConditionalOperator nop, Predicate p2)
-
-
Method Details
-
and
Description copied from interface:PredicateCreates an AND of the predicate with the argument. -
or
Description copied from interface:PredicateCreates an OR of the predicate with the argument. -
not
Description copied from interface:PredicateCreates a negation of the predicate with the argument. -
asExpression
Description copied from interface:VisitableGet a JPQL fragment as used in WHERE clause.- Specified by:
asExpressionin interfaceVisitable
-
asProjection
Description copied from interface:VisitableGets the string representation in SELECT projection.- Specified by:
asProjectionin interfaceVisitable
-
getAliasHint
Description copied from interface:VisitableGets the hint to be used while creating alias.- Specified by:
getAliasHintin interfaceVisitable
-
asJoinable
Description copied from interface:VisitableGets the string representation in FROM clause.- Specified by:
asJoinablein interfaceVisitable
-