Package jslx.dbutilities.dbutil
Class DbCreateTask
- java.lang.Object
-
- jslx.dbutilities.dbutil.DbCreateTask
-
public class DbCreateTask extends java.lang.ObjectA DbCreateTask represents a set of instructions that can be used to create, possibly fill, and alter a database. It can be used only once. The enum Type indicates what kind of tasks will be executed and the state of the task.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceDbCreateTask.AfterTablesOnlyStepIfcstatic interfaceDbCreateTask.DBAddConstraintsStepIfcstatic interfaceDbCreateTask.DBAfterInsertStepIfcstatic interfaceDbCreateTask.DbCreateStepIfcstatic classDbCreateTask.DbCreateTaskBuilderA builder that can be used to configure a database creation task through as set of configuration steps.static interfaceDbCreateTask.DbCreateTaskExecuteStepIfcstatic interfaceDbCreateTask.DbCreateTaskFirstStepIfcUsed to limit the options on the first stepstatic interfaceDbCreateTask.DbInsertStepIfcstatic classDbCreateTask.Statestatic classDbCreateTask.Typestatic interfaceDbCreateTask.WithCreateScriptStepIfcAllows the user to specify a full creation script that puts the database into the state desired by the user.static interfaceDbCreateTask.WithTablesScriptStepIfcAllows the user to specify a script that creates the tables of the database
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<java.lang.String>getAlterCommands()java.util.List<java.lang.String>getCreationScriptCommands()java.nio.file.PathgetExcelWorkbookPathForDataInsert()java.util.List<java.lang.String>getInsertCommands()java.util.List<java.lang.String>getInsertTableOrder()DbCreateTask.StategetState()java.util.List<java.lang.String>getTableCommands()DbCreateTask.TypegetType()java.lang.StringtoString()
-
-
-
Method Detail
-
getExcelWorkbookPathForDataInsert
public java.nio.file.Path getExcelWorkbookPathForDataInsert()
- Returns:
- the path to the Excel workbook to be used for inserting data, may be null
-
getInsertTableOrder
public java.util.List<java.lang.String> getInsertTableOrder()
- Returns:
- a list of table names in the order in which they need to be inserted. May be empty
-
getCreationScriptCommands
public java.util.List<java.lang.String> getCreationScriptCommands()
- Returns:
- a list of all the commands that were in the creation script, may be empty
-
getTableCommands
public java.util.List<java.lang.String> getTableCommands()
- Returns:
- a list of the create table commands, may be empty
-
getInsertCommands
public java.util.List<java.lang.String> getInsertCommands()
- Returns:
- a list of the insert commands, may be empty
-
getAlterCommands
public java.util.List<java.lang.String> getAlterCommands()
- Returns:
- a list of the alter commands, may be empty
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
getType
public final DbCreateTask.Type getType()
- Returns:
- the type of the command sequence specified during the builder process
-
getState
public final DbCreateTask.State getState()
-
-