
Stefan, it depends on how far you are ready to go ;) What you request is possible, but that will not work (AFAIK) from the scratch. What you need is custom handling of the options parsed. namespace po = boost::program_options; template<class CharT> void handle_parsed_option(po::basic_option<CharT> const& parsed_option) { //parse it } //program options are used to properly parse values // so all options parsed are valid po::options_description options("Option Parser"); options.add_options() ("*", po::value<int>(), "dummy placeholder") ; po::parsed_options const& opts = po::parse_config_file(input, options); ::std::for_each(opts.options.begin(), opts.options.end(), &handle_parsed_option<char>); Hope that helps. Best Regards, Ovanes On Fri, Apr 18, 2008 at 10:53 AM, Stefan Walk <walk@mis.tu-darmstadt.de> wrote:
Hi,
is there a general description of the config file syntax that program_options uses available? Like if it's case-sensitive, if you can quote arguments, etc ... currently i'm wondering if I can fill a vector from one line, like val = foo bar baz with foo, bar, and baz as the values ... is this possible with some separator?
Regards, Stefan
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users