23.05
|
Implementation of an option that accepts a single value. More...
#include <SimpleOption.h>
Public Member Functions | |
SimpleOption (std::string name, T default_value) | |
Construct the option with the given default value. More... | |
bool | parse (std::string value) override |
Parses the given string. More... | |
std::string | help () const override |
Help message for the option. More... | |
const T & | value () const |
Get the option value. More... | |
template<> | |
bool | parse (std::string value) |
Parses the given string. More... | |
![]() | |
Option (std::string name) | |
Constructor. More... | |
Option (std::string name, bool is_required, bool is_set) | |
Constructor. More... | |
virtual | ~Option ()=default |
Default destructor. More... | |
std::string | name () const |
Name of the option. More... | |
void | set_required (bool is_required) |
Set whether the option is required. More... | |
void | set_help (std::string help) |
Set the help message for the option. More... | |
bool | is_required () const |
Is the option required? More... | |
bool | is_set () const |
Has a value been assigned to the option? More... | |
Implementation of an option that accepts a single value.
Definition at line 39 of file SimpleOption.h.
|
inline |
Construct the option with the given default value.
[in] | name | Name of the option. |
[in] | default_value | Default value. |
Definition at line 76 of file SimpleOption.h.
|
inlineoverridevirtual |
Help message for the option.
Implements Option.
Definition at line 106 of file SimpleOption.h.
|
overridevirtual |
Parses the given string.
[in] | value | String representation as passed on the command line. |
Implements Option.
Definition at line 82 of file SimpleOption.h.
|
inlinevirtual |
Parses the given string.
[in] | value | String representation as passed on the command line. |
Implements Option.
Definition at line 98 of file SimpleOption.h.
|
inline |
Get the option value.
Definition at line 112 of file SimpleOption.h.
Referenced by gemm_tuner::consume_common_gemm_example_parameters(), arm_compute::utils::consume_common_graph_parameters(), CommonOptions::create_printers(), main(), arm_compute::utils::run_example(), and GraphEdsr::setup().