## 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 and `autocompletion` functionality.

- - ### Uses of CommandLine.Model.OptionSpec in picocli

    Methods in picocli that return CommandLine.Model.OptionSpec
    Modifier and Type | Method and Description
    --- | ---
    `CommandLine.Model.OptionSpec` | CommandLine.Model.OptionSpec.Builder.`build()` Returns a valid `OptionSpec` instance.
    `CommandLine.Model.OptionSpec` | CommandLine.Model.CommandSpec.`findOption(char shortName)` Returns the option with the specified short name, or `null` if no option with that name is defined for this command.
    `CommandLine.Model.OptionSpec` | CommandLine.Model.CommandSpec.`findOption(String name)` Returns the option with the specified name, or `null` if no option with that name is defined for this command.
    `CommandLine.Model.OptionSpec` | CommandLine.ParseResult.`matchedOption(char shortName)` Returns the option with the specified short name, or `null` if no option with that name was matched on the command line.
    `CommandLine.Model.OptionSpec` | CommandLine.ParseResult.`matchedOption(String name)` Returns the option with the specified name, or `null` if 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 and Description
    --- | ---
    `static Comparator<CommandLine.Model.OptionSpec>` | CommandLine.Help.`createShortOptionArityAndNameComparator()` Sorts `OptionSpecs` by their option max arity first, by min arity next, and by option name last.
    `static Comparator<CommandLine.Model.OptionSpec>` | CommandLine.Help.`createShortOptionNameComparator()` Sorts `OptionSpecs` by their option name in case-insensitive alphabetic order.
    `List<CommandLine.Model.OptionSpec>` | CommandLine.ParseResult.`matchedOptions()` Returns a list of matched options, in the order they were found on the command line.
    `List<CommandLine.Model.OptionSpec>` | CommandLine.Model.CommandSpec.`options()` Returns the list of options configured for this command.
    `Map<String,CommandLine.Model.OptionSpec>` | CommandLine.Model.CommandSpec.`optionsMap()` Returns a map of the option names to option spec objects configured for this command.
    `Map<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 and Description
    --- | ---
    `CommandLine.Model.CommandSpec` | CommandLine.Model.CommandSpec.`addOption(CommandLine.Model.OptionSpec option)` Adds the specified option spec to the list of configured arguments to expect.
    `CommandLine.ParseResult.Builder` | CommandLine.ParseResult.Builder.`addOption(CommandLine.Model.OptionSpec option)` Adds the specified `OptionSpec` to the list of options that were matched on the command line.
    `void` | CommandLine.Help.Layout.`addOption(CommandLine.Model.OptionSpec option, CommandLine.Help.IParamLabelRenderer paramLabelRenderer)` Delegates to the `option renderer` of this layout to obtain text values for the specified `CommandLine.Model.OptionSpec`, and then calls the `CommandLine.Help.Layout.layout(CommandLine.Model.ArgSpec, CommandLine.Help.Ansi.Text[][])` method to write these text values into the correct cells in the TextTable.
    `boolean` | CommandLine.ParseResult.`hasMatchedOption(CommandLine.Model.OptionSpec option)` Returns whether the specified option was matched on the command line.
    `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.

    Method parameters in picocli with type arguments of type CommandLine.Model.OptionSpec
    Modifier and Type | Method and Description
    --- | ---
    `void` | CommandLine.Help.Layout.`addOptions(List<CommandLine.Model.OptionSpec> options, CommandLine.Help.IParamLabelRenderer paramLabelRenderer)` Calls `CommandLine.Help.Layout.addOption(CommandLine.Model.OptionSpec, CommandLine.Help.IParamLabelRenderer)` for all non-hidden Options in the list.
    `protected CommandLine.Help.Ansi.Text` | CommandLine.Help.`createDetailedSynopsisOptionsText(Comparator<CommandLine.Model.OptionSpec> optionSort, boolean clusterBooleanOptions)` Returns a Text object containing a partial detailed synopsis showing only the options, starting with a `" "` space.
    `String` | CommandLine.Help.`detailedSynopsis(Comparator<CommandLine.Model.OptionSpec> optionSort, boolean clusterBooleanOptions)` Deprecated. use `CommandLine.Help.detailedSynopsis(int, Comparator, boolean)` instead.
    `String` | CommandLine.Help.`detailedSynopsis(int synopsisHeadingLength, Comparator<CommandLine.Model.OptionSpec> optionSort, boolean clusterBooleanOptions)` Generates a detailed synopsis message showing all options and parameters.
    `String` | CommandLine.Help.`optionList(CommandLine.Help.Layout layout, Comparator<CommandLine.Model.OptionSpec> optionSort, CommandLine.Help.IParamLabelRenderer valueLabelRenderer)` Sorts all `Options` with the specified `comparator` (if the comparator is non-`null`), then adds all non-hidden options to the specified TextTable and returns the result of TextTable.toString().

Copyright © 2019. All rights reserved.