public class HibernateDdlExecutor extends Object implements DdlExecutor
DdlCommands thrown its way.| Constructor and Description |
|---|
HibernateDdlExecutor(ConfluenceHibernateConfig hibernateConfig,
org.hibernate.SessionFactory sessionFactory) |
| Modifier and Type | Method and Description |
|---|---|
CreateIndexCommand |
createCreateIndexCommand(String indexName,
String tableName,
boolean isUnique,
String... columnNames)
Create a compound index
|
CreateIndexCommand |
createCreateIndexCommand(String indexName,
String tableName,
String... columnNames)
Create a compound non-unique index
|
DropIndexCommand |
createDropIndexCommand(String indexName,
String tableName) |
DropTableCommand |
createDropTableCommand(String tableName) |
RenameTableCommand |
createRenameTableCommand(String oldTableName,
String newTableName) |
CreateUniqueConstraintWithMultipleNullsCommand |
createUniqueConstraintWithMultipleNullsCommand(String constraintName,
String tableName,
String columnName) |
void |
executeDdl(List<? extends DdlCommand> commands)
Perform a set of data definition altering actions.
|
void |
executeDdlStatements(List<String> statements) |
List<String> |
getDdlStatements(List<? extends DdlCommand> commands) |
public HibernateDdlExecutor(ConfluenceHibernateConfig hibernateConfig, org.hibernate.SessionFactory sessionFactory)
public CreateIndexCommand createCreateIndexCommand(String indexName, String tableName, String... columnNames)
createCreateIndexCommand in interface DdlExecutorindexName - the index nametableName - the table namecolumnNames - a set of column namespublic CreateIndexCommand createCreateIndexCommand(String indexName, String tableName, boolean isUnique, String... columnNames)
createCreateIndexCommand in interface DdlExecutorindexName - the index nametableName - the table nameisUnique - true if the index is uniquecolumnNames - a set of column namespublic CreateUniqueConstraintWithMultipleNullsCommand createUniqueConstraintWithMultipleNullsCommand(String constraintName, String tableName, String columnName)
createUniqueConstraintWithMultipleNullsCommand in interface DdlExecutorpublic DropIndexCommand createDropIndexCommand(String indexName, String tableName)
createDropIndexCommand in interface DdlExecutorpublic DropTableCommand createDropTableCommand(String tableName)
createDropTableCommand in interface DdlExecutorpublic RenameTableCommand createRenameTableCommand(String oldTableName, String newTableName)
createRenameTableCommand in interface DdlExecutorpublic void executeDdl(List<? extends DdlCommand> commands)
DdlExecutorexecuteDdl in interface DdlExecutorcommands - A collection of ddl commands to performpublic void executeDdlStatements(List<String> statements)
executeDdlStatements in interface DdlExecutorpublic List<String> getDdlStatements(List<? extends DdlCommand> commands)
getDdlStatements in interface DdlExecutorCopyright © 2003–2022 Atlassian. All rights reserved.