Package liquibase.command
Class CommandDefinition
java.lang.Object
liquibase.command.CommandDefinition
- All Implemented Interfaces:
Comparable<CommandDefinition>
Metadata about a particular command. Look up instances with
CommandFactory.getCommandDefinition(String...)
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
add
(CommandArgumentDefinition commandArg) void
Add an alias to the command.int
boolean
getArgument
(String argName) Returns the given argument definition for this command.Returns the arguments for this command.<T> SortedSet<CommandArgumentDefinition<T>>
getArguments
(Class<T> argumentType) Convenience method to return the arguments for this command which are of a given type.getGroupLongDescription
(String[] group) The long description of the given command group.getGroupShortDescription
(String[] group) The short description of the given command group.boolean
Hidden commands are ones that can be called via integrations, but should not be normally shown in help to users.boolean
Internal commands are ones that can be called programmatically, but should not be exposed directly and automatically through integrations.The long description of the command.String[]
getName()
The fully qualified name of this command.Returns the steps in the command's pipelineThe short description of the command.int
hashCode()
boolean
Return true if this command represents the given commandvoid
setGroupHelpFooter
(String groupFooter) void
setGroupLongDescription
(String[] group, String longDescription) void
setGroupShortDescription
(String[] group, String shortDescription) Sets the short description of the given command group for help docs.void
setHelpFooter
(String footer) void
setHidden
(boolean hidden) void
setInternal
(boolean internal) void
setLongDescription
(String longDescription) void
setShortDescription
(String shortDescription)
-
Constructor Details
-
CommandDefinition
-
-
Method Details
-
getName
The fully qualified name of this command. -
compareTo
- Specified by:
compareTo
in interfaceComparable<CommandDefinition>
-
equals
-
hashCode
public int hashCode() -
getPipeline
Returns the steps in the command's pipeline -
getArgument
Returns the given argument definition for this command. Handles argument name smoothing. Returns null if no argument matches. -
getArguments
Returns the arguments for this command. -
getArguments
Convenience method to return the arguments for this command which are of a given type. -
getShortDescription
The short description of the command. Used in help docs. -
setShortDescription
-
getGroupShortDescription
The short description of the given command group. Used in help docs. -
setGroupShortDescription
Sets the short description of the given command group for help docs. If multiple command commands set different descriptions for the group, which version will be shown in any rolled up help is undefined. -
getGroupLongDescription
The long description of the given command group. Used in help docs. If multiple command commands set different descriptions for the group, which version will be shown in any rolled up help is undefined. -
setGroupLongDescription
-
getLongDescription
The long description of the command. Used in help docs. -
setLongDescription
-
add
-
getInternal
public boolean getInternal()Internal commands are ones that can be called programmatically, but should not be exposed directly and automatically through integrations. -
setInternal
public void setInternal(boolean internal) -
getHidden
public boolean getHidden()Hidden commands are ones that can be called via integrations, but should not be normally shown in help to users. "Alias" or legacy commands are often marked as hidden commands. -
setHidden
public void setHidden(boolean hidden) -
is
Return true if this command represents the given command -
addAlias
Add an alias to the command.
-