FACT++  1.0
void SetupConfiguration ( Configuration conf)

Definition at line 27 of file chatclient.cc.

References Configuration::AddEnv(), Configuration::AddOptions(), and Configuration::GetName().

Referenced by main().

28 {
29  const string n = conf.GetName()+".log";
30 
31  po::options_description config("Program options");
32  config.add_options()
33  ("dns", var<string>("localhost"), "Dim nameserver (overwites DIM_DNS_NODE environment variable)")
34  ("host", var<string>(""), "Address with which the Dim nameserver can connect to this host (overwites DIM_HOST_NODE environment variable)")
35  ("log,l", var<string>(n), "Write log-file")
36  ("console,c", var<int>(0), "Use console (0=shell, 1=simple buffered, X=simple unbuffered)")
37  ;
38 
39  conf.AddEnv("dns", "DIM_DNS_NODE");
40  conf.AddEnv("host", "DIM_HOST_NODE");
41 
42  conf.AddOptions(config);
43 }
void AddEnv(const std::string &conf, const std::string &env)
void AddOptions(const po::options_description &opt, bool visible=true)
Definition: Configuration.h:92
const std::string & GetName() const

+ Here is the call graph for this function:

+ Here is the caller graph for this function: