Class InImpl<T>
- java.lang.Object
-
- org.eclipse.persistence.internal.jpa.querydef.SelectionImpl<X>
-
- org.eclipse.persistence.internal.jpa.querydef.ExpressionImpl<X>
-
- org.eclipse.persistence.internal.jpa.querydef.FunctionExpressionImpl<java.lang.Boolean>
-
- org.eclipse.persistence.internal.jpa.querydef.CompoundExpressionImpl
-
- org.eclipse.persistence.internal.jpa.querydef.InImpl<T>
-
- All Implemented Interfaces:
java.io.Serializable
,javax.persistence.criteria.CriteriaBuilder.In<T>
,javax.persistence.criteria.Expression<java.lang.Boolean>
,javax.persistence.criteria.Predicate
,javax.persistence.criteria.Selection<java.lang.Boolean>
,javax.persistence.TupleElement<java.lang.Boolean>
,InternalExpression
,InternalSelection
public class InImpl<T> extends CompoundExpressionImpl implements javax.persistence.criteria.CriteriaBuilder.In<T>
Purpose: Contains the implementation of the In interface of the JPA criteria API.
Description: This class represents an In predicate.
- Since:
- EclipseLink 1.2
- Author:
- gyorke
- See Also:
Join
, Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected ExpressionImpl
leftExpression
protected org.eclipse.persistence.expressions.Expression
parentNode
-
Fields inherited from class org.eclipse.persistence.internal.jpa.querydef.CompoundExpressionImpl
isNegated
-
Fields inherited from class org.eclipse.persistence.internal.jpa.querydef.FunctionExpressionImpl
expressions, operator
-
Fields inherited from class org.eclipse.persistence.internal.jpa.querydef.ExpressionImpl
isLiteral, literal, metamodel
-
Fields inherited from class org.eclipse.persistence.internal.jpa.querydef.SelectionImpl
alias, currentNode, javaType
-
-
Constructor Summary
Constructors Constructor Description InImpl(javax.persistence.metamodel.Metamodel metamodel, ExpressionImpl leftExpression, java.util.Collection values, java.util.List expressions)
InImpl(javax.persistence.metamodel.Metamodel metamodel, ExpressionImpl leftExpression, ExpressionImpl rightExp, java.util.List expressions)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
findRootAndParameters(CommonAbstractCriteriaImpl query)
javax.persistence.criteria.Expression<T>
getExpression()
Returns the expression to be tested against the list of values.boolean
isPredicate()
javax.persistence.criteria.Predicate
not()
Apply negation to the predicate.void
setParentNode(org.eclipse.persistence.expressions.Expression parentNode)
This method is used to store what will be the parent EclipseLink expression in the case the tree needs to be altered.javax.persistence.criteria.CriteriaBuilder.In<T>
value(javax.persistence.criteria.Expression<? extends T> value)
Add to list of values to be tested against.javax.persistence.criteria.CriteriaBuilder.In<T>
value(T value)
Add to list of values to be tested against.-
Methods inherited from class org.eclipse.persistence.internal.jpa.querydef.CompoundExpressionImpl
getExpressions, getOperator, isCompoundExpression, isExpression, isNegated, setIsNegated, setOperator
-
Methods inherited from class org.eclipse.persistence.internal.jpa.querydef.FunctionExpressionImpl
getChildExpressions, getOperation
-
Methods inherited from class org.eclipse.persistence.internal.jpa.querydef.ExpressionImpl
as, buildExpressionForAs, in, in, in, in, isJunction, isLiteral, isNotNull, isNull, isParameter, isSubquery
-
Methods inherited from class org.eclipse.persistence.internal.jpa.querydef.SelectionImpl
alias, getAlias, getCompoundSelectionItems, getCurrentNode, getJavaType, isCompoundSelection, isConstructor, isFrom, isRoot, setJavaType
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface javax.persistence.criteria.Expression
as, in, in, in, in, isNotNull, isNull
-
Methods inherited from interface javax.persistence.criteria.Predicate
getExpressions, getOperator, isNegated
-
-
-
-
Field Detail
-
parentNode
protected org.eclipse.persistence.expressions.Expression parentNode
-
leftExpression
protected ExpressionImpl leftExpression
-
-
Constructor Detail
-
InImpl
public InImpl(javax.persistence.metamodel.Metamodel metamodel, ExpressionImpl leftExpression, java.util.Collection values, java.util.List expressions)
-
InImpl
public InImpl(javax.persistence.metamodel.Metamodel metamodel, ExpressionImpl leftExpression, ExpressionImpl rightExp, java.util.List expressions)
-
-
Method Detail
-
getExpression
public javax.persistence.criteria.Expression<T> getExpression()
Returns the expression to be tested against the list of values.- Specified by:
getExpression
in interfacejavax.persistence.criteria.CriteriaBuilder.In<T>
- Returns:
- expression
-
findRootAndParameters
public void findRootAndParameters(CommonAbstractCriteriaImpl query)
- Specified by:
findRootAndParameters
in interfaceInternalSelection
- Overrides:
findRootAndParameters
in classFunctionExpressionImpl<java.lang.Boolean>
-
isPredicate
public boolean isPredicate()
- Specified by:
isPredicate
in interfaceInternalExpression
- Overrides:
isPredicate
in classCompoundExpressionImpl
-
value
public javax.persistence.criteria.CriteriaBuilder.In<T> value(T value)
Add to list of values to be tested against.- Specified by:
value
in interfacejavax.persistence.criteria.CriteriaBuilder.In<T>
- Parameters:
value
- value- Returns:
- in predicate
-
value
public javax.persistence.criteria.CriteriaBuilder.In<T> value(javax.persistence.criteria.Expression<? extends T> value)
Add to list of values to be tested against.- Specified by:
value
in interfacejavax.persistence.criteria.CriteriaBuilder.In<T>
- Parameters:
value
- expression- Returns:
- in predicate
-
setParentNode
public void setParentNode(org.eclipse.persistence.expressions.Expression parentNode)
This method is used to store what will be the parent EclipseLink expression in the case the tree needs to be altered. Currently used for In.- Overrides:
setParentNode
in classCompoundExpressionImpl
-
not
public javax.persistence.criteria.Predicate not()
Description copied from class:CompoundExpressionImpl
Apply negation to the predicate.- Specified by:
not
in interfacejavax.persistence.criteria.Predicate
- Overrides:
not
in classCompoundExpressionImpl
- Returns:
- the negated predicate
-
-