Class Command
java.lang.Object
org.jacoco.cli.internal.Command
Common interface for all commands.
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract Stringabstract intexecute(PrintWriter out, PrintWriter err) Executes the given command.name()protected voidprintHelp(PrintWriter writer) Prints textual help for this command.usage(CommandParser parser)
-
Field Details
-
JAVACMD
-
help
public boolean helpFlag whether help should be printed for this command. -
quiet
public boolean quietFlag whether output to stdout should be suppressed.
-
-
Constructor Details
-
Command
public Command()
-
-
Method Details
-
description
- Returns:
- Short description of the command.
-
name
- Returns:
- name of the command
-
usage
- Parameters:
parser- parser for this command- Returns:
- usage string displayed for help
-
execute
Executes the given command.- Parameters:
out- std outerr- std err- Returns:
- exit code, should be 0 for normal operation
- Throws:
Exception- any exception that my occur during execution
-
printHelp
Prints textual help for this command.- Parameters:
writer- output destination
-