CMS 3D CMS Logo

/data/git/CMSSW_5_3_11_patch5/src/OnlineDB/EcalCondDB/interface/ODCond2ConfInfo.h

Go to the documentation of this file.
00001 #ifndef ODCOND2CONFINFO_H
00002 #define ODCOND2CONFINFO_H
00003 
00004 #include <map>
00005 #include <string>
00006 
00007 #include "OnlineDB/EcalCondDB/interface/IODConfig.h"
00008 #include "OnlineDB/EcalCondDB/interface/Tm.h"
00009 
00010 typedef int run_t;
00011 
00012 class ODCond2ConfInfo : public IODConfig {
00013  public:
00014   friend class EcalCondDBInterface;
00015   ODCond2ConfInfo();
00016   ~ODCond2ConfInfo();
00017 
00018   // User data methods
00019   inline std::string getTable() { return "COND_2_CONF_INFO"; }
00020 
00021   inline void setId(int id) { m_ID = id; }
00022   inline int getId() const { return m_ID; }
00023 
00024   inline void setType(std::string x) { m_type = x; }
00025   inline std::string getType() const { return m_type; }
00026 
00027   inline void setRecordDate(Tm x) { m_rec_time = x; }
00028   inline Tm getRecordDate() const { return m_rec_time; }
00029 
00030   inline void setLocation(std::string x) { m_loc = x; }
00031   inline std::string getLocation() const { return m_loc; }
00032 
00033   inline void setRunNumber(int id) { m_run = id; }
00034   inline int getRunNumber() const { return m_run; }
00035 
00036   inline void setDescription(std::string x) { m_desc = x; }
00037   inline std::string getDescription() const { return m_desc ; }
00038 
00039   inline void setDBDate(Tm x) { m_db_time = x; }
00040   inline Tm getDBDate() const { return m_db_time; }
00041 
00042   // the tag is already in IODConfig 
00043 
00044   int fetchID()  throw(std::runtime_error);
00045 
00046   int fetchNextId() throw(std::runtime_error);
00047   void setParameters(std::map<std::string,std::string> my_keys_map);
00048   
00049  private:
00050   void prepareWrite()  throw(std::runtime_error);
00051 
00052   void writeDB()       throw(std::runtime_error);
00053 
00054   void clear();
00055 
00056   void fetchData(ODCond2ConfInfo * result)     throw(std::runtime_error);
00057 
00058   void fetchParents()  throw(std::runtime_error) ;
00059 
00060 
00061   // User data
00062   int m_ID;
00063   std::string m_type;
00064   Tm m_rec_time;
00065   std::string m_loc;
00066   int m_run;
00067   std::string m_desc;
00068   Tm m_db_time;
00069   int m_loc_id;
00070   int m_typ_id;
00071 
00072 
00073 };
00074 
00075 #endif