开发者

Reload option values in boost::program_options from new source

I'm just starting to dig into boost::program_options for the first time. I like it quite a bit. However, what I'm trying to accompl开发者_Python百科ish with it doesn't seem to be something its designers have accounted for.

I want to use boost::program_options to parse both command line options as well as config files. So far so good. Additionally, though, I would like to be able to check for updated settings (say from a new config file) that could override the previously parsed settings in my variables_map.

Granted, I could do a separate parse and try to merge the two maps. Perhaps that's what I'll end up doing. I'm just wondering, though, if anyone has done anything like this before and has come up with a slick solution.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