-bool Config::set_option(const string &opt, const string &val)
-{
- bool result = false;
-
- OptionMap::iterator i = options.find(opt);
- if(i!=options.end())
- {
- if(i->second.value!=val)
- result = true;
- i->second.value = val;
- }
-
- return result;
-}
-
-void Config::load()
-{
- FS::Path fn = package.get_source()/(".options."+get_option("profile").value);
-
- try
- {
- IO::BufferedFile in(fn.str());
-
- mtime = Time::TimeStamp::from_unixtime(FS::stat(fn).st_mtime);
-
- DataFile::Parser parser(in, fn.str());
- Loader loader(*this);
- loader.load(parser);
- }
- catch(const IO::FileNotFound &)
- { }
-}
-