CMS 3D CMS Logo

ODTTCciConfig.h
Go to the documentation of this file.
1 #ifndef ODTTCCICONFIG_H
2 #define ODTTCCICONFIG_H
3 
4 #include <map>
5 #include <stdexcept>
8 #define USE_NORM 1
9 #define USE_CHUN 2
10 #define USE_BUFF 3
11 
12 /* Buffer Size */
13 #define BUFSIZE 200;
14 
15 class ODTTCciConfig : public IODConfig {
16 public:
17  friend class EcalCondDBInterface;
18  ODTTCciConfig();
19  ~ODTTCciConfig() override;
20 
21  // User data methods
22  inline std::string getTable() override { return "ECAL_TTCci_CONFIGURATION"; }
23 
24  inline void setId(int id) { m_ID = id; }
25  inline int getId() const { return m_ID; }
26 
29 
34 
35  inline void setTrgMode(std::string x) { m_trg_mode = x; }
36  inline std::string getTrgMode() const { return m_trg_mode; }
37  inline void setTrgSleep(int id) { m_trg_sleep = id; }
38  inline int getTrgSleep() const { return m_trg_sleep; }
39 
40  inline void setTTCciClob(unsigned char* x) { m_ttcci_clob = x; }
41  inline unsigned char* getTTCciClob() const { return m_ttcci_clob; }
42  inline void setSize(unsigned int id) { m_size = id; }
43  inline unsigned int getSize() const { return m_size; }
44  void setParameters(const std::map<std::string, std::string>& my_keys_map);
45 
46 private:
47  void prepareWrite() noexcept(false) override;
48  void writeDB() noexcept(false);
49  void clear();
50  void fetchData(ODTTCciConfig* result) noexcept(false);
51  int fetchID() noexcept(false);
52 
53  int fetchNextId() noexcept(false);
54 
55  // User data
56  int m_ID;
57  unsigned char* m_ttcci_clob;
58  std::string m_ttcci_file;
61  std::string m_trg_mode;
63  int m_size;
64 };
65 
66 #endif
std::string getTTCciConfigurationFile() const
Definition: ODTTCciConfig.h:28
unsigned char * m_ttcci_clob
Definition: ODTTCciConfig.h:57
void setConfigurationScript(std::string x)
Definition: ODTTCciConfig.h:30
unsigned int getSize() const
Definition: ODTTCciConfig.h:43
~ODTTCciConfig() override
std::string getConfigurationScriptParams() const
Definition: ODTTCciConfig.h:33
int getTrgSleep() const
Definition: ODTTCciConfig.h:38
void setTTCciClob(unsigned char *x)
Definition: ODTTCciConfig.h:40
std::string getConfigurationScript() const
Definition: ODTTCciConfig.h:31
std::string getTable() override
Definition: ODTTCciConfig.h:22
void fetchData(ODTTCciConfig *result) noexcept(false)
void setParameters(const std::map< std::string, std::string > &my_keys_map)
std::string m_configuration_script
Definition: ODTTCciConfig.h:59
void setId(int id)
Definition: ODTTCciConfig.h:24
void writeDB() noexcept(false)
void setTTCciConfigurationFile(std::string x)
Definition: ODTTCciConfig.h:27
void setSize(unsigned int id)
Definition: ODTTCciConfig.h:42
int fetchID() noexcept(false)
void prepareWrite() noexcept(false) override
std::string m_ttcci_file
Definition: ODTTCciConfig.h:58
void setTrgMode(std::string x)
Definition: ODTTCciConfig.h:35
void setConfigurationScriptParams(std::string x)
Definition: ODTTCciConfig.h:32
std::string getTrgMode() const
Definition: ODTTCciConfig.h:36
std::string m_trg_mode
Definition: ODTTCciConfig.h:61
void setTrgSleep(int id)
Definition: ODTTCciConfig.h:37
int fetchNextId() noexcept(false)
std::string m_configuration_script_params
Definition: ODTTCciConfig.h:60
unsigned char * getTTCciClob() const
Definition: ODTTCciConfig.h:41
int getId() const
Definition: ODTTCciConfig.h:25