WIP: Rewrite ConfigManager
This is merging the ConfigManager
and ConfigReader
classes as their interplay has been unnecessary complicated and e.g. did not allow to change the global configuration once it was set.
The parsing of CLI arguments is now done by a separate class, OptionParser
which makes it a bit more obvious that these aren't directly applied to the configs but have to be manually added later by calling applyOptions()
. Having this in the ConfigManager
always confused me.
Furthermore, this implements changes which fix #112 (closed) and add the version number as well as all global configuration parameters to the data files written by the ROOTObjectWriter
.
Open points:
- currently, the global section is always stores as empty section name, and I manually add it back in the
ROOTObjectWriter
when writing out - not really nice and might also be a problem for other output writers using this. We could name it in theConfigManager
class? Opinions? - the different members
getConfigurations()
andgetAllConfigurations()
are a bit confusing right now, but somehow necessary because sometimes the global configuration is requires and sometimes not. Ideas to improve?
Please comment/review.