public class Oracle8Builder extends SqlBuilder
_log, SIZE_PLACEHOLDER| Constructor and Description |
|---|
Oracle8Builder(Platform platform)
Creates a new builder instance.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
createAutoIncrementSequence(Table table,
Column column)
Creates the sequence necessary for the auto-increment of the given column.
|
protected void |
createAutoIncrementTrigger(Table table,
Column column)
Creates the trigger necessary for the auto-increment of the given column.
|
void |
createTable(Database database,
Table table,
Map parameters)
Outputs the DDL to create the table along with any non-external constraints as well
as with external primary keys and indices (but not foreign keys).
|
protected void |
createTemporaryTable(Database database,
Table table,
Map parameters)
Outputs the DDL to create the given temporary table.
|
protected void |
dropAutoIncrementSequence(Table table,
Column column)
Drops the sequence used for the auto-increment of the given column.
|
protected void |
dropAutoIncrementTrigger(Table table,
Column column)
Drops the trigger used for the auto-increment of the given column.
|
void |
dropExternalForeignKeys(Table table)
Creates external foreignkey drop statements.
|
void |
dropTable(Table table)
Outputs the DDL to drop the table.
|
protected void |
dropTemporaryTable(Database database,
Table table)
Outputs the DDL to drop the given temporary table.
|
protected String |
getNativeDefaultValue(Column column)
Returns the native default value for the column.
|
String |
getSelectLastIdentityValues(Table table)
Generates the SQL for querying the id that was created in the last insertion
operation.
|
protected void |
printDefaultValue(Object defaultValue,
int typeCode)
Prints the default value of the column.
|
protected void |
processChange(Database currentModel,
Database desiredModel,
AddColumnChange change)
Processes the addition of a column to a table.
|
protected void |
processChange(Database currentModel,
Database desiredModel,
RemoveColumnChange change)
Processes the removal of a column from a table.
|
protected void |
processChange(Database currentModel,
Database desiredModel,
RemovePrimaryKeyChange change)
Processes the removal of a primary key from a table.
|
protected void |
processTableStructureChanges(Database currentModel,
Database desiredModel,
Table sourceTable,
Table targetTable,
Map parameters,
List changes)
Allows database-specific implementations to handle changes in a database
specific manner.
|
protected void |
writeColumnAutoIncrementStmt(Table table,
Column column)
Prints that the column is an auto increment column.
|
void |
writeExternalIndexDropStmt(Table table,
Index index)
Generates the statement to drop a non-embedded index from the database.
|
addEscapedCharSequence, alterDatabase, applyForSelectedChanges, areEqual, columnsDiffer, createExternalForeignKeys, createExternalForeignKeys, createTable, createTables, createTables, createTables, createUniqueIdentifier, dropTable, dropTables, escapeStringValue, findCorrespondingForeignKey, getBareNativeType, getColumnName, getConstraintName, getDefaultValueHelper, getDeleteSql, getDelimitedIdentifier, getForeignKeyName, getIndent, getIndexName, getInsertSql, getMaxColumnNameLength, getMaxConstraintNameLength, getMaxForeignKeyNameLength, getMaxTableNameLength, getNativeType, getPlatform, getPlatformInfo, getRealTargetTableFor, getSqlType, getTableName, getTemporaryTableFor, getUpdateSql, getValueAsString, getValueDateFormat, getValueLocale, getValueNumberFormat, getValueTimeFormat, getWriter, isValidDefaultValue, print, printComment, printEndOfStatement, printIdentifier, printIndent, println, println, printlnIdentifier, printStartOfEmbeddedStatement, processChange, processChange, processChange, processChange, processChange, processChange, processChange, processChange, processChanges, processTableStructureChanges, processTableStructureChanges, setIndent, setValueDateFormat, setValueLocale, setValueNumberFormat, setValueTimeFormat, setWriter, shortenName, shouldGeneratePrimaryKeys, writeCastExpression, writeColumn, writeColumnDefaultValue, writeColumnDefaultValueStmt, writeColumnNotNullableStmt, writeColumnNullableStmt, writeColumns, writeCopyDataStatement, writeEmbeddedForeignKeysStmt, writeEmbeddedIndexCreateStmt, writeEmbeddedIndicesStmt, writeEmbeddedPrimaryKeysStmt, writeExternalForeignKeyCreateStmt, writeExternalForeignKeyDropStmt, writeExternalIndexCreateStmt, writeExternalIndicesCreateStmt, writeExternalPrimaryKeysCreateStmt, writeForeignReferences, writeLocalReferences, writePrimaryKeyStmt, writeTableAlterStmt, writeTableComment, writeTableCreationStmt, writeTableCreationStmtEndingpublic Oracle8Builder(Platform platform)
platform - The plaftform this builder belongs topublic void createTable(Database database, Table table, Map parameters) throws IOException
createTable in class SqlBuilderdatabase - The database modeltable - The tableparameters - Additional platform-specific parameters for the table creationIOExceptionpublic void dropTable(Table table) throws IOException
SqlBuilder.dropTable(Database, Table)
if you want that.dropTable in class SqlBuildertable - The table to dropIOExceptionprotected void createAutoIncrementSequence(Table table, Column column) throws IOException
table - The tablecolumn - The columnIOExceptionprotected void createAutoIncrementTrigger(Table table, Column column) throws IOException
table - The tablecolumn - The columnIOExceptionprotected void dropAutoIncrementSequence(Table table, Column column) throws IOException
table - The tablecolumn - The columnIOExceptionprotected void dropAutoIncrementTrigger(Table table, Column column) throws IOException
table - The tablecolumn - The columnIOExceptionprotected void createTemporaryTable(Database database, Table table, Map parameters) throws IOException
SqlBuilder.createTable(Database, Table, Map).createTemporaryTable in class SqlBuilderdatabase - The database modeltable - The tableparameters - Additional platform-specific parameters for the table creationIOExceptionprotected void dropTemporaryTable(Database database, Table table) throws IOException
SqlBuilder.dropTable(Table).dropTemporaryTable in class SqlBuilderdatabase - The database modeltable - The tableIOExceptionpublic void dropExternalForeignKeys(Table table) throws IOException
dropExternalForeignKeys in class SqlBuildertable - The tableIOExceptionpublic void writeExternalIndexDropStmt(Table table, Index index) throws IOException
writeExternalIndexDropStmt in class SqlBuildertable - The table the index is onindex - The index to dropIOExceptionprotected void printDefaultValue(Object defaultValue, int typeCode) throws IOException
printDefaultValue in class SqlBuilderdefaultValue - The default valuetypeCode - The type code to write the default value forIOExceptionprotected String getNativeDefaultValue(Column column)
getNativeDefaultValue in class SqlBuildercolumn - The columnprotected void writeColumnAutoIncrementStmt(Table table, Column column) throws IOException
writeColumnAutoIncrementStmt in class SqlBuildertable - The tablecolumn - The columnIOExceptionpublic String getSelectLastIdentityValues(Table table)
null.getSelectLastIdentityValues in class SqlBuildertable - The tablenull if the database does not support thisprotected void processTableStructureChanges(Database currentModel, Database desiredModel, Table sourceTable, Table targetTable, Map parameters, List changes) throws IOException
AddPrimaryKeyChange changes are
applied via an ALTER TABLE ADD CONSTRAINT statement.processTableStructureChanges in class SqlBuildercurrentModel - The current database schemadesiredModel - The desired database schemasourceTable - The original tabletargetTable - The desired tableparameters - The creation parameters for the tablechanges - The change objects for the target tableIOExceptionprotected void processChange(Database currentModel, Database desiredModel, AddColumnChange change) throws IOException
currentModel - The current database schemadesiredModel - The desired database schemachange - The change objectIOExceptionprotected void processChange(Database currentModel, Database desiredModel, RemoveColumnChange change) throws IOException
currentModel - The current database schemadesiredModel - The desired database schemachange - The change objectIOExceptionprotected void processChange(Database currentModel, Database desiredModel, RemovePrimaryKeyChange change) throws IOException
currentModel - The current database schemadesiredModel - The desired database schemachange - The change objectIOExceptionCopyright © 2005-2013 Apache Software Foundation. All Rights Reserved.