00001 #ifndef EDG_WORKLOAD_COMMON_CONFIGURATION_CONFBASE_H
00002 #define EDG_WORKLOAD_COMMON_CONFIGURATION_CONFBASE_H
00003
00004 #include <vector>
00005 #include <string>
00006
00007 #include "edg/workload/common/common_namespace.h"
00008
00009 namespace classad { class ClassAd; }
00010
00011 COMMON_NAMESPACE_BEGIN {
00012
00013 namespace configuration {
00014
00015 class confbase_c {
00016 public:
00017 virtual ~confbase_c( void );
00018
00019 inline const classad::ClassAd *get_classad( void ) const
00020 { return this->cb_ad; }
00021
00022 protected:
00023 confbase_c( const classad::ClassAd *ad );
00024
00025 bool getBool( const char *name, bool def ) const;
00026 int getInt( const char *name, int def ) const;
00027 double getDouble( const char *name, double def ) const;
00028 std::string getString( const char *name, const std::string &def ) const;
00029 std::string getAndParseString( const char *name, const std::string &def ) const;
00030 std::string getAndParseFileName( const char *name, const std::string &def ) const;
00031 std::vector<std::string> getVector( const char *name ) const;
00032
00033 const classad::ClassAd *cb_ad;
00034
00035 private:
00036 confbase_c( const confbase_c &cb );
00037 confbase_c &operator=( const confbase_c &cb );
00038 };
00039
00040 };
00041
00042 } COMMON_NAMESPACE_END;
00043
00044 #endif
00045
00046
00047
00048