Package liquibase.command.core
Class HistoryCommandStep
- java.lang.Object
-
- liquibase.command.AbstractCommandStep
-
- liquibase.command.AbstractCliWrapperCommandStep
-
- liquibase.command.core.HistoryCommandStep
-
- All Implemented Interfaces:
CommandStep
public class HistoryCommandStep extends AbstractCliWrapperCommandStep
-
-
Field Summary
Fields Modifier and Type Field Description static CommandArgumentDefinition<String>
CHANGELOG_FILE_ARG
static String[]
COMMAND_NAME
static CommandArgumentDefinition<String>
DEFAULT_CATALOG_NAME_ARG
static CommandArgumentDefinition<String>
DEFAULT_SCHEMA_NAME_ARG
static CommandArgumentDefinition<String>
DRIVER_ARG
static CommandArgumentDefinition<String>
DRIVER_PROPERTIES_FILE_ARG
static CommandArgumentDefinition<HistoryFormat>
FORMAT_ARG
static CommandArgumentDefinition<String>
PASSWORD_ARG
static CommandArgumentDefinition<String>
URL_ARG
static CommandArgumentDefinition<String>
USERNAME_ARG
-
Fields inherited from class liquibase.command.AbstractCommandStep
coreBundle
-
Fields inherited from interface liquibase.command.CommandStep
ORDER_DEFAULT, ORDER_NOT_APPLICABLE
-
-
Constructor Summary
Constructors Constructor Description HistoryCommandStep()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
adjustCommandDefinition(CommandDefinition commandDefinition)
Default implementation makes no changesprotected String[]
collectArguments(CommandScope commandScope)
Called byAbstractCliWrapperCommandStep.run(CommandResultsBuilder)
to create the actual arguments passed toMain.run(String[])
.String[][]
defineCommandNames()
Defines new command names For example, if it is part of `liquibase update`, this should return new String[][]{ new String[] {"update"}}.-
Methods inherited from class liquibase.command.AbstractCliWrapperCommandStep
collectArguments, preRunCheck, removeArgumentValues, run
-
Methods inherited from class liquibase.command.AbstractCommandStep
getOrder, providedDependencies, requiredDependencies, validate
-
-
-
-
Field Detail
-
COMMAND_NAME
public static final String[] COMMAND_NAME
-
URL_ARG
public static final CommandArgumentDefinition<String> URL_ARG
-
DEFAULT_SCHEMA_NAME_ARG
public static final CommandArgumentDefinition<String> DEFAULT_SCHEMA_NAME_ARG
-
DEFAULT_CATALOG_NAME_ARG
public static final CommandArgumentDefinition<String> DEFAULT_CATALOG_NAME_ARG
-
USERNAME_ARG
public static final CommandArgumentDefinition<String> USERNAME_ARG
-
PASSWORD_ARG
public static final CommandArgumentDefinition<String> PASSWORD_ARG
-
CHANGELOG_FILE_ARG
public static final CommandArgumentDefinition<String> CHANGELOG_FILE_ARG
-
DRIVER_ARG
public static final CommandArgumentDefinition<String> DRIVER_ARG
-
DRIVER_PROPERTIES_FILE_ARG
public static final CommandArgumentDefinition<String> DRIVER_PROPERTIES_FILE_ARG
-
FORMAT_ARG
public static final CommandArgumentDefinition<HistoryFormat> FORMAT_ARG
-
-
Method Detail
-
defineCommandNames
public String[][] defineCommandNames()
Description copied from interface:CommandStep
Defines new command names For example, if it is part of `liquibase update`, this should return new String[][]{ new String[] {"update"}}. If it is a part of `liquibase example init`, this should return {"example", "init"}.This is used to determine the available command names.
This can return null if this step is not defining a new command but "cross-cutting" existing commands
-
adjustCommandDefinition
public void adjustCommandDefinition(CommandDefinition commandDefinition)
Description copied from class:AbstractCommandStep
Default implementation makes no changes- Specified by:
adjustCommandDefinition
in interfaceCommandStep
- Overrides:
adjustCommandDefinition
in classAbstractCommandStep
-
collectArguments
protected String[] collectArguments(CommandScope commandScope) throws CommandExecutionException
Description copied from class:AbstractCliWrapperCommandStep
Called byAbstractCliWrapperCommandStep.run(CommandResultsBuilder)
to create the actual arguments passed toMain.run(String[])
.Implementations should generally call
AbstractCliWrapperCommandStep.collectArguments(CommandScope, List, String)
and possiblyAbstractCliWrapperCommandStep.removeArgumentValues(String[], String...)
- Specified by:
collectArguments
in classAbstractCliWrapperCommandStep
- Throws:
CommandExecutionException
-
-