SequenceStyleGenerator instead@Deprecated public class SequenceGenerator extends Object implements PersistentIdentifierGenerator, BulkInsertionCapableIdentifierGenerator
SequenceHiLoGenerator| Modifier and Type | Field and Description |
|---|---|
static String |
PARAMETERS
Deprecated.
No longer supported. To specify initial-value or increment use the
org.hibernate.id.enhanced.SequenceStyleGenerator generator instead.
|
static String |
SEQUENCE
Deprecated.
The sequence parameter
|
CATALOG, IDENTIFIER_NORMALIZER, PK, SCHEMA, TABLE, TABLESENTITY_NAME, GENERATOR_NAME, JPA_ENTITY_NAME| Constructor and Description |
|---|
SequenceGenerator()
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
protected IntegralDataTypeHolder |
buildHolder()
Deprecated.
|
void |
configure(Type type,
Properties params,
ServiceRegistry serviceRegistry)
Deprecated.
Configure this instance, given the value of parameters
specified by the user as <param> elements.
|
String |
determineBulkInsertionIdentifierGenerationSelectFragment(SqlStringGenerationContext context)
Deprecated.
Return the select expression fragment, if any, that generates the identifier values.
|
Serializable |
generate(SharedSessionContractImplementor session,
Object obj)
Deprecated.
Generate a new identifier.
|
protected IntegralDataTypeHolder |
generateHolder(SharedSessionContractImplementor session)
Deprecated.
|
String[] |
getAllSqlForTests()
Deprecated.
Exposed for tests only.
|
protected Type |
getIdentifierType()
Deprecated.
|
QualifiedName |
getPhysicalSequenceName()
Deprecated.
|
void |
initialize(SqlStringGenerationContext context)
Deprecated.
Initializes this instance, in particular pre-generates SQL as necessary.
|
void |
registerExportables(Database database)
Deprecated.
Register database objects used by this identifier generator, e.g.
|
boolean |
supportsBulkInsertionIdentifierGeneration()
Deprecated.
Given the configuration of this generator, is identifier generation as part of bulk insertion supported?
IMPL NOTE : Mainly here to allow stuff like SequenceStyleGenerator which *can* support this based on
configuration
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitsupportsJdbcBatchInsertspublic static final String SEQUENCE
@Deprecated public static final String PARAMETERS
protected Type getIdentifierType()
public QualifiedName getPhysicalSequenceName()
@Deprecated public String[] getAllSqlForTests()
public void configure(Type type, Properties params, ServiceRegistry serviceRegistry) throws MappingException
IdentifierGenerator
This method is called just once, following instantiation, and before IdentifierGenerator.registerExportables(Database).
configure in interface Configurableconfigure in interface IdentifierGeneratortype - The id property type descriptorparams - param values, keyed by parameter nameserviceRegistry - Access to service that may be needed.MappingException - If configuration fails.public Serializable generate(SharedSessionContractImplementor session, Object obj)
IdentifierGeneratorgenerate in interface IdentifierGeneratorsession - The session from which the request originatesobj - the entity or collection (idbag) for which the id is being generatedprotected IntegralDataTypeHolder generateHolder(SharedSessionContractImplementor session)
protected IntegralDataTypeHolder buildHolder()
public boolean supportsBulkInsertionIdentifierGeneration()
BulkInsertionCapableIdentifierGeneratorsupportsBulkInsertionIdentifierGeneration in interface BulkInsertionCapableIdentifierGeneratortrue if bulk insertions are supported; false otherwise.public String determineBulkInsertionIdentifierGenerationSelectFragment(SqlStringGenerationContext context)
BulkInsertionCapableIdentifierGeneratordetermineBulkInsertionIdentifierGenerationSelectFragment in interface BulkInsertionCapableIdentifierGeneratornull indicates that no fragment is needed.public void registerExportables(Database database)
IdentifierGenerator
This method is called just once, after IdentifierGenerator.configure(Type, Properties, ServiceRegistry).
registerExportables in interface ExportableProducerregisterExportables in interface IdentifierGeneratordatabase - The database instancepublic void initialize(SqlStringGenerationContext context)
IdentifierGenerator
This method is called after IdentifierGenerator.registerExportables(Database), before first use.
initialize in interface IdentifierGeneratorcontext - A context to help generate SQL stringsCopyright © 2001-2021 Red Hat, Inc. All Rights Reserved.