Top Description Methods
org.hibernate.sql.ast.spi

public Interface FromClauseAccess

Known Direct Subinterfaces
org.hibernate.query.sqm.sql.SqmTranslator
Known Direct Implementers
org.hibernate.sql.ast.spi.SimpleFromClauseAccessImpl, org.hibernate.query.results.FromClauseAccessImpl
Imports
java.util.function.Function, org.hibernate.spi.NavigablePath, org.hibernate.sql.ast.SqlTreeCreationException, org.hibernate.sql.ast.tree.from.TableGroup

Access to TableGroup indexing. The indexing is defined in terms of NavigablePath
Author
Steve Ebersole

Method Summary

Modifier and TypeMethod and Description
public TableGroup
findTableGroup(NavigablePath navigablePath)

Find a TableGroup by the NavigablePath it is registered under, and if not found on the current from clause level, ask the parent.

public default TableGroup
findTableGroupForGetOrCreate(NavigablePath navigablePath)

Find the TableGroup by the NavigablePath for the purpose of creating a new TableGroup if none can be found.

public TableGroup
findTableGroupOnCurrentFromClause(NavigablePath navigablePath)

Find a TableGroup in this from clause without consulting parents by the NavigablePath it is registered under.

public default TableGroup
getTableGroup(NavigablePath navigablePath)

Get a TableGroup by the NavigablePath it is registered under.

public void
registerTableGroup(NavigablePath navigablePath, TableGroup tableGroup)

Register a TableGroup under the given `navigablePath`.

public default TableGroup
resolveTableGroup(NavigablePath navigablePath, Function<NavigablePath, TableGroup> creator)

Finds the TableGroup associated with the given `navigablePath`.

Method Detail

findTableGroupback to summary
public TableGroup findTableGroup(NavigablePath navigablePath)

Find a TableGroup by the NavigablePath it is registered under, and if not found on the current from clause level, ask the parent. Returns null if no TableGroup is registered under that NavigablePath

findTableGroupForGetOrCreateback to summary
public default TableGroup findTableGroupForGetOrCreate(NavigablePath navigablePath)

Find the TableGroup by the NavigablePath for the purpose of creating a new TableGroup if none can be found. Returns null if no TableGroup or parent table group is registered under that NavigablePath

findTableGroupOnCurrentFromClauseback to summary
public TableGroup findTableGroupOnCurrentFromClause(NavigablePath navigablePath)

Find a TableGroup in this from clause without consulting parents by the NavigablePath it is registered under. Returns null if no TableGroup is registered under that NavigablePath

getTableGroupback to summary
public default TableGroup getTableGroup(NavigablePath navigablePath) throws SqlTreeCreationException

Get a TableGroup by the NavigablePath it is registered under. If there is no registration, an exception is thrown.

registerTableGroupback to summary
public void registerTableGroup(NavigablePath navigablePath, TableGroup tableGroup)

Register a TableGroup under the given `navigablePath`. Logs a message if this registration over-writes an existing one.

resolveTableGroupback to summary
public default TableGroup resolveTableGroup(NavigablePath navigablePath, Function<NavigablePath, TableGroup> creator)

Finds the TableGroup associated with the given `navigablePath`. If one is not found, it is created via the given `creator`, registered under `navigablePath` and returned.

API Note

If the `creator` is called, there is no need for it to register the TableGroup it creates. It will be registered by this method after.

See Also
findTableGroup, registerTableGroup