Top Fields Constructors Methods
org.hibernate.query.sqm.tree.domain

public Class SqmTreatedSimplePath<T, S extends T>

extends SqmEntityValuedSimplePath<S extends T>
implements SqmSimplePath<S extends T>, SqmTreatedPath<T, S extends T>
Class Inheritance
All Implemented Interfaces
org.hibernate.query.sqm.tree.domain.SqmTreatedPath, org.hibernate.query.sqm.tree.domain.SqmPathWrapper, org.hibernate.query.sqm.tree.domain.SqmPath, org.hibernate.query.criteria.JpaPath, jakarta.persistence.criteria.Path, jakarta.persistence.criteria.Expression, jakarta.persistence.criteria.Selection, jakarta.persistence.TupleElement, org.hibernate.query.criteria.JpaExpression, org.hibernate.query.criteria.JpaSelection, org.hibernate.query.criteria.JpaTupleElement, org.hibernate.query.criteria.JpaCriteriaNode, java.io.Serializable, org.hibernate.query.hql.spi.SemanticPathPart, org.hibernate.query.sqm.tree.expression.SqmExpression, org.hibernate.query.sqm.tree.select.SqmSelectableNode, org.hibernate.query.sqm.tree.SqmTypedNode, org.hibernate.query.sqm.tree.SqmVisitableNode, org.hibernate.query.sqm.tree.SqmNode, org.hibernate.query.sqm.tree.SqmExpressibleAccessor, org.hibernate.query.sqm.tree.domain.SqmSimplePath
Imports
org.hibernate.metamodel.model.domain.EntityDomainType, org.hibernate.query.PathException, org.hibernate.query.sqm.NodeBuilder, .SemanticQueryWalker, .SqmPathSource, org.hibernate.query.sqm.tree.SqmCopyContext, org.hibernate.spi.NavigablePath

Author
Steve Ebersole

Field Summary

Modifier and TypeField and Description
private final EntityDomainType<S>
private final SqmPath<T>

Constructor Summary

AccessConstructor and Description
public
SqmTreatedSimplePath(SqmPluralValuedSimplePath<T> wrappedPath, EntityDomainType<S> treatTarget, NodeBuilder nodeBuilder)

public
SqmTreatedSimplePath(SqmPath<T> wrappedPath, EntityDomainType<S> treatTarget, NodeBuilder nodeBuilder)

private
SqmTreatedSimplePath(NavigablePath navigablePath, SqmPath<T> wrappedPath, EntityDomainType<S> treatTarget, NodeBuilder nodeBuilder)

Method Summary

Modifier and TypeMethod and Description
public <X> X
public void
public SqmTreatedSimplePath<T, S>
public SqmPath<?>
get(String
name of the attribute
attributeName
)

Overrides org.hibernate.query.sqm.tree.domain.AbstractSqmPath.get.

Implements org.hibernate.query.sqm.tree.domain.SqmPath.get.

Create a path corresponding to the referenced attribute.
public EntityDomainType<S>
public SqmPathSource<S>
public SqmPathSource<?>
getResolvedModel()

Overrides org.hibernate.query.sqm.tree.domain.AbstractSqmPath.getResolvedModel.

Implements org.hibernate.query.sqm.tree.domain.SqmPath.getResolvedModel.

Get this path's actual resolved model, i.e. the concrete type for generic attributes.
public EntityDomainType<S>
public SqmPath<T>
public <S1 extends S> SqmTreatedSimplePath<S, S1>
treatAs(Class<S1> treatJavaType)

Overrides org.hibernate.query.sqm.tree.domain.SqmEntityValuedSimplePath.treatAs.

Implements org.hibernate.query.sqm.tree.domain.SqmPath.treatAs.

Support for JPA's explicit (TREAT) down-casting.
Inherited from org.hibernate.query.sqm.tree.domain.SqmEntityValuedSimplePath:
resolvePathParttreatAs

Field Detail

treatTargetback to summary
private final EntityDomainType<S> treatTarget
wrappedPathback to summary
private final SqmPath<T> wrappedPath

Constructor Detail

SqmTreatedSimplePathback to summary
public SqmTreatedSimplePath(SqmPluralValuedSimplePath<T> wrappedPath, EntityDomainType<S> treatTarget, NodeBuilder nodeBuilder)
SqmTreatedSimplePathback to summary
public SqmTreatedSimplePath(SqmPath<T> wrappedPath, EntityDomainType<S> treatTarget, NodeBuilder nodeBuilder)
SqmTreatedSimplePathback to summary
private SqmTreatedSimplePath(NavigablePath navigablePath, SqmPath<T> wrappedPath, EntityDomainType<S> treatTarget, NodeBuilder nodeBuilder)

Method Detail

acceptback to summary
public <X> X accept(SemanticQueryWalker<X> walker)

Overrides org.hibernate.query.sqm.tree.domain.SqmEntityValuedSimplePath.accept.

Implements org.hibernate.query.sqm.tree.SqmVisitableNode.accept.

Doc from org.hibernate.query.sqm.tree.SqmVisitableNode.accept.

Accept the walker per visitation

Annotations
@Override
appendHqlStringback to summary
public void appendHqlString(StringBuilder sb)

Overrides org.hibernate.query.sqm.tree.domain.AbstractSqmSimplePath.appendHqlString.

Implements org.hibernate.query.sqm.tree.SqmVisitableNode.appendHqlString.

Annotations
@Override
copyback to summary
public SqmTreatedSimplePath<T, S> copy(SqmCopyContext context)

Overrides org.hibernate.query.sqm.tree.domain.SqmEntityValuedSimplePath.copy.

Implements org.hibernate.query.sqm.tree.domain.SqmPath.copy, org.hibernate.query.sqm.tree.expression.SqmExpression.copy, org.hibernate.query.sqm.tree.select.SqmSelectableNode.copy, org.hibernate.query.sqm.tree.SqmNode.copy.

Annotations
@Override
getback to summary
public SqmPath<?> get(String attributeName)

Overrides org.hibernate.query.sqm.tree.domain.AbstractSqmPath.get.

Implements org.hibernate.query.sqm.tree.domain.SqmPath.get.

Doc from jakarta.persistence.criteria.Path.get.

Create a path corresponding to the referenced attribute.

Note

Applications using the string-based API may need to specify the type resulting from the get operation in order to avoid the use of Path variables.

   For example:

   CriteriaQuery<Person> q = cb.createQuery(Person.class);
   Root<Person> p = q.from(Person.class);
   q.select(p)
    .where(cb.isMember("joe",
                       p.<Set<String>>get("nicknames")));

   rather than:

   CriteriaQuery<Person> q = cb.createQuery(Person.class);
   Root<Person> p = q.from(Person.class);
   Path<Set<String>> nicknames = p.get("nicknames");
   q.select(p)
    .where(cb.isMember("joe", nicknames));
Parameters
attributeName:String

name of the attribute

Returns:SqmPath<?>

path corresponding to the referenced attribute

Annotations
@Override
@SuppressWarnings:unchecked
getNodeTypeback to summary
public EntityDomainType<S> getNodeType()

Overrides org.hibernate.query.sqm.tree.domain.SqmEntityValuedSimplePath.getNodeType.

Implements org.hibernate.query.sqm.tree.domain.SqmPath.getNodeType, org.hibernate.query.sqm.tree.expression.SqmExpression.getNodeType, org.hibernate.query.sqm.tree.SqmTypedNode.getNodeType.

Doc from org.hibernate.query.sqm.tree.domain.SqmPath.getNodeType.

This node's type is its "referenced path source"

Annotations
@Override
getReferencedPathSourceback to summary
public SqmPathSource<S> getReferencedPathSource()

Overrides org.hibernate.query.sqm.tree.domain.AbstractSqmSimplePath.getReferencedPathSource.

Implements org.hibernate.query.sqm.tree.domain.SqmPath.getReferencedPathSource.

Doc from org.hibernate.query.sqm.tree.domain.SqmPath.getReferencedPathSource.

The path source that this path refers to (and that most likely created it).

Annotations
@Override
getResolvedModelback to summary
public SqmPathSource<?> getResolvedModel()

Overrides org.hibernate.query.sqm.tree.domain.AbstractSqmPath.getResolvedModel.

Implements org.hibernate.query.sqm.tree.domain.SqmPath.getResolvedModel.

Doc from org.hibernate.query.sqm.tree.domain.SqmPath.getResolvedModel.

Get this path's actual resolved model, i.e. the concrete type for generic attributes.

Annotations
@Override
getTreatTargetback to summary
public EntityDomainType<S> getTreatTarget()

Implements org.hibernate.query.sqm.tree.domain.SqmTreatedPath.getTreatTarget.

Annotations
@Override
getWrappedPathback to summary
public SqmPath<T> getWrappedPath()

Implements org.hibernate.query.sqm.tree.domain.SqmTreatedPath.getWrappedPath.

Doc from org.hibernate.query.sqm.tree.domain.SqmPathWrapper.getWrappedPath.

Access the wrapped SqmPath.

Annotations
@Override
treatAsback to summary
public <S1 extends S> SqmTreatedSimplePath<S, S1> treatAs(Class<S1> treatJavaType) throws PathException

Overrides org.hibernate.query.sqm.tree.domain.SqmEntityValuedSimplePath.treatAs.

Implements org.hibernate.query.sqm.tree.domain.SqmPath.treatAs.

Doc from org.hibernate.query.criteria.JpaPath.treatAs.

Support for JPA's explicit (TREAT) down-casting.

Annotations
@Override