Uses of Class
picocli.CommandLine.Model.OptionSpec
-
Packages that use CommandLine.Model.OptionSpec Package Description picocli Provides classes and interfaces for the main picocli command line parsing andautocompletionfunctionality.picocli.codegen.docgen.manpage -
-
Uses of CommandLine.Model.OptionSpec in picocli
Fields in picocli declared as CommandLine.Model.OptionSpec Modifier and Type Field Description CommandLine.Model.OptionSpecCommandLine.Help. END_OF_OPTIONS_OPTIONFields in picocli with type parameters of type CommandLine.Model.OptionSpec Modifier and Type Field Description private java.util.List<CommandLine.Model.OptionSpec>CommandLine.ParseResult. matchedOptionsprivate java.util.List<CommandLine.Model.OptionSpec>CommandLine.ParseResult.Builder. matchedOptionsListprivate java.util.Set<CommandLine.Model.OptionSpec>CommandLine.ParseResult. matchedUniqueOptionsprivate CommandLine.Model.CaseAwareLinkedMap<java.lang.String,CommandLine.Model.OptionSpec>CommandLine.Model.CommandSpec. negatedOptionsByNameMapprivate java.util.List<CommandLine.Model.OptionSpec>CommandLine.Model.CommandSpec. optionsprivate java.util.Set<CommandLine.Model.OptionSpec>CommandLine.ParseResult.Builder. optionsprivate CommandLine.Model.CaseAwareLinkedMap<java.lang.String,CommandLine.Model.OptionSpec>CommandLine.Model.CommandSpec. optionsByNameMapprivate CommandLine.Model.CaseAwareLinkedMap<java.lang.Character,CommandLine.Model.OptionSpec>CommandLine.Model.CommandSpec. posixOptionsByKeyMapMethods in picocli that return CommandLine.Model.OptionSpec Modifier and Type Method Description CommandLine.Model.OptionSpecCommandLine.Model.OptionSpec.Builder. build()Returns a validOptionSpecinstance.private CommandLine.Model.OptionSpecCommandLine.Help. createEndOfOptionsOption(java.lang.String name)CommandLine.Model.OptionSpecCommandLine.Model.CommandSpec. findOption(char shortName)Returns the option with the specified short name, ornullif no option with that name is defined for this command.(package private) static CommandLine.Model.OptionSpecCommandLine.Model.CommandSpec. findOption(char shortName, java.lang.Iterable<CommandLine.Model.OptionSpec> options)CommandLine.Model.OptionSpecCommandLine.Model.CommandSpec. findOption(java.lang.String name)Returns the option with the specified name, ornullif no option with that name is defined for this command.(package private) static CommandLine.Model.OptionSpecCommandLine.Model.CommandSpec. findOption(java.lang.String name, java.util.List<CommandLine.Model.OptionSpec> options)CommandLine.Model.OptionSpecCommandLine.ParseResult. matchedOption(char shortName)Returns the option with the specified short name, ornullif no option with that name was matched on the command line.CommandLine.Model.OptionSpecCommandLine.ParseResult. matchedOption(java.lang.String name)Returns the option with the specified name, ornullif no option with that name was matched on the command line.Methods in picocli that return types with arguments of type CommandLine.Model.OptionSpec Modifier and Type Method Description private java.util.List<CommandLine.Model.OptionSpec>CommandLine.Model.ArgGroupSpec. addGroupOptionsToListRecursively(java.util.List<CommandLine.Model.OptionSpec> result)java.util.List<CommandLine.Model.OptionSpec>CommandLine.Model.ArgGroupSpec. allOptionsNested()Returns all options configured for this group and all subgroups.java.util.Comparator<CommandLine.Model.OptionSpec>CommandLine.Help. createDefaultOptionSort()Returns a comparator for sorting options, ornull, depending on the settings for this command.(package private) static java.util.Comparator<CommandLine.Model.OptionSpec>CommandLine.Help. createOrderComparator()private static java.util.Comparator<CommandLine.Model.OptionSpec>CommandLine.Help. createOrderComparatorIfNecessary(java.util.List<CommandLine.Model.OptionSpec> options)static java.util.Comparator<CommandLine.Model.OptionSpec>CommandLine.Help. createShortOptionArityAndNameComparator()static java.util.Comparator<CommandLine.Model.OptionSpec>CommandLine.Help. createShortOptionNameComparator()SortsOptionSpecsby their option name in case-insensitive alphabetic order.private java.util.List<CommandLine.Model.OptionSpec>CommandLine.Help. excludeHiddenAndGroupOptions(java.util.List<CommandLine.Model.OptionSpec> all)java.util.List<CommandLine.Model.OptionSpec>CommandLine.ParseResult. matchedOptions()Returns a list of matched options, in order they were matched on the command line.java.util.Set<CommandLine.Model.OptionSpec>CommandLine.ParseResult. matchedOptionsSet()Returns a set of matched options.java.util.Map<java.lang.String,CommandLine.Model.OptionSpec>CommandLine.Model.CommandSpec. negatedOptionsMap()Returns a map of the negated option names to option spec objects configured for this command.(package private) java.util.List<CommandLine.Model.OptionSpec>CommandLine.Help. options()java.util.List<CommandLine.Model.OptionSpec>CommandLine.Model.ArgGroupSpec. options()Returns the list of options configured for this group.java.util.List<CommandLine.Model.OptionSpec>CommandLine.Model.CommandSpec. options()Returns the list of options configured for this command.java.util.Map<java.lang.String,CommandLine.Model.OptionSpec>CommandLine.Model.CommandSpec. optionsMap()Returns a map of the option names to option spec objects configured for this command.java.util.Map<java.lang.Character,CommandLine.Model.OptionSpec>CommandLine.Model.CommandSpec. posixOptionsMap()Returns a map of the short (single character) option names to option spec objects configured for this command.Methods in picocli with parameters of type CommandLine.Model.OptionSpec Modifier and Type Method Description private static voidAutoComplete. addCandidatesForArgsFollowing(CommandLine.Model.OptionSpec optionSpec, java.util.List<java.lang.CharSequence> candidates)voidCommandLine.Help.Layout. addOption(CommandLine.Model.OptionSpec option, CommandLine.Help.IParamLabelRenderer paramLabelRenderer)Delegates to theoption rendererof this layout to obtain text values for the specifiedCommandLine.Model.OptionSpec, and then calls theCommandLine.Help.Layout.layout(CommandLine.Model.ArgSpec, CommandLine.Help.Ansi.Text[][])method to write these text values into the correct cells in the TextTable.CommandLine.Model.CommandSpecCommandLine.Model.CommandSpec. addOption(CommandLine.Model.OptionSpec option)Adds the specified option spec to the list of configured arguments to expect.CommandLine.ParseResult.BuilderCommandLine.ParseResult.Builder. addOption(CommandLine.Model.OptionSpec option)Adds the specifiedOptionSpecto the list of options that were matched on the command line.private voidCommandLine.Model.CommandSpec. addOptionNegative(CommandLine.Model.OptionSpec option, CommandLine.Tracer tracer)static CommandLine.Model.OptionSpec.BuilderCommandLine.Model.OptionSpec. builder(CommandLine.Model.OptionSpec original)Returns a Builder initialized from the specifiedOptionSpec.intCommandLine.Help.SortByOptionArityAndNameAlphabetically. compare(CommandLine.Model.OptionSpec o1, CommandLine.Model.OptionSpec o2)intCommandLine.Help.SortByShortestOptionNameAlphabetically. compare(CommandLine.Model.OptionSpec o1, CommandLine.Model.OptionSpec o2)(package private) static CommandLine.Help.Ansi.TextCommandLine.Help. concatOptionText(java.lang.String prefix, CommandLine.Help.Ansi.Text text, CommandLine.Help.ColorScheme colorScheme, CommandLine.Model.OptionSpec option, CommandLine.Help.IParamLabelRenderer parameterLabelRenderer)private CommandLine.Help.Ansi.TextCommandLine.Model.ArgGroupSpec. concatOptionText(java.lang.String prefix, CommandLine.Help.Ansi.Text text, CommandLine.Help.ColorScheme colorScheme, CommandLine.Model.OptionSpec option)private CommandLine.Help.Ansi.TextCommandLine.Help.DefaultOptionRenderer. createLongOptionText(CommandLine.Model.OptionSpec option, CommandLine.Help.IParamLabelRenderer renderer, CommandLine.Help.ColorScheme scheme, java.lang.String longOption)private static CommandLine.Model.CommandSpecAutoComplete. findCommandFor(CommandLine.Model.OptionSpec option, CommandLine.Model.CommandSpec commandSpec)private static voidAutoComplete. generateCompletionCandidates(java.lang.StringBuilder buff, CommandLine.Model.OptionSpec f)booleanCommandLine.ParseResult. hasMatchedOption(CommandLine.Model.OptionSpec option)Returns whether the specified option was matched on the command line.private <T> TCommandLine.ParseResult. matchedOptionValue(CommandLine.Model.OptionSpec option, T defaultValue)Returns the command line argument value of the specified option, converted to the type of the option, or the specified default value if the specified option isnull.private java.lang.StringCommandLine.PropertiesDefaultProvider. optionDefaultValue(CommandLine.Model.OptionSpec option)CommandLine.Help.Ansi.Text[][]CommandLine.Help.DefaultOptionRenderer. render(CommandLine.Model.OptionSpec option, CommandLine.Help.IParamLabelRenderer paramLabelRenderer, CommandLine.Help.ColorScheme scheme)CommandLine.Help.Ansi.Text[][]CommandLine.Help.IOptionRenderer. render(CommandLine.Model.OptionSpec option, CommandLine.Help.IParamLabelRenderer parameterLabelRenderer, CommandLine.Help.ColorScheme scheme)Returns a text representation of the specified option and its parameter(s) if any.CommandLine.Help.Ansi.Text[][]CommandLine.Help.MinimalOptionRenderer. render(CommandLine.Model.OptionSpec option, CommandLine.Help.IParamLabelRenderer parameterLabelRenderer, CommandLine.Help.ColorScheme scheme)private CommandLine.Help.Ansi.Text[][]CommandLine.Help.DefaultOptionRenderer. renderDescriptionLines(CommandLine.Model.OptionSpec option, CommandLine.Help.ColorScheme scheme, java.lang.String requiredOption, java.lang.String shortOption, CommandLine.Help.Ansi.Text longOptionText)Method parameters in picocli with type arguments of type CommandLine.Model.OptionSpec Modifier and Type Method Description voidCommandLine.Help.Layout. addAllOptions(java.util.List<CommandLine.Model.OptionSpec> options, CommandLine.Help.IParamLabelRenderer paramLabelRenderer)CallsCommandLine.Help.Layout.addOption(CommandLine.Model.OptionSpec, CommandLine.Help.IParamLabelRenderer)for all Options in the specified list.private CommandLine.Model.CommandSpecCommandLine.Model.CommandSpec. addArgGroup(CommandLine.Model.ArgGroupSpec group, java.util.Set<CommandLine.Model.OptionSpec> groupOptions, java.util.Set<CommandLine.Model.PositionalParamSpec> groupPositionals)private voidCommandLine.Model.CommandSpec. addGroupArgsToCommand(CommandLine.Model.ArgGroupSpec group, java.util.Map<java.lang.String,CommandLine.Model.ArgGroupSpec> added, java.util.Set<CommandLine.Model.OptionSpec> groupOptions, java.util.Set<CommandLine.Model.PositionalParamSpec> groupPositionals)private java.util.List<CommandLine.Model.OptionSpec>CommandLine.Model.ArgGroupSpec. addGroupOptionsToListRecursively(java.util.List<CommandLine.Model.OptionSpec> result)voidCommandLine.Help.Layout. addOptions(java.util.List<CommandLine.Model.OptionSpec> options, CommandLine.Help.IParamLabelRenderer paramLabelRenderer)CallsCommandLine.Help.Layout.addOption(CommandLine.Model.OptionSpec, CommandLine.Help.IParamLabelRenderer)for all non-hidden Options in the list.intCommandLine.Help. calcLongOptionColumnWidth(java.util.List<CommandLine.Model.OptionSpec> options, java.util.List<CommandLine.Model.PositionalParamSpec> positionals, CommandLine.Help.ColorScheme aColorScheme)Returns the width of the long options column in the usage help message.CommandLine.Help.LayoutCommandLine.Help. createDefaultLayout(java.util.List<CommandLine.Model.OptionSpec> options, java.util.List<CommandLine.Model.PositionalParamSpec> positionals, CommandLine.Help.ColorScheme aColorScheme)Returns aLayoutinstance configured with the user preferences captured in this Help instance.protected CommandLine.Help.Ansi.TextCommandLine.Help. createDetailedSynopsisOptionsText(java.util.Collection<CommandLine.Model.ArgSpec> done, java.util.Comparator<CommandLine.Model.OptionSpec> optionSort, boolean clusterBooleanOptions)Returns a Text object containing a partial detailed synopsis showing only the options, starting with a" "space.protected CommandLine.Help.Ansi.TextCommandLine.Help. createDetailedSynopsisOptionsText(java.util.Collection<CommandLine.Model.ArgSpec> done, java.util.List<CommandLine.Model.OptionSpec> optionList, java.util.Comparator<CommandLine.Model.OptionSpec> optionSort, boolean clusterBooleanOptions)Returns a Text object containing a partial detailed synopsis showing only the specified options, starting with a" "space.protected CommandLine.Help.Ansi.TextCommandLine.Help. createDetailedSynopsisOptionsText(java.util.Collection<CommandLine.Model.ArgSpec> done, java.util.List<CommandLine.Model.OptionSpec> optionList, java.util.Comparator<CommandLine.Model.OptionSpec> optionSort, boolean clusterBooleanOptions)Returns a Text object containing a partial detailed synopsis showing only the specified options, starting with a" "space.private static java.util.Comparator<CommandLine.Model.OptionSpec>CommandLine.Help. createOrderComparatorIfNecessary(java.util.List<CommandLine.Model.OptionSpec> options)java.lang.StringCommandLine.Help. detailedSynopsis(int synopsisHeadingLength, java.util.Comparator<CommandLine.Model.OptionSpec> optionSort, boolean clusterBooleanOptions)Generates a detailed synopsis message showing all options and parameters.java.lang.StringCommandLine.Help. detailedSynopsis(java.util.Comparator<CommandLine.Model.OptionSpec> optionSort, boolean clusterBooleanOptions)Deprecated.private java.util.List<CommandLine.Model.OptionSpec>CommandLine.Help. excludeHiddenAndGroupOptions(java.util.List<CommandLine.Model.OptionSpec> all)(package private) static CommandLine.Model.OptionSpecCommandLine.Model.CommandSpec. findOption(char shortName, java.lang.Iterable<CommandLine.Model.OptionSpec> options)(package private) static CommandLine.Model.OptionSpecCommandLine.Model.CommandSpec. findOption(java.lang.String name, java.util.List<CommandLine.Model.OptionSpec> options)private static java.lang.StringAutoComplete. generateOptionsCases(java.util.List<CommandLine.Model.OptionSpec> argOptionFields, java.lang.String indent, java.lang.String currWord)private static java.lang.StringAutoComplete. generateOptionsSwitch(java.util.List<CommandLine.Model.OptionSpec> argOptions)java.lang.StringCommandLine.Help. optionList(CommandLine.Help.Layout layout, java.util.Comparator<CommandLine.Model.OptionSpec> optionSort, CommandLine.Help.IParamLabelRenderer valueLabelRenderer)Sorts allOptionswith the specifiedcomparator(if the comparator is non-null), then adds all non-hidden options to the specified TextTable and returns the result of TextTable.toString().java.lang.StringCommandLine.Help. optionListExcludingGroups(java.util.List<CommandLine.Model.OptionSpec> options)Returns a description of the specified list of options.java.lang.StringCommandLine.Help. optionListExcludingGroups(java.util.List<CommandLine.Model.OptionSpec> optionList, CommandLine.Help.Layout layout, java.util.Comparator<CommandLine.Model.OptionSpec> optionSort, CommandLine.Help.IParamLabelRenderer valueLabelRenderer)Sorts allOptionswith the specifiedcomparator(if the comparator is non-null), then adds the specified options to the specified TextTable and returns the result of TextTable.toString().java.lang.StringCommandLine.Help. optionListExcludingGroups(java.util.List<CommandLine.Model.OptionSpec> optionList, CommandLine.Help.Layout layout, java.util.Comparator<CommandLine.Model.OptionSpec> optionSort, CommandLine.Help.IParamLabelRenderer valueLabelRenderer)Sorts allOptionswith the specifiedcomparator(if the comparator is non-null), then adds the specified options to the specified TextTable and returns the result of TextTable.toString().private java.lang.StringCommandLine.Help. optionListGroupSections(java.util.List<CommandLine.Model.ArgGroupSpec> groupList, java.util.Comparator<CommandLine.Model.OptionSpec> optionSort, CommandLine.Help.IParamLabelRenderer paramLabelRenderer)private static java.lang.StringAutoComplete. optionNames(java.util.List<CommandLine.Model.OptionSpec> options)private static <T> intCommandLine.Model.CommandSpec. remove(CommandLine.Model.ArgSpec arg, java.util.Map<T,CommandLine.Model.OptionSpec> map)Constructors in picocli with parameters of type CommandLine.Model.OptionSpec Constructor Description Builder(CommandLine.Model.OptionSpec original) -
Uses of CommandLine.Model.OptionSpec in picocli.codegen.docgen.manpage
Methods in picocli.codegen.docgen.manpage that return types with arguments of type CommandLine.Model.OptionSpec Modifier and Type Method Description private static java.util.Comparator<CommandLine.Model.OptionSpec>ManPageGenerator. createOrderComparatorIfNecessary(java.util.List<CommandLine.Model.OptionSpec> options)Methods in picocli.codegen.docgen.manpage with parameters of type CommandLine.Model.OptionSpec Modifier and Type Method Description intManPageGenerator.SortByShortestOptionNameAlphabetically. compare(CommandLine.Model.OptionSpec o1, CommandLine.Model.OptionSpec o2)private static voidManPageGenerator. writeEndOfOptions(java.io.PrintWriter pw, CommandLine.Help.IOptionRenderer optionRenderer, CommandLine.Help.IParamLabelRenderer paramLabelRenderer, CommandLine.Model.OptionSpec option)Write the end of options.private static voidManPageGenerator. writeOption(java.io.PrintWriter pw, CommandLine.Help.IOptionRenderer optionRenderer, CommandLine.Help.IParamLabelRenderer paramLabelRenderer, CommandLine.Model.OptionSpec option)Method parameters in picocli.codegen.docgen.manpage with type arguments of type CommandLine.Model.OptionSpec Modifier and Type Method Description private static java.util.Comparator<CommandLine.Model.OptionSpec>ManPageGenerator. createOrderComparatorIfNecessary(java.util.List<CommandLine.Model.OptionSpec> options)
-