public abstract class Command extends Object
Modifier | Constructor and Description |
---|---|
protected |
Command(String name,
String description)
Create a new command with the given name and description.
|
Modifier and Type | Method and Description |
---|---|
abstract void |
configure(net.sourceforge.argparse4j.inf.Subparser subparser)
Configure the command's
Subparser . |
String |
getDescription()
Returns the command's description.
|
String |
getName()
Returns the command's name.
|
abstract void |
run(Bootstrap<?> bootstrap,
net.sourceforge.argparse4j.inf.Namespace namespace)
Executes when the user runs this specific command.
|
public final String getName()
public final String getDescription()
public abstract void configure(net.sourceforge.argparse4j.inf.Subparser subparser)
Subparser
.subparser
- the Subparser
specific to the commandpublic abstract void run(Bootstrap<?> bootstrap, net.sourceforge.argparse4j.inf.Namespace namespace) throws Exception
bootstrap
- the bootstrap bootstrapnamespace
- the parsed command line namespaceException
- if something goes wrongCopyright © 2016. All rights reserved.