Top Description Fields Constructors Methods
org.eclipse.persistence.internal.jpa.querydef

public Class ExpressionImpl<X>

extends SelectionImpl<X>
implements Expression<X>, InternalExpression
Class Inheritance
All Implemented Interfaces
org.eclipse.persistence.internal.jpa.querydef.InternalExpression, jakarta.persistence.criteria.Expression, jakarta.persistence.criteria.Selection, jakarta.persistence.TupleElement
Known Direct Subclasses
org.eclipse.persistence.internal.jpa.querydef.ParameterExpressionImpl, org.eclipse.persistence.internal.jpa.querydef.PathImpl, org.eclipse.persistence.internal.jpa.querydef.FunctionExpressionImpl
Imports
java.util.ArrayList, .Collection, .List, jakarta.persistence.criteria.Expression, .Predicate, jakarta.persistence.metamodel.Metamodel, org.eclipse.persistence.descriptors.ClassDescriptor, org.eclipse.persistence.internal.jpa.metamodel.MetamodelImpl, org.eclipse.persistence.internal.localization.ExceptionLocalization, org.eclipse.persistence.sessions.Project

Purpose: Represents an Expression in the Criteria API heirarchy.

Description: Expressions are expression nodes that can not be joined from and may or not be the result of a Path expression.

Author
gyorke
Since
EclipseLink 1.2
See Also
Expression

Field Summary

Modifier and TypeField and Description
protected boolean
protected Object
protected Metamodel
Inherited from org.eclipse.persistence.internal.jpa.querydef.SelectionImpl:
aliascurrentNodejavaType

Constructor Summary

AccessConstructor and Description
protected
ExpressionImpl(Metamodel metamodel, Class<X> javaType, Expression expressionNode)

public
ExpressionImpl(Metamodel metamodel, Class<X> javaType, Expression expressionNode, Object value)

Method Summary

Modifier and TypeMethod and Description
public <T> Expression<T>
as(Class<T>
intended type of the expression
type
)

Implements jakarta.persistence.criteria.Expression.as.

Perform a typecast upon the expression, returning a new expression object.
protected <T> Expression<T>
public void
public Predicate
in(Object...
values to be tested against
values
)

Implements jakarta.persistence.criteria.Expression.in.

Create a predicate to test whether the expression is a member of the argument list.
public Predicate

Returns:

predicate testing for membership
in
(Expression<?>...
expressions to be tested against
values
)

Implements jakarta.persistence.criteria.Expression.in.

Apply a predicate to test whether the expression is a member of the argument list.
public Predicate

Returns:

predicate testing for membership
in
(Collection<?>
collection
values
)

Implements jakarta.persistence.criteria.Expression.in.

Apply a predicate to test whether the expression is a member of the collection.
public Predicate

Returns:

predicate testing for membership
in
(Expression<Collection<?>>
expression corresponding to collection
values
)

Implements jakarta.persistence.criteria.Expression.in.

Apply a predicate to test whether the expression is a member of the collection.
public boolean
public boolean
public boolean
public boolean
public Predicate
isNotNull()

Implements jakarta.persistence.criteria.Expression.isNotNull.

Create a predicate to test whether the expression is not null.
public Predicate
isNull()

Implements jakarta.persistence.criteria.Expression.isNull.

Create a predicate to test whether the expression is null.
public boolean
public boolean
public boolean
Inherited from org.eclipse.persistence.internal.jpa.querydef.SelectionImpl:
aliasgetAliasgetCompoundSelectionItemsgetCurrentNodegetJavaTypeisCompoundSelectionisConstructorisFromisRootsetJavaType

Field Detail

isLiteralback to summary
protected boolean isLiteral
literalback to summary
protected Object literal
metamodelback to summary
protected Metamodel metamodel

Constructor Detail

ExpressionImplback to summary
protected ExpressionImpl(Metamodel metamodel, Class<X> javaType, Expression expressionNode)
ExpressionImplback to summary
public ExpressionImpl(Metamodel metamodel, Class<X> javaType, Expression expressionNode, Object value)

