Class SqmEnumLiteral<E extends Enum<E>>
java.lang.Object
org.hibernate.query.sqm.tree.AbstractSqmNode
org.hibernate.query.sqm.tree.jpa.AbstractJpaTupleElement<E>
org.hibernate.query.sqm.tree.jpa.AbstractJpaSelection<E>
org.hibernate.query.sqm.tree.expression.AbstractSqmExpression<E>
org.hibernate.query.sqm.tree.expression.SqmLiteral<E>
org.hibernate.query.sqm.tree.expression.SqmEnumLiteral<E>
- All Implemented Interfaces:
Expression<E>,Selection<E>,Type<E>,TupleElement<E>,Serializable,JpaCriteriaNode,JpaExpression<E>,JpaSelection<E>,JpaTupleElement<E>,SemanticPathPart,SqmBindableType<E>,SqmExpressible<E>,SqmExpression<E>,SqmSelectableNode<E>,SqmExpressibleAccessor<E>,SqmNode,SqmTypedNode<E>,SqmVisitableNode,BindableType<E>
public class SqmEnumLiteral<E extends Enum<E>>
extends SqmLiteral<E>
implements SqmBindableType<E>, SemanticPathPart
Specialized SQM literal defined by an enum reference. E.g.
".. where p.sex = Sex.MALE"- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface jakarta.persistence.metamodel.Type
Type.PersistenceType -
Field Summary
-
Constructor Summary
ConstructorsConstructorDescriptionSqmEnumLiteral(E enumValue, EnumJavaType<E> referencedEnumTypeDescriptor, String enumValueName, NodeBuilder nodeBuilder) -
Method Summary
Modifier and TypeMethodDescription<X> Xaccept(SemanticQueryWalker<X> walker) Accept the walker per visitationvoidappendHqlString(StringBuilder hql, SqmRenderContext context) asDouble()asFloat()asLong()asString()copy(SqmCopyContext context) The Java type descriptor for this expressibleSqmPath<?> resolveIndexedAccess(SqmExpression<?> selector, boolean isTerminal, SqmCreationState creationState) resolvePathPart(String name, boolean isTerminal, SqmCreationState creationState) Methods inherited from class org.hibernate.query.sqm.tree.expression.SqmLiteral
appendHqlString, asLoggableText, equals, getLiteralValue, hashCodeMethods inherited from class org.hibernate.query.sqm.tree.expression.AbstractSqmExpression
applyInferableType, as, cast, equalTo, equalTo, getJavaTypeDescriptor, in, in, in, in, internalApplyInferableType, isNotNull, isNull, nodeBuilder, notEqualTo, notEqualToMethods inherited from class org.hibernate.query.sqm.tree.jpa.AbstractJpaSelection
alias, getSelectionItems, isCompoundSelectionMethods inherited from class org.hibernate.query.sqm.tree.jpa.AbstractJpaTupleElement
copyTo, getAlias, getNodeType, setAlias, setExpressibleTypeMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.hibernate.query.criteria.JpaSelection
alias, getCompoundSelectionItems, getSelectionItemsMethods inherited from interface org.hibernate.query.criteria.JpaTupleElement
getJavaTypeName, isEnumMethods inherited from interface jakarta.persistence.criteria.Selection
isCompoundSelectionMethods inherited from interface org.hibernate.query.sqm.SqmBindableType
resolveExpressibleMethods inherited from interface org.hibernate.query.sqm.SqmExpressible
getRelationalJavaType, getTypeNameMethods inherited from interface org.hibernate.query.sqm.tree.expression.SqmExpression
castAs, getNodeType, visitSubSelectableNodesMethods inherited from interface org.hibernate.query.sqm.tree.select.SqmSelectableNode
getTupleLengthMethods inherited from interface org.hibernate.query.sqm.tree.SqmTypedNode
getNodeJavaTypeMethods inherited from interface org.hibernate.query.sqm.tree.SqmVisitableNode
toHqlStringMethods inherited from interface jakarta.persistence.TupleElement
getAlias
-
Constructor Details
-
SqmEnumLiteral
public SqmEnumLiteral(E enumValue, EnumJavaType<E> referencedEnumTypeDescriptor, String enumValueName, NodeBuilder nodeBuilder)
-
-
Method Details
-
copy
-
getExpressible
- Specified by:
getExpressiblein interfaceSqmExpressibleAccessor<E extends Enum<E>>- Specified by:
getExpressiblein interfaceSqmTypedNode<E extends Enum<E>>
-
getPersistenceType
- Specified by:
getPersistenceTypein interfaceType<E extends Enum<E>>
-
getSqmType
- Specified by:
getSqmTypein interfaceSqmExpressible<E extends Enum<E>>
-
getEnumValue
-
getExpressibleJavaType
Description copied from interface:SqmExpressibleThe Java type descriptor for this expressible- Specified by:
getExpressibleJavaTypein interfaceSqmExpressible<E extends Enum<E>>
-
getJavaType
- Specified by:
getJavaTypein interfaceJpaTupleElement<E extends Enum<E>>- Specified by:
getJavaTypein interfaceTupleElement<E extends Enum<E>>- Specified by:
getJavaTypein interfaceType<E extends Enum<E>>
-
resolvePathPart
public SemanticPathPart resolvePathPart(String name, boolean isTerminal, SqmCreationState creationState) - Specified by:
resolvePathPartin interfaceSemanticPathPart
-
resolveIndexedAccess
public SqmPath<?> resolveIndexedAccess(SqmExpression<?> selector, boolean isTerminal, SqmCreationState creationState) - Specified by:
resolveIndexedAccessin interfaceSemanticPathPart
-
asLong
- Specified by:
asLongin interfaceJpaExpression<E extends Enum<E>>- Specified by:
asLongin interfaceSqmExpression<E extends Enum<E>>- Overrides:
asLongin classAbstractSqmExpression<E extends Enum<E>>
-
asInteger
- Specified by:
asIntegerin interfaceJpaExpression<E extends Enum<E>>- Specified by:
asIntegerin interfaceSqmExpression<E extends Enum<E>>- Overrides:
asIntegerin classAbstractSqmExpression<E extends Enum<E>>
-
asFloat
- Specified by:
asFloatin interfaceJpaExpression<E extends Enum<E>>- Specified by:
asFloatin interfaceSqmExpression<E extends Enum<E>>- Overrides:
asFloatin classAbstractSqmExpression<E extends Enum<E>>
-
asDouble
- Specified by:
asDoublein interfaceJpaExpression<E extends Enum<E>>- Specified by:
asDoublein interfaceSqmExpression<E extends Enum<E>>- Overrides:
asDoublein classAbstractSqmExpression<E extends Enum<E>>
-
asBigDecimal
- Specified by:
asBigDecimalin interfaceJpaExpression<E extends Enum<E>>- Specified by:
asBigDecimalin interfaceSqmExpression<E extends Enum<E>>- Overrides:
asBigDecimalin classAbstractSqmExpression<E extends Enum<E>>
-
asBigInteger
- Specified by:
asBigIntegerin interfaceJpaExpression<E extends Enum<E>>- Specified by:
asBigIntegerin interfaceSqmExpression<E extends Enum<E>>- Overrides:
asBigIntegerin classAbstractSqmExpression<E extends Enum<E>>
-
asString
- Specified by:
asStringin interfaceJpaExpression<E extends Enum<E>>- Specified by:
asStringin interfaceSqmExpression<E extends Enum<E>>- Overrides:
asStringin classAbstractSqmExpression<E extends Enum<E>>
-
accept
Description copied from interface:SqmVisitableNodeAccept the walker per visitation- Specified by:
acceptin interfaceSqmVisitableNode- Overrides:
acceptin classSqmLiteral<E extends Enum<E>>
-
appendHqlString
- Specified by:
appendHqlStringin interfaceSqmVisitableNode- Overrides:
appendHqlStringin classSqmLiteral<E extends Enum<E>>
-