CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
DTHVStatusHandler.h
Go to the documentation of this file.
1 #ifndef DTHVStatusHandler_H
2 #define DTHVStatusHandler_H
3 
14 //----------------------
15 // Base Class Headers --
16 //----------------------
18 
19 //------------------------------------
20 // Collaborating Class Declarations --
21 //------------------------------------
25 #include <string>
26 
27 namespace coral {
28  class TimeStamp;
29 }
31 
32 //---------------
33 // C++ Headers --
34 //---------------
35 
36 
37 // ---------------------
38 // -- Class Interface --
39 // ---------------------
40 
42 
43  public:
44 
48 
51  virtual ~DTHVStatusHandler();
52 
55  void getNewObjects();
57  std::string id() const;
58 
59  private:
60 
62  typedef std::pair<int,float> channelValue;
63 
64  void checkNewData();
65 
66  void getChannelMap();
67  void getLayerSplit();
68  void getChannelSplit();
69  void dumpHVAliases();
70 
71  void createSnapshot();
72  int recoverSnapshot();
74  void dumpSnapshot( const coral::TimeStamp& time );
75  void updateHVStatus();
76  int checkForPeriod( cond::Time_t condSince,
77  cond::Time_t condUntil,
78  int& missingChannels,
79  bool copyOffline );
80 
81  void copyHVData();
83  void getLayerValues( int rawId, int type,
84  float& valueL, float& valueR,
85  float& valueS, float& valueC );
86  void setChannelFlag( DTHVStatus* hv,
87  int whe, int sta, int sec, int qua, int lay, int l_p,
89 
90  int checkStatusChange( int type, float oldValue, float newValue );
91  void filterData();
92 
93  static DTWireId layerId( int rawId, int l_p );
94  static coral::TimeStamp coralTime( const cond::Time_t& time );
95  static cond::Time_t condTime( const coral::TimeStamp& time );
96  static cond::Time_t condTime( long long int time );
97 
98  std::string dataTag;
99  std::string onlineConnect;
100  std::string utilConnect;
101  std::string onlineAuthentication;
102  std::string bufferConnect;
104 
105  int ySince;
106  int mSince;
107  int dSince;
108  int hSince;
109  int pSince;
110  int sSince;
111  int yUntil;
112  int mUntil;
113  int dUntil;
114  int hUntil;
115  int pUntil;
116  int sUntil;
118  bool dumpAtEnd;
119  long long int bwdTime;
120  long long int fwdTime;
121  long long int minTime;
122 
123  std::map<int,timedMeasurement> snapshotValues;
125 
131  long long int lastStamp;
133 
140 
141  std::string mapVersion;
142  std::string splitVersion;
143  std::map<int,int> aliasMap;
144  std::map<int,int> layerMap;
145  std::map<int,int> laySplit;
146  std::map< int, std::vector<int>* > channelSplit;
147  std::vector< std::pair<DTHVStatus*, cond::Time_t> > tmpContainer;
148  bool switchOff;
149 
150 };
151 
152 
153 #endif // DTHVStatusHandler_H
154 
155 
156 
157 
158 
159 
std::string id() const
type
Definition: HCALResponse.h:22
long int flag
Definition: mlp_lapack.h:47
DTHVStatus * lastStatus
long long int lastStamp
std::map< int, int > aliasMap
DTHVAbstractCheck::timedMeasurement timedMeasurement
cond::Time_t lastFound
long long int minTime
cond::Time_t procUntil
void getLayerValues(int rawId, int type, float &valueL, float &valueR, float &valueS, float &valueC)
std::string onlineConnect
cond::DbSession buff_session
static DTWireId layerId(int rawId, int l_p)
std::map< int, std::vector< int > * > channelSplit
DTHVStatusHandler(const edm::ParameterSet &ps)
DTHVStatus * offlineList()
std::vector< std::pair< DTHVStatus *, cond::Time_t > > tmpContainer
cond::Time_t recoverLastTime()
cond::DbConnection buff_conn
static coral::TimeStamp coralTime(const cond::Time_t &time)
int checkStatusChange(int type, float oldValue, float newValue)
cond::Time_t nextFound
std::map< int, int > laySplit
unsigned long long Time_t
Definition: Time.h:16
cond::Time_t procSince
long long int fwdTime
std::pair< long long int, float > timedMeasurement
check HV status
void dumpSnapshot(const coral::TimeStamp &time)
static cond::Time_t condTime(const coral::TimeStamp &time)
std::map< int, timedMeasurement > snapshotValues
std::map< int, int > layerMap
int checkForPeriod(cond::Time_t condSince, cond::Time_t condUntil, int &missingChannels, bool copyOffline)
void setChannelFlag(DTHVStatus *hv, int whe, int sta, int sec, int qua, int lay, int l_p, const DTHVAbstractCheck::flag &flag)
cond::DbConnection util_conn
long long int bwdTime
std::string onlineAuthentication
cond::DbSession util_session
std::pair< int, float > channelValue
cond::DbSession omds_session
DTHVAbstractCheck * hvChecker
std::string bufferConnect
virtual ~DTHVStatusHandler()
cond::Time_t timeLimit
cond::DbConnection omds_conn
std::string splitVersion