Package nz.org.riskscape.engine.cli
Class Main
java.lang.Object
nz.org.riskscape.engine.cli.Main
- All Implemented Interfaces:
nz.org.riskscape.picocli.CommandLine.IVersionProvider
CLI Application entry point.
-
Field Summary
Modifier and TypeFieldDescriptionprotected final CliBootstrap
static final String
protected nz.org.riskscape.picocli.CommandLine
static final String
static final String
protected final nz.org.riskscape.engine.i18n.Messages
protected final nz.org.riskscape.engine.plugin.PluginRepository
protected final nz.org.riskscape.cli.Terminal
-
Constructor Summary
ConstructorDescriptionMain()
Main
(org.jline.terminal.Terminal jlineTerminal, nz.org.riskscape.cli.Terminal terminal, nz.org.riskscape.engine.i18n.Messages messages, Consumer<Integer> exithook, nz.org.riskscape.engine.plugin.PluginRepository pluginRepository, CliBootstrap bootstrap) -
Method Summary
Modifier and TypeMethodDescriptionString[]
protected void
handleExitException
(nz.org.riskscape.engine.cli.ExitException ex, boolean showStackTrace) static Path
Standard logic for looking up where RiskScape seems to be installedstatic void
Java app entry point.void
processResult
(Object result) void
protected void
unhandledException
(Exception ex, boolean showStackTrace)
-
Field Details
-
COPYRIGHT_NOTICE
-
LICENSE_NOTICE
-
CLI_HELP_RESOURCE_BUNDLE_NAME
- See Also:
-
cmd
protected nz.org.riskscape.picocli.CommandLine cmd -
terminal
protected final nz.org.riskscape.cli.Terminal terminal -
messages
protected final nz.org.riskscape.engine.i18n.Messages messages -
exithook
-
pluginRepository
protected final nz.org.riskscape.engine.plugin.PluginRepository pluginRepository -
bootstrap
-
-
Constructor Details
-
Main
public Main() -
Main
public Main(org.jline.terminal.Terminal jlineTerminal, nz.org.riskscape.cli.Terminal terminal, nz.org.riskscape.engine.i18n.Messages messages, Consumer<Integer> exithook, nz.org.riskscape.engine.plugin.PluginRepository pluginRepository, CliBootstrap bootstrap)
-
-
Method Details
-
main
Java app entry point.
-
lookupApplicationHome
Standard logic for looking up where RiskScape seems to be installed
-
getVersion
- Specified by:
getVersion
in interfacenz.org.riskscape.picocli.CommandLine.IVersionProvider
- Throws:
Exception
-
runMain
- Throws:
Exception
-
handleExitException
protected void handleExitException(nz.org.riskscape.engine.cli.ExitException ex, boolean showStackTrace) -
unhandledException
-
processResult
-