public interface

Queryable

implements Joinable Loadable PropertyMapping
org.hibernate.persister.entity.Queryable
Known Indirect Subclasses

Class Overview

Extends the generic EntityPersister contract to add operations required by the Hibernate Query Language

Summary

Nested Classes
class Queryable.Declarer  
[Expand]
Inherited Constants
From interface org.hibernate.persister.entity.EntityPersister
From interface org.hibernate.persister.entity.Loadable
Public Methods
abstract String generateFilterConditionAlias(String rootAlias)
The alias used for any filter conditions (mapped where-fragments or enabled-filters).
abstract String[] getConstraintOrderedTableNameClosure()
Get the names of all tables used in the hierarchy (up and down) ordered such that deletes in the given order would not cause contraint violations.
abstract String[][] getContraintOrderedTableKeyColumnClosure()
For each table specified in getConstraintOrderedTableNameClosure(), get the columns that define the key between the various hierarchy classes.
abstract String getDiscriminatorSQLValue()
Get the discriminator value for this particular concrete subclass, as a string that may be embedded in a select statement
abstract String[] getIdentifierColumnNames()
Get the names of columns used to persist the identifier
abstract String getMappedSuperclass()
Get the class that this class is mapped as a subclass of - not necessarily the direct superclass
abstract Queryable.Declarer getSubclassPropertyDeclarer(String propertyPath)
Determine whether the given property is declared by our mapped class, our super class, or one of our subclasses...
abstract int getSubclassPropertyTableNumber(String propertyPath)
Given a property name, determine the number of the table which contains the column to which this property is mapped.
abstract String getSubclassTableName(int number)
Get the name of the table with the given index from the internal array.
abstract String getTemporaryIdTableDDL()
Get the appropriate DDL command for generating the temporary table to be used to (potentially) store id values when performing bulk update/deletes.
abstract String getTemporaryIdTableName()
Get the name of the temporary table to be used to (potentially) store id values when performing bulk update/deletes.
abstract DiscriminatorMetadata getTypeDiscriminatorMetadata()
Retrieve the information needed to properly deal with this entity's discriminator in a query.
abstract String identifierSelectFragment(String name, String suffix)
Given a query alias and an identifying suffix, render the intentifier select fragment.
abstract boolean isAbstract()
Is this an abstract class?
abstract boolean isExplicitPolymorphism()
Is this class explicit polymorphism only?
abstract boolean isMultiTable()
Is the inheritence hierarchy described by this persister contained across multiple tables?
abstract boolean isVersionPropertyInsertable()
Is the version property included in insert statements?
abstract String propertySelectFragment(String alias, String suffix, boolean allProperties)
Given a query alias and an identifying suffix, render the property select fragment.
abstract SelectFragment propertySelectFragmentFragment(String alias, String suffix, boolean allProperties)
[Expand]
Inherited Methods
From interface org.hibernate.cache.OptimisticCacheSource
From interface org.hibernate.persister.entity.EntityPersister
From interface org.hibernate.persister.entity.Joinable
From interface org.hibernate.persister.entity.Loadable
From interface org.hibernate.persister.entity.PropertyMapping

Public Methods

public abstract String generateFilterConditionAlias (String rootAlias)

The alias used for any filter conditions (mapped where-fragments or enabled-filters).

This may or may not be different from the root alias depending upon the inheritence mapping strategy.

Parameters
rootAlias The root alias
Returns
  • The alias used for "filter conditions" within the where clause.

public abstract String[] getConstraintOrderedTableNameClosure ()

Get the names of all tables used in the hierarchy (up and down) ordered such that deletes in the given order would not cause contraint violations.

Returns
  • The ordered array of table names.

public abstract String[][] getContraintOrderedTableKeyColumnClosure ()

For each table specified in getConstraintOrderedTableNameClosure(), get the columns that define the key between the various hierarchy classes.

The first dimension here corresponds to the table indexes returned in getConstraintOrderedTableNameClosure().

The second dimension should have the same length across all the elements in the first dimension. If not, that'd be a problem ;)

public abstract String getDiscriminatorSQLValue ()

Get the discriminator value for this particular concrete subclass, as a string that may be embedded in a select statement

public abstract String[] getIdentifierColumnNames ()

Get the names of columns used to persist the identifier

public abstract String getMappedSuperclass ()

Get the class that this class is mapped as a subclass of - not necessarily the direct superclass

public abstract Queryable.Declarer getSubclassPropertyDeclarer (String propertyPath)

Determine whether the given property is declared by our mapped class, our super class, or one of our subclasses...

Note: the method is called 'subclass property...' simply for consistency sake (e.g. getSubclassPropertyTableNumber(String)

Parameters
propertyPath The property name.
Returns
  • The property declarer

public abstract int getSubclassPropertyTableNumber (String propertyPath)

Given a property name, determine the number of the table which contains the column to which this property is mapped.

Note that this is not relative to the results from getConstraintOrderedTableNameClosure(). It is relative to the subclass table name closure maintained internal to the persister (yick!). It is also relative to the indexing used to resolve getSubclassTableName(int)...

Parameters
propertyPath The name of the property.
Returns
  • The nunber of the table to which the property is mapped.

public abstract String getSubclassTableName (int number)

Get the name of the table with the given index from the internal array.

Parameters
number The index into the internal array.

public abstract String getTemporaryIdTableDDL ()

Get the appropriate DDL command for generating the temporary table to be used to (potentially) store id values when performing bulk update/deletes.

Returns
  • The appropriate temporary table creation command.

public abstract String getTemporaryIdTableName ()

Get the name of the temporary table to be used to (potentially) store id values when performing bulk update/deletes.

Returns
  • The appropriate temporary table name.

public abstract DiscriminatorMetadata getTypeDiscriminatorMetadata ()

Retrieve the information needed to properly deal with this entity's discriminator in a query.

Returns
  • The entity discriminator metadata

public abstract String identifierSelectFragment (String name, String suffix)

Given a query alias and an identifying suffix, render the intentifier select fragment.

public abstract boolean isAbstract ()

Is this an abstract class?

public abstract boolean isExplicitPolymorphism ()

Is this class explicit polymorphism only?

public abstract boolean isMultiTable ()

Is the inheritence hierarchy described by this persister contained across multiple tables?

Returns
  • True if the inheritence hierarchy is spread across multiple tables; false otherwise.

public abstract boolean isVersionPropertyInsertable ()

Is the version property included in insert statements?

public abstract String propertySelectFragment (String alias, String suffix, boolean allProperties)

Given a query alias and an identifying suffix, render the property select fragment.

public abstract SelectFragment propertySelectFragmentFragment (String alias, String suffix, boolean allProperties)