|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ShellCommand
The shell command allows a single source to provide a customized invoker according to the context of the arguments. More importantly it allows to decouple the obtention of a command related to its arguments from the actual execution of the command. This somewhat matters because the command execution pipeline has notion of consumed and produced types, thanks to this, the consumed and produced types can vary according to the arguments.
Method Summary | |
---|---|
CommandCompletion |
complete(CommandContext context,
String line)
Provide completions for the specified arguments. |
CommandInvoker<?,?> |
createInvoker(String line)
Provides an invoker for the specified arguments. |
String |
describe(String line,
DescriptionFormat mode)
Returns a description of the command or null if none can be found. |
Method Detail |
---|
CommandCompletion complete(CommandContext context, String line)
context
- the command contextline
- the original command line arguments
String describe(String line, DescriptionFormat mode)
line
- the usage linemode
- the description mode
CommandInvoker<?,?> createInvoker(String line)
line
- the command line arguments
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |