public class TableUpgrader extends Object
| Modifier and Type | Class and Description |
|---|---|
protected static class |
TableUpgrader.TableUpgrade |
| Modifier and Type | Field and Description |
|---|---|
protected List<TableUpgrader.TableUpgrade> |
tableUpgrades |
| Constructor and Description |
|---|
TableUpgrader(JDBCMapper mapper) |
| Modifier and Type | Method and Description |
|---|---|
void |
add(String tableKey,
String columnName,
String sqlProcedure,
String testProp)
Add a couple table/column associated with a sql procedure to be executed when the column is added and a a test
flag to force his execution.
|
void |
upgrade(String tableKey,
List<Column> addedColumns,
String ddlMode,
SQLStatement.ListCollector ddlCollector)
Check if there is an added column that match with a upgrade process.
|
protected List<TableUpgrader.TableUpgrade> tableUpgrades
public TableUpgrader(JDBCMapper mapper)
public void add(String tableKey, String columnName, String sqlProcedure, String testProp)
tableKey - table namecolumnName - desired added columnsqlProcedure - sql procedure nametestProp - test flag namepublic void upgrade(String tableKey, List<Column> addedColumns, String ddlMode, SQLStatement.ListCollector ddlCollector) throws SQLException
tableKey - table nameaddedColumns - list of added columnSQLException - Exception thrown by JDBCCopyright © 2018 Nuxeo. All rights reserved.