Package org.hibernate.query.sqm
Interface SqmPathSource<J>
-
- All Superinterfaces:
Bindable<J>
,BindableType<J>
,SqmExpressible<J>
,SqmExpressibleAccessor<J>
- All Known Subinterfaces:
BagPersistentAttribute<D,E>
,CompositeSqmPathSource<J>
,EntityDomainType<J>
,ListPersistentAttribute<D,E>
,MappedSuperclassDomainType<J>
,MapPersistentAttribute<D,K,V>
,PluralPersistentAttribute<D,C,E>
,SetPersistentAttribute<D,E>
,SingularPersistentAttribute<D,J>
- All Known Implementing Classes:
AbstractPluralAttribute
,AbstractSqmPathSource
,AnonymousTupleSimpleSqmPathSource
,AnonymousTupleSqmAssociationPathSource
,AnonymousTupleSqmPathSource
,AnonymousTupleType
,AnyDiscriminatorSqmPathSource
,AnyMappingSqmPathSource
,BagAttributeImpl
,BasicSqmPathSource
,DiscriminatorSqmPathSource
,EmbeddedSqmPathSource
,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>
Represents any part of the domain model which can be used to create aSqmPath
node.- API Note:
- Parallel to the JPA-defined interface
Bindable
but broader mainly to support@Any
mappings
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface jakarta.persistence.metamodel.Bindable
Bindable.BindableType
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description SqmPath<J>
createSqmPath(SqmPath<?> lhs, SqmPathSource<?> intermediatePathSource)
Create an SQM path for this source relative to the given left hand sideSqmPathSource<?>
findSubPathSource(String name)
Find aSqmPathSource
by name relative to this source.default SqmPathSource<?>
findSubPathSource(String name, JpaMetamodelImplementor metamodel)
Find aSqmPathSource
by name relative to this source.default SqmExpressible<J>
getExpressible()
default SqmPathSource<?>
getIntermediatePathSource(SqmPathSource<?> pathSource)
Returns the intermediateSqmPathSource
for a path source previously acquired viafindSubPathSource(String)
.String
getPathName()
The name of this thing.DomainType<J>
getSqmPathType()
The type of path this source creates.default DomainType<J>
getSqmType()
default SqmPathSource<?>
getSubPathSource(String name)
Find aSqmPathSource
by name relative to this source.default SqmPathSource<?>
getSubPathSource(String name, JpaMetamodelImplementor metamodel)
Find aSqmPathSource
by name relative to this source.default boolean
isGeneric()
Indicates if this path source is generically typed-
Methods inherited from interface jakarta.persistence.metamodel.Bindable
getBindableJavaType, getBindableType
-
Methods inherited from interface org.hibernate.query.BindableType
getBindableJavaType
-
Methods inherited from interface org.hibernate.query.sqm.SqmExpressible
getExpressibleJavaType, getRelationalJavaType, getTypeName, isInstance, resolveExpressible
-
Methods inherited from interface org.hibernate.query.sqm.tree.SqmExpressibleAccessor
getNodeJavaType
-
-
-
-
Method Detail
-
getPathName
String getPathName()
The name of this thing.- API Note:
- Mainly used in logging and when creating a
NavigablePath
.
-
getSqmPathType
DomainType<J> getSqmPathType()
The type of path this source creates.- API Note:
- Analogous to
Bindable.getBindableJavaType()
.
-
findSubPathSource
SqmPathSource<?> findSubPathSource(String name)
Find aSqmPathSource
by name relative to this source.- Returns:
- null if the subPathSource is not found
- Throws:
IllegalStateException
- to indicate that this source cannot be de-referenced
-
findSubPathSource
default SqmPathSource<?> findSubPathSource(String name, JpaMetamodelImplementor metamodel)
Find aSqmPathSource
by name relative to this source.- Returns:
- null if the subPathSource is not found
- Throws:
IllegalStateException
- to indicate that this source cannot be de-referenced
-
getSubPathSource
default SqmPathSource<?> getSubPathSource(String name)
Find aSqmPathSource
by name relative to this source.- Throws:
IllegalStateException
- to indicate that this source cannot be de-referencedIllegalArgumentException
- if the subPathSource is not found
-
getSubPathSource
default SqmPathSource<?> getSubPathSource(String name, JpaMetamodelImplementor metamodel)
Find aSqmPathSource
by name relative to this source.- Throws:
IllegalStateException
- to indicate that this source cannot be de-referencedIllegalArgumentException
- if the subPathSource is not found
-
getIntermediatePathSource
default SqmPathSource<?> getIntermediatePathSource(SqmPathSource<?> pathSource)
Returns the intermediateSqmPathSource
for a path source previously acquired viafindSubPathSource(String)
.
-
createSqmPath
SqmPath<J> createSqmPath(SqmPath<?> lhs, SqmPathSource<?> intermediatePathSource)
Create an SQM path for this source relative to the given left hand side
-
getExpressible
default SqmExpressible<J> getExpressible()
- Specified by:
getExpressible
in interfaceSqmExpressibleAccessor<J>
-
getSqmType
default DomainType<J> getSqmType()
- Specified by:
getSqmType
in interfaceSqmExpressible<J>
-
isGeneric
default boolean isGeneric()
Indicates if this path source is generically typed
-
-