com.im.commons.db
Interface DatabasePlatformX
- All Superinterfaces:
- DatabasePlatform
- All Known Implementing Classes:
- AbstractDatabasePlatform
public interface DatabasePlatformX
- extends DatabasePlatform
DO NOT USE THIS INTERFACE OUTSIDE db_commons MODULE!!!
This is temporary interface. It's purpose is to separate methods of database platform
that are used in db_commons module from those used in client modules.
DatabasePlatform is interface used by client modules.
DatabasePlatformX is interface used by db_commons module.
This interface should be made module-private, but it was not possible, because
AspectJ part of DIF module build was failing (I will look at this more closely).
Also, this interface is used from several client unit tests, I didn't want to
add methods used in those tests to client-used DatabasePlatform interface just
because they are used in tests. Some refactoring of tests might help with this.
|
Method Summary |
String |
createIdColumnNameFromTableName(String tableName)
|
String |
getCartridgeOwner()
|
String |
getCatalog()
|
String |
getColumnListCommaSeparated(String[] columns)
|
List<String> |
getMetaTableNamesSorted()
|
NativeJdbcExtractor |
getNativeJdbcExtractor()
|
TermEncoder |
getTermEncoder()
|
String |
sqlAlterColumnDefault(SchemaQualifiedName tableName,
String columnName,
Class colClass,
String nativeType,
String columnDefinition,
String defaultValue,
boolean required)
|
String |
sqlAlterColumnDefault(String tableName,
String columnName,
String nativeType,
String columnDefinition,
String defaultValue,
boolean required)
|
String |
sqlAlterColumnName(String tableName,
String oldName,
String newName,
String definition)
|
String |
sqlAlterColumnSize(String tableName,
String columnName,
String columnDefinition)
|
String |
sqlAlterTableName(String oldName,
String newName)
|
String |
sqlCreateIJCAuthoritiesTable()
|
String[] |
sqlCreateIJCChangesLogTable()
|
String |
sqlCreateIJCGenericsTable()
|
String[] |
sqlCreateIJCInvocationLogTable()
|
String |
sqlCreateIJCItemInfoTable()
|
String |
sqlCreateIJCItemUserTable()
|
String |
sqlCreateIJCSchemaAuthoritiesTable()
|
String |
sqlCreateIJCSchemaTable()
|
String |
sqlCreateIJCSecurityAuthoritiesAuthoritiesFK()
|
String |
sqlCreateIJCSecurityInfoTable()
|
String |
sqlCreateIJCUserTable()
|
String[] |
sqlCreateIJCViewsTable()
|
String |
sqlCreateTable(String schemaPlusTable,
List<DBDatabaseInfo.NativeType> columnDefs,
List<String> columnNames)
Creates a table with the given name and the fields. |
String |
sqlCreateTable(String tableName,
String idColumnName,
String extraCols)
|
String |
sqlCreateView(String viewName,
String sql)
|
String |
sqlDropColumn(String tableName,
String columnName)
|
String |
sqlDropView(String viewName)
|
String |
sqlGenericItemDelete()
|
String |
sqlGenericItemInsert()
|
String |
sqlGenericItemUpdate()
|
String |
sqlGetDBSchemaVersion()
|
String |
sqlGetItemsByType()
|
String |
sqlQueryForIds(String tableName,
String[] idColumnNames,
int limit)
|
String |
sqlQueryForIdsWithSort(String tableName,
String[] idColumnNames,
int limit,
SortColumn[] sortCols)
|
String |
sqlRetrieveSequence(String sequenceName)
|
String |
sqlSchemaMetaDataInsert()
|
String |
sqlSchemaMetaDataNextIndex()
|
String |
sqlSelect(String tableName,
String columns,
String idColumnName)
|
String |
sqlSetDBSchemaVersion(boolean insert)
|
String |
sqlSort(List ids,
SortColumn[] sortCols,
SchemaQualifiedName tableName,
String selectCol,
DBDatabaseInfo.ColumnSQLType selectColType)
|
String |
sqlViewMetaDataInsert()
|
String |
sqlViewMetaDataNextIndex()
|
| Methods inherited from interface com.im.commons.db.DatabasePlatform |
buildColumnInfoForColumn, buildColumnInfosForTable, buildConstraintInfosForTable, buildExportedForeignKeyInfoForTable, buildImportedForeignKeyInfoForTable, buildIndexInfoForTable, buildJChemPropertyTableNames, buildSequenceInfo, buildSequenceInfo, buildTableInfo, buildTableInfoFull, buildTableInfos, buildTableInfosEager, buildTableInfosLazy, checkSchemaExistence, executeDDL, executeDDL, getAddAuthoritySql, getAddUserSql, getDataSource, getDBInfo, getDefaultSchemaName, getDeleteAuthoritiesSql, getDeleteUserSql, getJdbcTemplate, getLobHandler, getMetaTableNames, getSchemaNames, getSetEnabledSql, getTableNames, getTransactionManager, getUpdatePasswordSql, getUsedSchemas, getViewNames, isProjectDatabase, readValue, shutdown, sqlAddColumn, sqlAddForeignKey, sqlAddIndex, sqlAddUniqueConstraint, sqlAlterColumnRequired, sqlCount, sqlCreateSecurityTables, sqlCreateSecurityTablesExternalConstraints, sqlCreateSequence, sqlDeleteRow, sqlDropForeignKey, sqlDropIndex, sqlDropPrimaryConstraint, sqlDropSequence, sqlDropTable, sqlDropUniqueConstraint, sqlFullColumnDefinition, sqlInsertRow, sqlInsertRowDefaults, sqlLastId, sqlNow, sqlRebuildIndex, sqlSelectDistinct, sqlSelectDuplicateRows, sqlSelectInList, sqlSelectPS, sqlUpdateIJCViewsTable, sqlUpdateRow, sqlUpgradeCommand, start, translateSQLException, updateHeartbeat |
IJC_SCHEMA_TABLE_NAME
static final String IJC_SCHEMA_TABLE_NAME
- See Also:
- Constant Field Values
IJC_ITEM_INFO_TABLE_NAME
static final String IJC_ITEM_INFO_TABLE_NAME
- See Also:
- Constant Field Values
IJC_VIEWS_TABLE_NAME
static final String IJC_VIEWS_TABLE_NAME
- See Also:
- Constant Field Values
IJC_USER_TABLE_NAME
static final String IJC_USER_TABLE_NAME
- See Also:
- Constant Field Values
IJC_ITEM_USER_TABLE_NAME
static final String IJC_ITEM_USER_TABLE_NAME
- See Also:
- Constant Field Values
IJC_VIEWS_SEQUENCE_NAME
static final String IJC_VIEWS_SEQUENCE_NAME
- See Also:
- Constant Field Values
IJC_SECURITY_USERS_TABLE_NAME
static final String IJC_SECURITY_USERS_TABLE_NAME
- See Also:
- Constant Field Values
IJC_SECURITY_AUTHORITIES_TABLE_NAME
static final String IJC_SECURITY_AUTHORITIES_TABLE_NAME
- See Also:
- Constant Field Values
IJC_SECURITY_INFO_TABLE_NAME
static final String IJC_SECURITY_INFO_TABLE_NAME
- See Also:
- Constant Field Values
IJC_INVOCATION_LOG_TABLE_NAME
static final String IJC_INVOCATION_LOG_TABLE_NAME
- See Also:
- Constant Field Values
IJC_CHANGE_LOG_TABLE_NAME
static final String IJC_CHANGE_LOG_TABLE_NAME
- See Also:
- Constant Field Values
IJC_AUTHORITIES_TABLE_NAME
static final String IJC_AUTHORITIES_TABLE_NAME
- See Also:
- Constant Field Values
IJC_SCHEMA_AUTHORITIES_TABLE_NAME
static final String IJC_SCHEMA_AUTHORITIES_TABLE_NAME
- See Also:
- Constant Field Values
createIdColumnNameFromTableName
String createIdColumnNameFromTableName(String tableName)
getCartridgeOwner
String getCartridgeOwner()
getCatalog
String getCatalog()
getColumnListCommaSeparated
String getColumnListCommaSeparated(String[] columns)
- Parameters:
columns -
- Returns:
- The comma-separated list of column names
getMetaTableNamesSorted
List<String> getMetaTableNamesSorted()
getNativeJdbcExtractor
NativeJdbcExtractor getNativeJdbcExtractor()
getTermEncoder
TermEncoder getTermEncoder()
sqlAlterColumnDefault
String sqlAlterColumnDefault(SchemaQualifiedName tableName,
String columnName,
Class colClass,
String nativeType,
String columnDefinition,
String defaultValue,
boolean required)
sqlAlterColumnDefault
String sqlAlterColumnDefault(String tableName,
String columnName,
String nativeType,
String columnDefinition,
String defaultValue,
boolean required)
sqlAlterColumnName
String sqlAlterColumnName(String tableName,
String oldName,
String newName,
String definition)
sqlAlterColumnSize
String sqlAlterColumnSize(String tableName,
String columnName,
String columnDefinition)
sqlAlterTableName
String sqlAlterTableName(String oldName,
String newName)
sqlCreateIJCGenericsTable
String sqlCreateIJCGenericsTable()
sqlCreateIJCItemInfoTable
String sqlCreateIJCItemInfoTable()
sqlCreateIJCItemUserTable
String sqlCreateIJCItemUserTable()
sqlCreateIJCInvocationLogTable
String[] sqlCreateIJCInvocationLogTable()
sqlCreateIJCChangesLogTable
String[] sqlCreateIJCChangesLogTable()
sqlCreateIJCAuthoritiesTable
String sqlCreateIJCAuthoritiesTable()
sqlCreateIJCSchemaAuthoritiesTable
String sqlCreateIJCSchemaAuthoritiesTable()
sqlCreateIJCSecurityAuthoritiesAuthoritiesFK
String sqlCreateIJCSecurityAuthoritiesAuthoritiesFK()
sqlCreateIJCSchemaTable
String sqlCreateIJCSchemaTable()
sqlCreateIJCSecurityInfoTable
String sqlCreateIJCSecurityInfoTable()
sqlCreateIJCUserTable
String sqlCreateIJCUserTable()
sqlCreateIJCViewsTable
String[] sqlCreateIJCViewsTable()
sqlCreateTable
String sqlCreateTable(String tableName,
String idColumnName,
String extraCols)
sqlCreateTable
String sqlCreateTable(String schemaPlusTable,
List<DBDatabaseInfo.NativeType> columnDefs,
List<String> columnNames)
- Description copied from interface:
DatabasePlatform
- Creates a table with the given name and the fields. The list of columnDefs
cannot be empty or null; the table must contain at least one column. The
list of column names must be the same size as column definitions; name at
index "i" will be used for column defined by definition at index "i".
- Specified by:
sqlCreateTable in interface DatabasePlatform
columnDefs - The column definitionscolumnNames - The column names
- Returns:
- SQL statement to create the table
sqlCreateView
String sqlCreateView(String viewName,
String sql)
sqlDropColumn
String sqlDropColumn(String tableName,
String columnName)
sqlDropView
String sqlDropView(String viewName)
sqlGenericItemDelete
String sqlGenericItemDelete()
sqlGenericItemInsert
String sqlGenericItemInsert()
sqlGenericItemUpdate
String sqlGenericItemUpdate()
sqlGetItemsByType
String sqlGetItemsByType()
sqlGetDBSchemaVersion
String sqlGetDBSchemaVersion()
sqlQueryForIds
String sqlQueryForIds(String tableName,
String[] idColumnNames,
int limit)
sqlQueryForIdsWithSort
String sqlQueryForIdsWithSort(String tableName,
String[] idColumnNames,
int limit,
SortColumn[] sortCols)
sqlRetrieveSequence
String sqlRetrieveSequence(String sequenceName)
sqlSchemaMetaDataInsert
String sqlSchemaMetaDataInsert()
sqlSchemaMetaDataNextIndex
String sqlSchemaMetaDataNextIndex()
sqlSelect
String sqlSelect(String tableName,
String columns,
String idColumnName)
sqlSetDBSchemaVersion
String sqlSetDBSchemaVersion(boolean insert)
sqlSort
String sqlSort(List ids,
SortColumn[] sortCols,
SchemaQualifiedName tableName,
String selectCol,
DBDatabaseInfo.ColumnSQLType selectColType)
sqlViewMetaDataInsert
String sqlViewMetaDataInsert()
sqlViewMetaDataNextIndex
String sqlViewMetaDataNextIndex()