Uses of Class
org.apache.logging.log4j.core.tools.picocli.CommandLine
Packages that use CommandLine
-
Uses of CommandLine in org.apache.logging.log4j.core.tools.picocli
Fields in org.apache.logging.log4j.core.tools.picocli declared as CommandLineModifier and TypeFieldDescriptionprivate final CommandLine
CommandLine.ExecutionException.commandLine
private final CommandLine
CommandLine.ParameterException.commandLine
private CommandLine
CommandLine.parent
Fields in org.apache.logging.log4j.core.tools.picocli with type parameters of type CommandLineModifier and TypeFieldDescriptionprivate final Map
<String, CommandLine> CommandLine.Interpreter.commands
Methods in org.apache.logging.log4j.core.tools.picocli that return CommandLineModifier and TypeMethodDescriptionCommandLine.addSubcommand
(String name, Object command) Registers a subcommand with the specified name.CommandLine.ExecutionException.getCommandLine()
Returns theCommandLine
object for the (sub)command that could not be invoked.CommandLine.ParameterException.getCommandLine()
Returns theCommandLine
object for the (sub)command whose input could not be parsed.CommandLine.getParent()
Returns the command that this is a subcommand of, ornull
if this is a top-level command.<K> CommandLine
CommandLine.registerConverter
(Class<K> cls, CommandLine.ITypeConverter<K> converter) Registers the specified type converter for the specified class.CommandLine.setCommandName
(String commandName) Sets the command name (also called program name) displayed in the usage help synopsis to the specified value.CommandLine.setOverwrittenOptionsAllowed
(boolean newValue) Sets whether options for single-value fields can be specified multiple times on the command line without aCommandLine.OverwrittenOptionException
being thrown.CommandLine.setSeparator
(String separator) Sets the String the parser uses to separate option names from option values to the specified value.CommandLine.setUnmatchedArgumentsAllowed
(boolean newValue) Sets whether the end user may specify unmatched arguments on the command line without aCommandLine.UnmatchedArgumentException
being thrown.private static CommandLine
CommandLine.toCommandLine
(Object obj) Methods in org.apache.logging.log4j.core.tools.picocli that return types with arguments of type CommandLineModifier and TypeMethodDescriptionCommandLine.getSubcommands()
Returns a map with the subcommands registered on this instance.(package private) List
<CommandLine> Entry point into parsing command line arguments.Parses the specified command line arguments and returns a list ofCommandLine
objects representing the top-level command and any subcommands (if any) that were recognized and initialized during the parsing process.Methods in org.apache.logging.log4j.core.tools.picocli with parameters of type CommandLineModifier and TypeMethodDescriptionprivate static CommandLine.MissingParameterException
CommandLine.MissingParameterException.create
(CommandLine cmd, Collection<Field> missing, String separator) private static CommandLine.ParameterException
CommandLine.ParameterException.create
(CommandLine cmd, Exception ex, String arg, int i, String[] args) private static Object
CommandLine.execute
(CommandLine parsed) Method parameters in org.apache.logging.log4j.core.tools.picocli with type arguments of type CommandLineModifier and TypeMethodDescriptionCommandLine.Help.addAllSubcommands
(Map<String, CommandLine> commands) Registers all specified subcommands with this Help.CommandLine.IParseResultHandler.handleParseResult
(List<CommandLine> parsedCommands, PrintStream out, CommandLine.Help.Ansi ansi) Processes a List ofCommandLine
objects resulting from successfully parsing the command line arguments and optionally returns a list of results.CommandLine.RunAll.handleParseResult
(List<CommandLine> parsedCommands, PrintStream out, CommandLine.Help.Ansi ansi) Prints help if requested, and otherwise executes the top-level command and all subcommands asRunnable
orCallable
.CommandLine.RunFirst.handleParseResult
(List<CommandLine> parsedCommands, PrintStream out, CommandLine.Help.Ansi ansi) Prints help if requested, and otherwise executes the top-levelRunnable
orCallable
command.CommandLine.RunLast.handleParseResult
(List<CommandLine> parsedCommands, PrintStream out, CommandLine.Help.Ansi ansi) Prints help if requested, and otherwise executes the most specificRunnable
orCallable
subcommand.private void
CommandLine.Interpreter.parse
(List<CommandLine> parsedCommands, Stack<String> argumentStack, String[] originalArgs) static boolean
CommandLine.printHelpIfRequested
(List<CommandLine> parsedCommands, PrintStream out, CommandLine.Help.Ansi ansi) Helper method that may be useful when processing the list ofCommandLine
objects that result from successfully parsing command line arguments.private void
CommandLine.Interpreter.processArguments
(List<CommandLine> parsedCommands, Stack<String> args, Collection<Field> required, Set<Field> initialized, String[] originalArgs) Constructors in org.apache.logging.log4j.core.tools.picocli with parameters of type CommandLineModifierConstructorDescriptionExecutionException
(CommandLine commandLine, String msg) ExecutionException
(CommandLine commandLine, String msg, Exception ex) MaxValuesforFieldExceededException
(CommandLine commandLine, String msg) MissingParameterException
(CommandLine commandLine, String msg) MissingTypeConverterException
(CommandLine commandLine, String msg) OverwrittenOptionException
(CommandLine commandLine, String msg) ParameterException
(CommandLine commandLine, String msg) Constructs a new ParameterException with the specified CommandLine and error message.ParameterException
(CommandLine commandLine, String msg, Exception ex) Constructs a new ParameterException with the specified CommandLine and error message.UnmatchedArgumentException
(CommandLine commandLine, String msg) UnmatchedArgumentException
(CommandLine commandLine, List<String> args) UnmatchedArgumentException
(CommandLine commandLine, Stack<String> args)