25 #ifndef UQ_BOOST_INPUT_OPTIONS_H
26 #define UQ_BOOST_INPUT_OPTIONS_H
29 #include <queso/ScopedPtr.h>
30 #include <queso/BaseInputOptionsParser.h>
34 namespace program_options
36 class options_description;
76 void registerOption(std::string name, T defaultValue, std::string description);
83 void getOption(std::string & name, T & value);
86 friend std::ostream &
operator<<(std::ostream & os,
92 typename ScopedPtr<boost::program_options::variables_map>::Type
m_optionsMap;
100 #endif // UQ_BOOST_INPUT_OPTIONS_H
virtual ~BoostInputOptionsParser()
Destructor.
ScopedPtr< boost::program_options::variables_map >::Type m_optionsMap
friend std::ostream & operator<<(std::ostream &os, const BoostInputOptionsParser &parser)
Helpful stream operator for printing the parser state.
void scanInputFile()
This is the method that parses the input file.
const std::string & m_filename
void registerOption(std::string name, T defaultValue, std::string description)
Call this to register an option with the parser.
ScopedPtr< boost::program_options::options_description >::Type m_optionsDescription
BoostInputOptionsParser()
Default constructor that sets m_filename to "".
void getOption(std::string &name, T &value)
Get option name from the parser and set value to the parsed value.