public class InPredicate<T> extends AbstractSimplePredicate implements CriteriaBuilder.In<T>, Serializable
Predicate.BooleanOperatorParameterContainer.Helper| Constructor and Description |
|---|
InPredicate(CriteriaBuilderImpl criteriaBuilder,
Expression<? extends T> expression)
Constructs an IN predicate against a given expression with an empty list of values.
|
InPredicate(CriteriaBuilderImpl criteriaBuilder,
Expression<? extends T> expression,
Collection<T> values)
Constructs an IN predicate against a given expression with the given literal value list.
|
InPredicate(CriteriaBuilderImpl criteriaBuilder,
Expression<? extends T> expression,
Expression<? extends T>... values)
Constructs an IN predicate against a given expression with the given list of expression values.
|
InPredicate(CriteriaBuilderImpl criteriaBuilder,
Expression<? extends T> expression,
List<Expression<? extends T>> values)
Constructs an IN predicate against a given expression with the given list of expression values.
|
InPredicate(CriteriaBuilderImpl criteriaBuilder,
Expression<? extends T> expression,
T... values)
Constructs an IN predicate against a given expression with the given given literal value list.
|
| Modifier and Type | Method and Description |
|---|---|
Expression<T> |
getExpression()
Return the expression to be tested against the
list of values.
|
Expression<? extends T> |
getExpressionInternal() |
List<Expression<? extends T>> |
getValues() |
void |
registerParameters(ParameterRegistry registry)
Register any parameters contained within this query component with the given registry.
|
String |
render(boolean isNegated,
RenderingContext renderingContext)
Form of
Renderable.render(org.hibernate.jpa.criteria.compile.RenderingContext) used when the predicate is wrapped in a negated wrapper. |
InPredicate<T> |
value(Expression<? extends T> value)
Add to list of values to be tested against.
|
InPredicate<T> |
value(T value)
Add to list of values to be tested against.
|
getExpressions, getOperator, isJunction, render, renderProjectiongetCompoundSelectionItems, isCompoundSelection, isNegated, notas, asBigDecimal, asBigInteger, asDouble, asFloat, asInteger, asLong, asString, in, in, in, in, isNotNull, isNullalias, getValueHandlersforceConversion, getAlias, getJavaType, getValueHandler, resetJavaType, setAliascriteriaBuilderclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetExpressions, getOperator, isNegated, notas, in, in, in, in, isNotNull, isNullalias, getCompoundSelectionItems, isCompoundSelectiongetAlias, getJavaTypecriteriaBuildergetValueHandlersgetValueHandlerpublic InPredicate(CriteriaBuilderImpl criteriaBuilder, Expression<? extends T> expression)
criteriaBuilder - The query builder from which this originates.expression - The expression.public InPredicate(CriteriaBuilderImpl criteriaBuilder, Expression<? extends T> expression, Expression<? extends T>... values)
criteriaBuilder - The query builder from which this originates.expression - The expression.values - The value list.public InPredicate(CriteriaBuilderImpl criteriaBuilder, Expression<? extends T> expression, List<Expression<? extends T>> values)
criteriaBuilder - The query builder from which this originates.expression - The expression.values - The value list.public InPredicate(CriteriaBuilderImpl criteriaBuilder, Expression<? extends T> expression, T... values)
criteriaBuilder - The query builder from which this originates.expression - The expression.values - The value list.public InPredicate(CriteriaBuilderImpl criteriaBuilder, Expression<? extends T> expression, Collection<T> values)
criteriaBuilder - The query builder from which this originates.expression - The expression.values - The value list.public Expression<T> getExpression()
CriteriaBuilder.IngetExpression in interface CriteriaBuilder.In<T>public Expression<? extends T> getExpressionInternal()
public List<Expression<? extends T>> getValues()
public InPredicate<T> value(T value)
CriteriaBuilder.Invalue in interface CriteriaBuilder.In<T>value - valuepublic InPredicate<T> value(Expression<? extends T> value)
CriteriaBuilder.Invalue in interface CriteriaBuilder.In<T>value - expressionpublic void registerParameters(ParameterRegistry registry)
ParameterContainerregisterParameters in interface ParameterContainerregistry - The parameter registry with which to register.public String render(boolean isNegated, RenderingContext renderingContext)
PredicateImplementorRenderable.render(org.hibernate.jpa.criteria.compile.RenderingContext) used when the predicate is wrapped in a negated wrapper. Allows passing
down the negation flag.
Note that this form is no-op in compound (junction) predicates. The reason being that compound predicates
are more complex and the negation is applied during its creation.render in interface PredicateImplementorisNegated - Should the predicate be negated.renderingContext - The context for renderingCopyright © 2017 JBoss by Red Hat. All rights reserved.