CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ODSRPCycle.h
Go to the documentation of this file.
1 #ifndef ODSRPCYCLE_H
2 #define ODSRPCYCLE_H
3 
4 #include <stdexcept>
5 #include <iostream>
6 
8 
9 
10 
11 class ODSRPCycle : public IODConfig {
12  public:
13  friend class EcalCondDBInterface;
14  friend class ODEcalCycle;
15 
16  ODSRPCycle();
17  ~ODSRPCycle();
18 
19  inline std::string getTable() { return "ECAL_SRP_CYCLE"; }
20 
21  inline void setId(int id){m_ID=id;}
22  inline int getId()const{ return m_ID;} ;
23 
24  // Methods for user data
26  inline int getSRPConfigurationID() const{return m_srp_config_id;}
27 
28  // Operators
29  inline bool operator==(const ODSRPCycle &m) const { return ( m_ID == m.m_ID); }
30  inline bool operator!=(const ODSRPCycle &m) const { return !(*this == m); }
31 
32  private:
33  // User data
34  int m_ID;
36  void writeDB() throw(std::runtime_error);
37  void prepareWrite() throw(std::runtime_error);
38  void clear();
39  void fetchData(ODSRPCycle * result) throw(std::runtime_error);
40  void insertConfig() throw(std::runtime_error);
41 
42 
43  // Methods from IUniqueDBObject
44  int fetchID() throw(std::runtime_error);
45  void setByID(int id) throw(std::runtime_error);
46 
47 
48 };
49 
50 #endif
void prepareWrite()
Definition: ODSRPCycle.cc:26
void fetchData(ODSRPCycle *result)
Definition: ODSRPCycle.cc:131
void setByID(int id)
Definition: ODSRPCycle.cc:104
int m_srp_config_id
Definition: ODSRPCycle.h:35
bool operator!=(const ODSRPCycle &m) const
Definition: ODSRPCycle.h:30
bool operator==(const ODSRPCycle &m) const
Definition: ODSRPCycle.h:29
int getId() const
Definition: ODSRPCycle.h:22
void clear()
Definition: ODSRPCycle.cc:66
tuple result
Definition: query.py:137
std::string getTable()
Definition: ODSRPCycle.h:19
int getSRPConfigurationID() const
Definition: ODSRPCycle.h:26
int fetchID()
Definition: ODSRPCycle.cc:71
void setId(int id)
Definition: ODSRPCycle.h:21
void writeDB()
Definition: ODSRPCycle.cc:41
void setSRPConfigurationID(int x)
Definition: ODSRPCycle.h:25
x
Definition: VDTMath.h:216
void insertConfig()
Definition: ODSRPCycle.cc:158