Package org.hibernate.query.sqm
Interface SqmPathSource<J>
- All Superinterfaces:
Bindable<J>,PathSource<J>,SqmExpressible<J>,SqmExpressibleAccessor<J>
- All Known Subinterfaces:
CompositeSqmPathSource<J>,SqmBagPersistentAttribute<D,,E> SqmEmbeddableDomainType<E>,SqmEntityDomainType<E>,SqmListPersistentAttribute<D,,E> SqmMappedSuperclassDomainType<T>,SqmMapPersistentAttribute<D,,K, V> SqmPluralPersistentAttribute<D,,C, E> SqmSetPersistentAttribute<D,,E> SqmSingularPersistentAttribute<D,,J> SqmTreatableDomainType<T>
- All Known Implementing Classes:
AbstractDiscriminatorSqmPathSource,AbstractPluralAttribute,AbstractSqmPathSource,AnonymousTupleSimpleSqmPathSource,AnonymousTupleSqmAssociationPathSource,AnonymousTupleSqmAssociationPathSourceNew,AnonymousTupleSqmPathSource,AnonymousTupleSqmPathSourceNew,AnonymousTupleType,AnyDiscriminatorSqmPathSource,AnyMappingSqmPathSource,BagAttributeImpl,BasicSqmPathSource,EmbeddableTypeImpl,EmbeddedDiscriminatorSqmPathSource,EmbeddedSqmPathSource,EntityDiscriminatorSqmPathSource,EntitySqmPathSource,EntityTypeImpl,ListAttributeImpl,MapAttributeImpl,MappedSuperclassSqmPathSource,MappedSuperclassTypeImpl,NonAggregatedCompositeSqmPathSource,SetAttributeImpl,SingularAttributeImpl,SingularAttributeImpl.Identifier,SingularAttributeImpl.Version,SqmCteTable,SqmPolymorphicRootDescriptor
public interface SqmPathSource<J>
extends SqmExpressible<J>, Bindable<J>, SqmExpressibleAccessor<J>, PathSource<J>
Represents any part of the domain model which can be used to create a
SqmPath node.- API Note:
- Parallel to the JPA-defined interface
Bindablebut broader mainly to support@Anymappings
-
Nested Class Summary
Nested classes/interfaces inherited from interface jakarta.persistence.metamodel.Bindable
Bindable.BindableType -
Method Summary
Modifier and TypeMethodDescriptioncreateSqmPath(SqmPath<?> lhs, SqmPathSource<?> intermediatePathSource) Create an SQM path for this source relative to the given left hand sidefindSubPathSource(String name) Find aSqmPathSourceby name relative to this source.default SqmPathSource<?> findSubPathSource(String name, boolean includeSubtypes) Find aSqmPathSourceby name relative to this source.default SqmBindableType<J> default SqmPathSource<?> getIntermediatePathSource(SqmPathSource<?> pathSource) Returns the intermediateSqmPathSourcefor a path source previously acquired viafindSubPathSource(String).The type of path this source creates.default SqmDomainType<J> default SqmPathSource<?> getSubPathSource(String name) Find aSqmPathSourceby name relative to this source.default SqmPathSource<?> getSubPathSource(String name, boolean subtypes) Find aSqmPathSourceby name relative to this source.default booleanIndicates if this path source is generically typedMethods inherited from interface jakarta.persistence.metamodel.Bindable
getBindableJavaType, getBindableTypeMethods inherited from interface org.hibernate.metamodel.model.domain.PathSource
getPathNameMethods inherited from interface org.hibernate.query.sqm.SqmExpressible
getExpressibleJavaType, getRelationalJavaType, getTypeNameMethods inherited from interface org.hibernate.query.sqm.tree.SqmExpressibleAccessor
getNodeJavaType
-
Method Details
-
getPathType
SqmDomainType<J> getPathType()The type of path this source creates.- Specified by:
getPathTypein interfacePathSource<J>
-
findSubPathSource
Find aSqmPathSourceby name relative to this source.- Specified by:
findSubPathSourcein interfacePathSource<J>- Parameters:
name- the name of the path source to find- Returns:
- null if the subPathSource is not found
- Throws:
IllegalStateException- to indicate that this source cannot be de-referenced
-
findSubPathSource
Find aSqmPathSourceby name relative to this source. IfincludeSubtypesis set totrueand this path source is polymorphic, also try finding subtype attributes.- Specified by:
findSubPathSourcein interfacePathSource<J>- Parameters:
name- the name of the path source to findincludeSubtypes- flag indicating whether to consider subtype attributes- Returns:
- null if the subPathSource is not found
- Throws:
IllegalStateException- to indicate that this source cannot be de-referenced
-
getSubPathSource
Find aSqmPathSourceby name relative to this source.- Parameters:
name- the name of the path source to find- Throws:
IllegalStateException- to indicate that this source cannot be de-referencedIllegalArgumentException- if the subPathSource is not found
-
getSubPathSource
Find aSqmPathSourceby name relative to this source. Ifsubtypesis set totrueand this path source is polymorphic, also try finding subtype attributes.- Parameters:
name- the name of the path source to findsubtypes- flag indicating whether to consider subtype attributes- Throws:
IllegalStateException- to indicate that this source cannot be de-referencedIllegalArgumentException- if the subPathSource is not found
-
getIntermediatePathSource
Returns the intermediateSqmPathSourcefor a path source previously acquired viafindSubPathSource(String). -
createSqmPath
Create an SQM path for this source relative to the given left hand side -
getExpressible
- Specified by:
getExpressiblein interfaceSqmExpressibleAccessor<J>
-
getSqmType
- Specified by:
getSqmTypein interfaceSqmExpressible<J>
-
isGeneric
default boolean isGeneric()Indicates if this path source is generically typed
-