|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface PkGenerator
Defines methods to support automatic primary key generation.
| Method Summary | |
|---|---|
void |
createAutoPk(DataNode node,
List<DbEntity> dbEntities)
Generates necessary database objects to provide automatic primary key support. |
List<String> |
createAutoPkStatements(List<DbEntity> dbEntities)
Returns a list of SQL strings needed to generates database objects to provide automatic primary support for the list of entities. |
void |
dropAutoPk(DataNode node,
List<DbEntity> dbEntities)
Drops any common database objects associated with automatic primary key generation process. |
List<String> |
dropAutoPkStatements(List<DbEntity> dbEntities)
Returns SQL string needed to drop database objects associated with automatic primary key generation. |
Object |
generatePk(DataNode dataNode,
DbAttribute pk)
Generates a unique and non-repeating primary key for specified PK attribute. |
void |
reset()
Resets any cached primary keys forcing generator to go to the database next time id generation is requested. |
| Method Detail |
|---|
void createAutoPk(DataNode node,
List<DbEntity> dbEntities)
throws Exception
node - node that provides access to a DataSource.dbEntities - a list of entities that require primary key auto-generation
support
ExceptionList<String> createAutoPkStatements(List<DbEntity> dbEntities)
void dropAutoPk(DataNode node,
List<DbEntity> dbEntities)
throws Exception
node - node that provides access to a DataSource.dbEntities - a list of entities whose primary key auto-generation support
should be dropped.
ExceptionList<String> dropAutoPkStatements(List<DbEntity> dbEntities)
Object generatePk(DataNode dataNode,
DbAttribute pk)
throws Exception
Exceptionvoid reset()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||