Package convex.cli
Class Main
java.lang.Object
convex.cli.ACommand
convex.cli.Main
- All Implemented Interfaces:
Runnable
Convex CLI implementation
This is the main `convex` command and root for child commands.
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncli()Gets the current CLI main command instancepicocli.CommandLinevoidexecute()Execute this command.booleanChecks if the CLI should output ANSI coloursbooleanChecks if the CLI is in interactive mode (user input permitted)booleanChecks if the CLI is in strict (paranoid) modestatic voidJava main(...) entry point when run as a Java application.intmainExecute(String[] args) Command line execution entry point.voidSets output to the specified file.protected intverbose()Gets the current verbosity level for the CLIMethods inherited from class convex.cli.ACommand
inform, inform, informError, informSuccess, informWarning, paranoia, println, println, printRecord, printResult, prompt, readPassword, run, showUsage
-
Field Details
-
commandLine
public picocli.CommandLine commandLine
-
-
Constructor Details
-
Main
public Main()
-
-
Method Details
-
execute
public void execute()Description copied from class:ACommandExecute this command. Subclasses should override this to provide specific command functionality -
main
Java main(...) entry point when run as a Java application. Exits JVM process with specified exit code- Parameters:
args- Command line arguments
-
mainExecute
Command line execution entry point. Can be run from Java code without terminating the JVM.- Parameters:
args- Command line arguments- Returns:
- Process result value
-
isParanoid
public boolean isParanoid()Description copied from class:ACommandChecks if the CLI is in strict (paranoid) mode- Overrides:
isParanoidin classACommand- Returns:
- true iff in strict mode
-
isColoured
public boolean isColoured()Description copied from class:ACommandChecks if the CLI should output ANSI colours- Overrides:
isColouredin classACommand- Returns:
-
commandLine
public picocli.CommandLine commandLine()- Overrides:
commandLinein classACommand
-
isInteractive
public boolean isInteractive()Description copied from class:ACommandChecks if the CLI is in interactive mode (user input permitted)- Overrides:
isInteractivein classACommand- Returns:
- True if in interactive mode
-
verbose
protected int verbose()Description copied from class:ACommandGets the current verbosity level for the CLI -
setOut
Sets output to the specified file.- Parameters:
outFile- String specifying file. `-` or `null` specifies STDOUT
-
cli
Description copied from class:ACommandGets the current CLI main command instance
-