CMS 3D CMS Logo

RawDataTask.h
Go to the documentation of this file.
1 #ifndef RawDataTask_H
2 #define RawDataTask_H
3 
4 #include "DQWorkerTask.h"
5 
8 
10 
11 namespace ecaldqm {
12  class RawDataTask : public DQWorkerTask {
13  public:
14  RawDataTask();
15  ~RawDataTask() override {}
16 
17  void addDependencies(DependencySet&) override;
18 
19  void beginRun(edm::Run const&, edm::EventSetup const&) override;
20  void beginLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) override;
21  void beginEvent(edm::Event const&, edm::EventSetup const&) override;
22 
23  bool analyze(void const*, Collections) override;
24 
25  void runOnSource(FEDRawDataCollection const&);
27 
28  enum Constants { nEventTypes = 25 };
29 
30  private:
31  edm::RunNumber_t runNumber_; // run number needed regardless of single-/multi-thread operation
32  int l1A_;
33  int orbit_;
34  int bx_;
35  short triggerType_;
37  };
38 
39  inline bool RawDataTask::analyze(void const* _p, Collections _collection) {
40  switch (_collection) {
41  case kSource:
42  if (_p)
43  runOnSource(*static_cast<FEDRawDataCollection const*>(_p));
44  return true;
45  break;
46  case kEcalRawData:
47  if (_p)
48  runOnRawData(*static_cast<EcalRawDataCollection const*>(_p));
49  return true;
50  break;
51  default:
52  break;
53  }
54  return false;
55  }
56 
57 } // namespace ecaldqm
58 
59 #endif
~RawDataTask() override
Definition: RawDataTask.h:15
void runOnRawData(EcalRawDataCollection const &)
Definition: RawDataTask.cc:59
void addDependencies(DependencySet &) override
Definition: RawDataTask.cc:17
bool analyze(void const *, Collections) override
Definition: RawDataTask.h:39
edm::RunNumber_t runNumber_
Definition: RawDataTask.h:31
void beginRun(edm::Run const &, edm::EventSetup const &) override
Definition: RawDataTask.cc:21
void runOnSource(FEDRawDataCollection const &)
Definition: RawDataTask.cc:38
void beginEvent(edm::Event const &, edm::EventSetup const &) override
Definition: RawDataTask.cc:30
unsigned int RunNumber_t
void beginLuminosityBlock(edm::LuminosityBlock const &, edm::EventSetup const &) override
Definition: RawDataTask.cc:23
Definition: Run.h:45