popt_options.h
Go to the documentation of this file.00001
00049 #ifndef POPT_OPTIONS_H
00050 #define POPT_OPTIONS_H
00051
00052 #include <string>
00053 #include <vector>
00054
00055 namespace popt {
00056
00068 void parse_options(int argc, char const ** argv,
00069 std::vector<std::string> & additional_params);
00070
00071 class option_base;
00072
00079 class option {
00080 public:
00086 template <class T> option(T &, char const * option_name,
00087 char short_name, char const * help_str,
00088 char const * arg_help_str);
00089
00098 option(bool &, char const * option_name,
00099 char short_name, char const * help_str);
00100
00101 ~option();
00102
00103 private:
00104 option_base * the_option;
00105 };
00106
00107
00112 template <> option::option(int &, char const * option_name, char short_name,
00113 char const * help_str, char const * arg_help_str);
00114 template <> option::option(std::string &, char const * option_name,
00115 char short_name, char const * help_str,
00116 char const * arg_help_str);
00117 template <> option::option(std::vector<std::string> &,
00118 char const * option_name, char short_name,
00119 char const * help_str, char const * arg_help_str);
00120
00121 }
00122
00123 #endif // POPT_OPTIONS_H