Package com.aspectran.shell.command
Class AbstractCommand
- java.lang.Object
-
- com.aspectran.shell.command.AbstractCommand
-
- All Implemented Interfaces:
Command
- Direct Known Subclasses:
AspectCommand
,ClearCommand
,EchoCommand
,HelpCommand
,HistoryCommand
,JettyCommand
,JobCommand
,PBDecryptCommand
,PBEncryptCommand
,QuitCommand
,RestartCommand
,SysInfoCommand
,TransletCommand
,UndertowCommand
,VerboseCommand
public abstract class AbstractCommand extends java.lang.Object implements Command
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.aspectran.shell.command.Command
Command.Descriptor
-
-
Constructor Summary
Constructors Constructor Description AbstractCommand(CommandRegistry registry)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addArguments(Arguments arguments)
protected void
addOption(Option option)
ShellService
getActiveShellService()
java.util.List<Arguments>
getArgumentsList()
CommandRegistry
getCommandRegistry()
ConsoleCommander
getCommandRunner()
Options
getOptions()
ShellService
getShellService()
boolean
isServiceAvailable()
void
printHelp(ShellConsole console)
Prints the usage statement for the specified command.void
printQuickHelp(ShellConsole console)
protected void
skipParsingAtNonOption()
protected Arguments
touchArguments()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.aspectran.shell.command.Command
execute, getDescriptor
-
-
-
-
Constructor Detail
-
AbstractCommand
public AbstractCommand(CommandRegistry registry)
-
-
Method Detail
-
getCommandRegistry
public CommandRegistry getCommandRegistry()
-
getCommandRunner
public ConsoleCommander getCommandRunner()
-
getShellService
public ShellService getShellService()
-
getActiveShellService
public ShellService getActiveShellService()
-
isServiceAvailable
public boolean isServiceAvailable()
-
addOption
protected void addOption(Option option)
-
addArguments
protected void addArguments(Arguments arguments)
-
touchArguments
protected Arguments touchArguments()
-
skipParsingAtNonOption
protected void skipParsingAtNonOption()
-
getOptions
public Options getOptions()
- Specified by:
getOptions
in interfaceCommand
-
getArgumentsList
public java.util.List<Arguments> getArgumentsList()
- Specified by:
getArgumentsList
in interfaceCommand
-
printHelp
public void printHelp(ShellConsole console)
Description copied from interface:Command
Prints the usage statement for the specified command.
-
printQuickHelp
public void printQuickHelp(ShellConsole console)
- Specified by:
printQuickHelp
in interfaceCommand
-
-