Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members

ManagerConfig.h

Go to the documentation of this file.
00001 // -*- C++ -*-
00019 /*
00020  * $Log: ManagerConfig.h,v $
00021  * Revision 1.4  2007/04/13 18:02:28  n-ando
00022  * Some configuration properties handling processes were changed.
00023  *
00024  * Revision 1.3  2006/11/06 01:26:28  n-ando
00025  * Some trivial fixes.
00026  *
00027  * Revision 1.2  2006/10/23 08:38:23  n-ando
00028  * To get Property after "init()" calling, getConfig() was added.
00029  *
00030  * Revision 1.1  2006/10/17 10:21:38  n-ando
00031  * The first commitment.
00032  *
00033  *
00034  */
00035 
00036 
00037 #ifndef ManagerConfig_h
00038 #define ManagerConfig_h
00039 
00040 #include <rtm/Properties.h>
00041 
00042 
00043 namespace RTC
00044 {
00045 
00046   
00079   class ManagerConfig
00080   {
00081   public:
00082     // The list of default configuration file path.
00083     static const char* config_file_path[];
00084     
00085     // Environment value to specify configuration file
00086     static const char* config_file_env;
00087 
00088 
00104     ManagerConfig();
00105 
00106 
00129     ManagerConfig(int argc, char** argv);
00130 
00131 
00143     virtual ~ManagerConfig();
00144     
00145 
00171     //    void init();
00172 
00173 
00174 
00202     void init(int argc, char** argv);
00203 
00204 
00212     void configure(Properties& prop);
00213 
00214 
00236     Properties getConfig() const;
00237 
00238   protected:
00260     void parseArgs(int argc, char** argv);
00261     
00262     
00282     bool findConfigFile();
00283 
00284     
00312     void setSystemInformation(Properties& prop);
00313 
00314 
00322     bool fileExist(const std::string& filename);
00323 
00324     std::string m_configFile;
00325   };
00326   
00327 }; // namespace RTC  
00328   
00329   
00330 #endif // ManagerConfig_h
00331   

Generated on Fri Oct 5 05:15:59 2007 for OpenRTM by  doxygen 1.4.1