Method Detail

asback to summary
public <T> Expression<T> as(Class<T> type)

Implements jakarta.persistence.criteria.Expression.as.

Doc from jakarta.persistence.criteria.Expression.as.

Perform a typecast upon the expression, returning a new expression object. This method does not cause type conversion: the runtime type is not changed.

Warning

may result in a runtime failure.

Parameters
type:Class<T>

intended type of the expression

Returns:Expression<T>

new expression of the given type

Annotations
@Override
buildExpressionForAsback to summary
protected <T> Expression<T> buildExpressionForAs(Class<T> type)
findRootAndParametersback to summary
public void findRootAndParameters(CommonAbstractCriteriaImpl<T> criteriaQuery)

Implements org.eclipse.persistence.internal.jpa.querydef.InternalSelection.findRootAndParameters.

Annotations
@Override
inback to summary
public Predicate in(Object... values)

Implements jakarta.persistence.criteria.Expression.in.

Doc from jakarta.persistence.criteria.Expression.in.

Create a predicate to test whether the expression is a member of the argument list.

Parameters
values:Object[]

values to be tested against

Returns:Predicate

predicate testing for membership

Annotations
@Override
inback to summary
public Predicate in(Expression<?>... values)

Implements jakarta.persistence.criteria.Expression.in.

Apply a predicate to test whether the expression is a member of the argument list.

Parameters
values:Expression<?>[]

Doc from jakarta.persistence.criteria.Expression.in.

expressions to be tested against

Returns:Predicate

predicate testing for membership

Annotations
@Override
inback to summary
public Predicate in(Collection<?> values)

Implements jakarta.persistence.criteria.Expression.in.

Apply a predicate to test whether the expression is a member of the collection.

Parameters
values:Collection<?>

collection

Returns:Predicate

predicate testing for membership

Annotations
@Override
inback to summary
public Predicate in(Expression<Collection<?>> values)

Implements jakarta.persistence.criteria.Expression.in.

Apply a predicate to test whether the expression is a member of the collection.

Parameters
values:Expression<Collection<?>>

expression corresponding to collection

Returns:Predicate

predicate testing for membership

Annotations
@Override
isCompoundExpressionback to summary
public boolean isCompoundExpression()

Implements org.eclipse.persistence.internal.jpa.querydef.InternalExpression.isCompoundExpression.

Annotations
@Override
isExpressionback to summary
public boolean isExpression()

Implements org.eclipse.persistence.internal.jpa.querydef.InternalExpression.isExpression.

Annotations
@Override
isJunctionback to summary
public boolean isJunction()

Implements org.eclipse.persistence.internal.jpa.querydef.InternalExpression.isJunction.

Annotations
@Override
isLiteralback to summary
public boolean isLiteral()

Implements org.eclipse.persistence.internal.jpa.querydef.InternalExpression.isLiteral.

Annotations
@Override
isNotNullback to summary
public Predicate isNotNull()

Implements jakarta.persistence.criteria.Expression.isNotNull.

Doc from jakarta.persistence.criteria.Expression.isNotNull.

Create a predicate to test whether the expression is not null.

Returns:Predicate

predicate testing whether the expression is not null

Annotations
@Override
isNullback to summary
public Predicate isNull()

Implements jakarta.persistence.criteria.Expression.isNull.

Doc from jakarta.persistence.criteria.Expression.isNull.

Create a predicate to test whether the expression is null.

Returns:Predicate

predicate testing whether the expression is null

Annotations
@Override
isParameterback to summary
public boolean isParameter()

Implements org.eclipse.persistence.internal.jpa.querydef.InternalExpression.isParameter.

Annotations
@Override
isPredicateback to summary
public boolean isPredicate()

Implements org.eclipse.persistence.internal.jpa.querydef.InternalExpression.isPredicate.

Annotations
@Override
isSubqueryback to summary
public boolean isSubquery()

Implements org.eclipse.persistence.internal.jpa.querydef.InternalExpression.isSubquery.

Annotations
@Override