Hi,
This is a feature request for the program_options library.
A clean and extensible design for my code
stipulates that it will be best to pass the user input (command line / config file)
around to different modules which then extract the relevant options using the
program_options library. This will mean neglecting all options that are
irrelevant to the current module. However, it appears that this is possible
only from the command line and not from the config file.
Ideally, it will be great if the api for parsing config files mirrors what exists for the command line. That would mean a basic_config_file_parser class with chainable allow_unregistered() and collect_unrecognized() methods for the
config file parsing.
Some searching shows that there have been a
couple of similar requests on this list:
http://thread.gmane.org/gmane.comp.lib.boost.user/25035
http://thread.gmane.org/gmane.comp.lib.boost.user/24398
and on the developers' list:
http://thread.gmane.org/gmane.comp.lib.boost.devel/150415
http://thread.gmane.org/gmane.comp.lib.boost.devel/86380
It also appears that a issue ticket was opened on sourceforge: http://thread.gmane.org/gmane.comp.lib.boost.devel/145941
Thanks
RamV