public interface

PersistentIdentifierGenerator

implements IdentifierGenerator
org.hibernate.id.PersistentIdentifierGenerator
Known Indirect Subclasses

Class Overview

An IdentifierGenerator that requires creation of database objects.

All PersistentIdentifierGenerators that also implement Configurable have access to a special mapping parameter: schema

Summary

Constants
String CATALOG The configuration parameter holding the catalog name
String IDENTIFIER_NORMALIZER The key under whcih to find the ObjectNameNormalizer in the config param map.
String PK The configuration parameter holding the primary key column name of the generated id
String SCHEMA The configuration parameter holding the schema name
String TABLE The configuration parameter holding the table name for the generated id
String TABLES The configuration parameter holding the table names for all tables for which the id must be unique
[Expand]
Inherited Constants
From interface org.hibernate.id.IdentifierGenerator
Fields
public static final SQLStatementLogger SQL_STATEMENT_LOGGER
Public Methods
abstract Object generatorKey()
Return a key unique to the underlying database objects.
abstract String[] sqlCreateStrings(Dialect dialect)
The SQL required to create the underlying database objects.
abstract String[] sqlDropStrings(Dialect dialect)
The SQL required to remove the underlying database objects.
[Expand]
Inherited Methods
From interface org.hibernate.id.IdentifierGenerator

Constants

public static final String CATALOG

The configuration parameter holding the catalog name

Constant Value: "catalog"

public static final String IDENTIFIER_NORMALIZER

The key under whcih to find the ObjectNameNormalizer in the config param map.

Constant Value: "identifier_normalizer"

public static final String PK

The configuration parameter holding the primary key column name of the generated id

Constant Value: "target_column"

public static final String SCHEMA

The configuration parameter holding the schema name

Constant Value: "schema"

public static final String TABLE

The configuration parameter holding the table name for the generated id

Constant Value: "target_table"

public static final String TABLES

The configuration parameter holding the table names for all tables for which the id must be unique

Constant Value: "identity_tables"

Fields

public static final SQLStatementLogger SQL_STATEMENT_LOGGER

Public Methods

public abstract Object generatorKey ()

Return a key unique to the underlying database objects. Prevents us from trying to create/remove them multiple times.

Returns
  • Object an identifying key for this generator

public abstract String[] sqlCreateStrings (Dialect dialect)

The SQL required to create the underlying database objects.

Parameters
dialect The dialect against which to generate the create command(s)
Returns
  • The create command(s)
Throws
HibernateException problem creating the create command(s)

public abstract String[] sqlDropStrings (Dialect dialect)

The SQL required to remove the underlying database objects.

Parameters
dialect The dialect against which to generate the drop command(s)
Returns
  • The drop command(s)
Throws
HibernateException problem creating the drop command(s)