CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
RunDCSHVDat.h
Go to the documentation of this file.
1 #ifndef RUNDCSHVEBDAT_H
2 #define RUNDCSHVEBDAT_H
3 
4 #include <vector>
5 #include <stdexcept>
6 
14 
15 class RunDCSHVDat : public IDataItem {
16  public:
18 
19  static const int maxDifference = 30*60*1000000; // 30 minutes
20  static const int maxHVDifferenceEB = 300; // max HV tolerance in mV for EB
21  static const int maxHVDifferenceEE = 5000; // max HV tolerance in mV for EE
22  static const int minHV = 10000; // if HV less than this value (in mV) HV is off
23 
24  static const int HVNOTNOMINAL = 1;
25  static const int HVOFF = 2;
26 
27  friend class EcalCondDBInterface;
28  RunDCSHVDat();
29  ~RunDCSHVDat();
30 
31  // User data methods
32  inline std::string getTable() { return ""; }
33  inline std::string getEBAccount() { return "CMS_ECAL_HV_PVSS_COND"; }
34  inline std::string getEEAccount() { return "CMS_EE_HV_PVSS_COND"; }
35  inline void setHV(float t) { m_hv = t; }
36  inline void setStatus(int t) { m_status = t; }
37  inline void setHVNominal(float t) { m_hvnom = t; }
38  inline float getHV() const { return m_hv; }
39  inline float getHVNominal() const { return m_hvnom; }
40  inline int getStatus() const { return m_status; }
41  int getTimeStatus() {return m_tstatus;}
42  void setTimeStatus(int t ) {m_tstatus=t; }
43  private:
44  void setStatusForBarrel(RunDCSHVDat&, const Tm&);
45  void setStatusForEndcaps(RunDCSHVDat&, const Tm&);
47  ResultSet* getBarrelRset(const Tm& timeStart) ;
48 
51 
52  ResultSet* getEndcapAnodeRset(const Tm& timestart);
53  ResultSet* getEndcapDynodeRset(const Tm& timestart);
54  int nowMicroseconds();
55  void fillTheMap(ResultSet *, std::map< EcalLogicID, RunDCSHVDat >* );
56  // void fillTheMapByTime(ResultSet *, std::list< std::pair< Tm, std::map< EcalLogicID, RunDCSHVDat > > >* ) ;
58 
59 
60  void prepareWrite()
61  throw(std::runtime_error);
62 
63  void writeDB(const EcalLogicID* ecid, const RunDCSHVDat* item, RunIOV* iov )
64  throw(std::runtime_error);
65 
66  void fetchData(std::map< EcalLogicID, RunDCSHVDat >* fillMap, RunIOV* iov)
67  throw(std::runtime_error);
68 
69  void fetchLastData(std::map< EcalLogicID, RunDCSHVDat >* fillMap)
70  throw(std::runtime_error);
71 
72  void fetchHistoricalData(std::list< std::pair<Tm, std::map< EcalLogicID, RunDCSHVDat > > >* fillMap, const Tm& timeStart )
73  throw(std::runtime_error);
74 
75 
76  // User data
77  float m_hv;
78  float m_hvnom;
79  int m_status;
80  int m_tstatus;
81 };
82 
83 #endif
static const int maxHVDifferenceEB
Definition: RunDCSHVDat.h:20
oracle::occi::ResultSet ResultSet
Definition: RunDCSHVDat.h:17
float getHVNominal() const
Definition: RunDCSHVDat.h:39
void setStatusForEndcaps(RunDCSHVDat &, const Tm &)
Definition: RunDCSHVDat.cc:337
ResultSet * getEndcapDynodeRset()
Definition: RunDCSHVDat.cc:187
std::string getEEAccount()
Definition: RunDCSHVDat.h:34
ResultSet * getEndcapAnodeRset()
Definition: RunDCSHVDat.cc:170
void prepareWrite()
Definition: RunDCSHVDat.cc:36
void fetchData(std::map< EcalLogicID, RunDCSHVDat > *fillMap, RunIOV *iov)
Definition: RunDCSHVDat.cc:52
float m_hv
Definition: RunDCSHVDat.h:77
ResultSet * getBarrelRset()
Definition: RunDCSHVDat.cc:153
static const int HVNOTNOMINAL
Definition: RunDCSHVDat.h:24
std::string getTable()
Definition: RunDCSHVDat.h:32
std::string getEBAccount()
Definition: RunDCSHVDat.h:33
void setStatusForBarrel(RunDCSHVDat &, const Tm &)
Definition: RunDCSHVDat.cc:315
int getStatus() const
Definition: RunDCSHVDat.h:40
tuple iov
Definition: o2o.py:307
void fetchLastData(std::map< EcalLogicID, RunDCSHVDat > *fillMap)
Definition: RunDCSHVDat.cc:355
static const int minHV
Definition: RunDCSHVDat.h:22
static const int maxHVDifferenceEE
Definition: RunDCSHVDat.h:21
float m_hvnom
Definition: RunDCSHVDat.h:78
void setTimeStatus(int t)
Definition: RunDCSHVDat.h:42
void setStatus(int t)
Definition: RunDCSHVDat.h:36
void setHVNominal(float t)
Definition: RunDCSHVDat.h:37
string const
Definition: compareJSON.py:14
oracle::occi::ResultSet ResultSet
Definition: HcalDbOmds.cc:26
static const int HVOFF
Definition: RunDCSHVDat.h:25
void fillTheMapByTime(ResultSet *rset, std::list< DataReducer< RunDCSHVDat >::MyData< RunDCSHVDat > > *my_data_list)
Definition: RunDCSHVDat.cc:244
void fillTheMap(ResultSet *, std::map< EcalLogicID, RunDCSHVDat > *)
Definition: RunDCSHVDat.cc:204
int nowMicroseconds()
Definition: RunDCSHVDat.cc:305
void writeDB(const EcalLogicID *ecid, const RunDCSHVDat *item, RunIOV *iov)
Definition: RunDCSHVDat.cc:45
void setHV(float t)
Definition: RunDCSHVDat.h:35
void fetchHistoricalData(std::list< std::pair< Tm, std::map< EcalLogicID, RunDCSHVDat > > > *fillMap, const Tm &timeStart)
Definition: RunDCSHVDat.cc:381
Definition: RunIOV.h:13
Definition: Tm.h:13
float getHV() const
Definition: RunDCSHVDat.h:38
int getTimeStatus()
Definition: RunDCSHVDat.h:41
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger list("!*","!HLTx*"if it matches 2 triggers or more) will accept the event if all the matching triggers are FAIL.It will reject the event if any of the triggers are PASS or EXCEPTION(this matches the behavior of"!*"before the partial wildcard feature was incorporated).Triggers which are in the READY state are completely ignored.(READY should never be returned since the trigger paths have been run
static const int maxDifference
Definition: RunDCSHVDat.h:19