chrono::ChCLI Class Reference

Description

Wrapper for cxxopts.

#include <ChCLI.h>

Public Member Functions

 ChCLI (const std::string &program, const std::string &help_string=" - command line options")
 Constructor.
 
 ~ChCLI ()
 Destructor.
 
bool Parse (int argc, char **argv, bool show_help=false, bool count_help=true)
 Parse messages and display help message, if needed.
 
void Help ()
 Print the help menu.
 
bool CheckHelp ()
 Check if help was passed.
 
bool CheckOption (const std::string &option)
 Check if the specified option was passed.
 
template<typename T >
bool HasValueInVector (const std::string &option, T value)
 Check for value in vector.
 
template<typename T = bool>
void AddOption (const std::string &group, const std::string &opts, const std::string &desc, const std::string &def, const std::string &arg_help)
 
template<typename T = bool>
void AddOption (const std::string &group, const std::string &opts, const std::string &desc, const std::string &def)
 
template<typename T = bool>
void AddOption (const std::string &group, const std::string &opts, const std::string &desc)
 
void AddOption (const std::string &group, cxxopts::Option option)
 
const cxxopts::OptionValue & Get (const std::string &option)
 
template<typename T >
const T GetAsType (const std::string &option)
 Get option as type Recommanded way of accessing.
 
template<typename T >
const bool Matches (const T &option, const T &value)
 

The documentation for this class was generated from the following file:
  • /builds/uwsbel/chrono/src/chrono_thirdparty/cxxopts/ChCLI.h