|
| | args () noexcept |
| | Default constructor.
|
| |
| | ~args () |
| | Destructor.
|
| |
| | args (const args &other) |
| | Copy constructor.
|
| |
| args & | operator= (const args &other) |
| | Copy assignment operator.
|
| |
| | args (args &&other) noexcept=default |
| | Move constructor.
|
| |
| args & | operator= (args &&other) noexcept=default |
| | Move assignment operator.
|
| |
| bool | parse (const std::vector< std::string > &arguments, bool has_program_name_as_first_arg=false) noexcept |
| | Parse program arguments from a vector of strings.
|
| |
| bool | parse (const std::string &arguments, bool has_program_name_as_first_arg=false) noexcept |
| | Parse program arguments from a string.
|
| |
| bool | parse (int argc, char **argv, bool has_program_name_as_first_arg=false) noexcept |
| | Parse program arguments from argc/argv.
|
| |
|
void | clear () noexcept |
| | Clear the arguments map.
|
| |
| std::optional< std::string > | get (const std::string &key) const noexcept |
| | Get a value from the args map (from front)
|
| |
| std::optional< std::unordered_map< std::string, std::string > > | get () const noexcept |
| | Get entire args map (from front)
|
| |
| std::optional< std::vector< std::unordered_map< std::string, std::string > > > | get_array () const noexcept |
| | Get vector of args maps (useful for JSON parsing with array of objects)
|
| |
|
|
static constexpr const auto | APP_KEY = "app" |
| |
|
static constexpr const auto | ALGO_ID_FLAG_STR = "-a" |
| |
|
static constexpr const auto | ALGO_ID_OPTION_STR = "--algo" |
| |
|
static constexpr const auto | ALGO_ID_WORD_STR = "algo" |
| |
|
static constexpr const auto | BLOCK_ID_FLAG_STR = "-b" |
| |
|
static constexpr const auto | BLOCK_ID_OPTION_STR = "--block" |
| |
|
static constexpr const auto | BLOCK_ID_WORD_STR = "block" |
| |
|
static constexpr const auto | ROW_FLAG_STR = "-r" |
| |
|
static constexpr const auto | ROW_OPTION_STR = "--rows" |
| |
|
static constexpr const auto | ROW_WORD_STR = "rows" |
| |
|
static constexpr const auto | COLUMN_FLAG_STR = "-c" |
| |
|
static constexpr const auto | COLUMN_OPTION_STR = "--columns" |
| |
|
static constexpr const auto | COLUMN_WORD_STR = "columns" |
| |
|
static constexpr const auto | LEVEL_FLAG_STR = "-l" |
| |
|
static constexpr const auto | LEVEL_OPTION_STR = "--levels" |
| |
|
static constexpr const auto | LEVEL_WORD_STR = "levels" |
| |
|
static constexpr const auto | JSON_FLAG_STR = "-j" |
| |
|
static constexpr const auto | JSON_OPTION_STR = "--json" |
| |
|
static constexpr const auto | JSON_WORD_STR = "json" |
| |
|
static constexpr const auto | OUTPUT_ID_FLAG_STR = "-o" |
| |
|
static constexpr const auto | OUTPUT_ID_OPTION_STR = "--output" |
| |
|
static constexpr const auto | OUTPUT_ID_WORD_STR = "output" |
| |
|
static constexpr const auto | DEFAULT_OUTPUT_FILENAME = "maze.txt" |
| |
|
static constexpr const auto | OUTPUT_FILENAME_WORD_STR = "output_filename" |
| |
|
static constexpr const auto | SEED_FLAG_STR = "-s" |
| |
|
static constexpr const auto | SEED_OPTION_STR = "--seed" |
| |
|
static constexpr const auto | SEED_WORD_STR = "seed" |
| |
|
static constexpr const auto | DISTANCES_FLAG_STR = "-d" |
| |
|
static constexpr const auto | DISTANCES_OPTION_STR = "--distances" |
| |
|
static constexpr const auto | DISTANCES_WORD_STR = "distances" |
| |
|
static constexpr const auto | DISTANCES_START_STR = "distances_start" |
| |
|
static constexpr const auto | DISTANCES_END_STR = "distances_end" |
| |
|
static constexpr const auto | HELP_FLAG_STR = "-h" |
| |
|
static constexpr const auto | HELP_OPTION_STR = "--help" |
| |
|
static constexpr const auto | HELP_WORD_STR = "help" |
| |
|
static constexpr const auto | VERSION_FLAG_STR = "-v" |
| |
|
static constexpr const auto | VERSION_OPTION_STR = "--version" |
| |
|
static constexpr const auto | VERSION_WORD_STR = "version" |
| |
|
static constexpr const auto | TRUE_VALUE = "true" |
| |
|
static constexpr const auto | FALSE_VALUE = "false" |
| |
Command-line argument handler with JSON support.
Uses PIMPL pattern to wrap CLI11 functionality with additional JSON support