public class TableKeyGeneratorFactory extends Object implements KeyGeneratorFactory
TableKeyGenerator
Modifier and Type | Field and Description |
---|---|
static String |
NAME
Short name of this key generator factory.
|
Constructor and Description |
---|
TableKeyGeneratorFactory() |
Modifier and Type | Method and Description |
---|---|
KeyGenerator |
getKeyGenerator(PersistenceFactory factory,
Properties params,
int sqlType)
Produce the key generator.
|
String |
getKeyGeneratorName()
Get the short name of the key generator.
|
public static String NAME
public String getKeyGeneratorName()
KeyGeneratorFactory
getKeyGeneratorName
in interface KeyGeneratorFactory
KeyGenerator
used to identify key generator (types).public KeyGenerator getKeyGenerator(PersistenceFactory factory, Properties params, int sqlType) throws MappingException
KeyGeneratorFactory
getKeyGenerator
in interface KeyGeneratorFactory
factory
- Helper object for obtaining database-specific QuerySyntax.params
- Parameters for key generator.sqlType
- The SQL type of the primary key, the generated identities must have
the corresponding Java type, e.g. java.sql.Types.INTEGER corresponds to
java.lang.Integer, java.sql.Types.NUMERIC corresponds to java.lang.BigDecimal.KeyGenerator
instance.MappingException
- If there's a problem resolving the mapping information.Copyright © 2016. All rights reserved.