enum style_t
Description
Various possible styles of options. There are "long" options, which start with "--" and "short", which start with either "-" or "/". Both kinds can be allowed or disallowed, see allow_long and allow_short. The allowed character for short options is also configurable. Option's value can be specified in the same token as name ("--foo=bar"), or in the next token. It's possible to introduce long options by the same character as short options, see allow_long_disguise. Finally, guessing (specifying only prefix of option) and case insensitive processing are supported.
Declared at: libs/pika/program_options/include/pika/program_options/cmdline.hpp:29
Enumerators
| Name | Value | Comment |
|---|---|---|
| allow_long | 1 | Allow "--long_name" style |
| allow_short | 2 | Allow "- <single character" style |
| allow_dash_for_short | 4 | Allow "-" in short options |
| allow_slash_for_short | 8 | Allow "/" in short options |
| long_allow_adjacent | 16 | Allow option parameter in the same token for long option, like in |
| long_allow_next | 32 | Allow option parameter in the next token for long options. |
| short_allow_adjacent | 64 | Allow option parameter in the same token for short options. |
| short_allow_next | 128 | Allow option parameter in the next token for short options. |
| allow_sticky | 256 | Allow to merge several short options together, so that "-s -k" become "-sk". All of the options but last should accept no parameter. For example, if "-s" accept a parameter, then "k" will be taken as parameter, not another short option. Dos-style short options cannot be sticky. |
| allow_guessing | 512 | Allow abbreviated spellings for long options, if they unambiguously identify long option. No long option name should be prefix of other long option name if guessing is in effect. |
| long_case_insensitive | 1024 | Ignore the difference in case for long options. |
| short_case_insensitive | 2048 | Ignore the difference in case for short options. |
| case_insensitive | 3072 | Ignore the difference in case for all options. |
| allow_long_disguise | 4096 | Allow long options with single option starting character, e.g -foo=10 |
| unix_style | 1015 | The more-or-less traditional unix style. |
| default_style | 1015 | The default style. |