public class MckoiBuilder extends SqlBuilder
_log, LINE_SEPARATOR, SIZE_PLACEHOLDER| Constructor and Description |
|---|
MckoiBuilder(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.
|
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 |
dropAutoIncrementSequence(Table table,
Column column)
Drops the sequence used for the auto-increment of the given column.
|
void |
dropTable(Table table)
Outputs the DDL to drop the table.
|
String |
getSelectLastIdentityValues(Table table)
Generates the SQL for querying the id that was created in the last insertion
operation.
|
protected void |
writeColumnDefaultValue(Table table,
Column column)
Prints the default value of the column.
|
protected void |
writeRecreateTableStmt(Database model,
Table table,
Map parameters)
Writes the SQL to recreate a table.
|
addColumn, addEscapedCharSequence, areEqual, columnsDiffer, copyData, createForeignKey, createForeignKeys, createForeignKeys, createIndex, createIndexes, createPrimaryKey, createTable, createTables, createTables, createTables, createTemporaryTable, createUniqueIdentifier, dropForeignKey, dropForeignKeys, dropIndex, dropTable, dropTables, dropTemporaryTable, escapeStringValue, getBareNativeType, getColumnName, getConstraintName, getDefaultValueHelper, getDeleteSql, getDelimitedIdentifier, getForeignKeyName, getIndent, getIndexName, getInsertSql, getMaxColumnNameLength, getMaxConstraintNameLength, getMaxForeignKeyNameLength, getMaxTableNameLength, getNativeDefaultValue, getNativeType, getPlatform, getPlatformInfo, getSizeSpec, getSqlType, getSqlType, getTableName, getUpdateSql, getUpdateSql, getValueAsString, getValueDateFormat, getValueLocale, getValueNumberFormat, getValueTimeFormat, getWriter, isValidDefaultValue, print, printComment, printDefaultValue, printEndOfStatement, printIdentifier, printIndent, println, println, printlnIdentifier, printStartOfEmbeddedStatement, setIndent, setValueDateFormat, setValueLocale, setValueNumberFormat, setValueTimeFormat, setWriter, shortenName, shouldGeneratePrimaryKeys, writeAddIdentityColumnUsingAlterTable, writeCastExpression, writeColumn, writeColumnAutoIncrementStmt, writeColumnDefaultValueStmt, writeColumnNotNullableStmt, writeColumnNullableStmt, writeColumns, writeEmbeddedForeignKeysStmt, writeEmbeddedIndexCreateStmt, writeEmbeddedIndicesStmt, writeEmbeddedPrimaryKeysStmt, writeForeignKeyOnDeleteAction, writeForeignKeyOnUpdateAction, writeForeignReferences, writeLocalReferences, writePrimaryKeyStmt, writeTableAlterStmt, writeTableComment, writeTableCreationStmt, writeTableCreationStmtEndingpublic MckoiBuilder(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 dropAutoIncrementSequence(Table table, Column column) throws IOException
table - The tablecolumn - The columnIOExceptionprotected void writeColumnDefaultValue(Table table, Column column) throws IOException
writeColumnDefaultValue 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 writeRecreateTableStmt(Database model, Table table, Map parameters) throws IOException
model - The database modeltable - The table to recreateparameters - The table creation parametersIOExceptionCopyright © 2010-2015 Pivotal Software, Inc. All rights reserved.