Interface Parameter.Subcommand.Builder
- All Superinterfaces:
AbstractBuilder<Parameter.Subcommand>
,Builder<Parameter.Subcommand,
,Parameter.Subcommand.Builder> ResettableBuilder<Parameter.Subcommand,
Parameter.Subcommand.Builder>
- Enclosing interface:
- Parameter.Subcommand
public static interface Parameter.Subcommand.Builder
extends Builder<Parameter.Subcommand,Parameter.Subcommand.Builder>
-
Method Summary
Modifier and TypeMethodDescriptionSets an alias for the subcommand.build()
Builds this subcommand parameter.subcommand
(Command.Parameterized command) Sets theCommand.Parameterized
to execute for this subcommand.
-
Method Details
-
addAlias
Sets an alias for the subcommand. This can be executed more than once.- Parameters:
alias
- The alias- Returns:
- This builder, for chaining
-
subcommand
Sets theCommand.Parameterized
to execute for this subcommand.- Parameters:
command
- TheCommand.Parameterized
- Returns:
- This builder, for chaining.
-
build
Parameter.Subcommand build()Builds this subcommand parameter.An alias and the command must be set, else a
IllegalStateException
will be thrown.- Specified by:
build
in interfaceAbstractBuilder<Parameter.Subcommand>
- Returns:
- The
Parameter.Subcommand
-