java.io.Closeable, java.lang.AutoCloseablepublic class MultiCommand extends Command
| Modifier and Type | Field | Description |
|---|---|---|
protected java.util.Map<java.lang.String,Command> |
subcommands |
description, parser| Constructor | Description |
|---|---|
MultiCommand(java.lang.String description,
java.lang.Runnable beforeMain) |
Construct the multi-command with the specified command description and runnable to execute before main is invoked.
|
| Modifier and Type | Method | Description |
|---|---|---|
void |
close() |
|
protected void |
execute(Terminal terminal,
joptsimple.OptionSet options) |
Executes this command.
|
protected void |
printAdditionalHelp(Terminal terminal) |
Prints additional help information, specific to the command
|
addShutdownHook, exit, mainprotected final java.util.Map<java.lang.String,Command> subcommands
public MultiCommand(java.lang.String description,
java.lang.Runnable beforeMain)
description - the multi-command descriptionbeforeMain - the before-main runnableprotected void printAdditionalHelp(Terminal terminal)
CommandprintAdditionalHelp in class Commandprotected void execute(Terminal terminal, joptsimple.OptionSet options) throws java.lang.Exception
CommandUserException.