Package org.hibernate.id
Interface PersistentIdentifierGenerator
- All Superinterfaces:
IdentifierGenerator
- All Known Implementing Classes:
MultipleHiLoPerTableGenerator,SequenceGenerator,SequenceHiLoGenerator,SequenceIdentityGenerator,SequenceStyleGenerator,TableGenerator,TableGenerator,TableHiLoGenerator
An IdentifierGenerator that requires creation of database objects.
All PersistentIdentifierGenerators that also implement Configurable have access to a special mapping parameter: schema
All PersistentIdentifierGenerators that also implement Configurable have access to a special mapping parameter: schema
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe configuration parameter holding the catalog namestatic final StringThe key under whcih to find theObjectNameNormalizerin the config param map.static final StringThe configuration parameter holding the primary key column name of the generated idstatic final StringThe configuration parameter holding the schema namestatic final SQLStatementLoggerstatic final StringThe configuration parameter holding the table name for the generated idstatic final StringThe configuration parameter holding the table names for all tables for which the id must be uniqueFields inherited from interface org.hibernate.id.IdentifierGenerator
ENTITY_NAME -
Method Summary
Modifier and TypeMethodDescriptionReturn a key unique to the underlying database objects.String[]sqlCreateStrings(Dialect dialect) The SQL required to create the underlying database objects.String[]sqlDropStrings(Dialect dialect) The SQL required to remove the underlying database objects.Methods inherited from interface org.hibernate.id.IdentifierGenerator
generate
-
Field Details
-
SCHEMA
The configuration parameter holding the schema name- See Also:
-
TABLE
The configuration parameter holding the table name for the generated id- See Also:
-
TABLES
The configuration parameter holding the table names for all tables for which the id must be unique- See Also:
-
PK
The configuration parameter holding the primary key column name of the generated id- See Also:
-
CATALOG
The configuration parameter holding the catalog name- See Also:
-
IDENTIFIER_NORMALIZER
The key under whcih to find theObjectNameNormalizerin the config param map.- See Also:
-
SQL_STATEMENT_LOGGER
-
-
Method Details
-
sqlCreateStrings
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)
-
sqlDropStrings
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)
-
generatorKey
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
-