CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
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 beginEvent(edm::Event const&, edm::EventSetup const&, bool const&, bool&) override;
21 
22  bool analyze(void const*, Collections) override;
23 
24  void runOnSource(FEDRawDataCollection const&);
26 
27  enum Constants { nEventTypes = 25 };
28 
29  private:
30  edm::RunNumber_t runNumber_; // run number needed regardless of single-/multi-thread operation
31  int l1A_;
32  int orbit_;
33  int bx_;
34  short triggerType_;
36  };
37 
38  inline bool RawDataTask::analyze(void const* _p, Collections _collection) {
39  switch (_collection) {
40  case kSource:
41  if (_p)
42  runOnSource(*static_cast<FEDRawDataCollection const*>(_p));
43  return true;
44  break;
45  case kEcalRawData:
46  if (_p)
47  runOnRawData(*static_cast<EcalRawDataCollection const*>(_p));
48  return true;
49  break;
50  default:
51  break;
52  }
53  return false;
54  }
55 
56 } // namespace ecaldqm
57 
58 #endif
~RawDataTask() override
Definition: RawDataTask.h:15
void runOnRawData(EcalRawDataCollection const &)
Definition: RawDataTask.cc:66
void beginEvent(edm::Event const &, edm::EventSetup const &, bool const &, bool &) override
Definition: RawDataTask.cc:24
void addDependencies(DependencySet &) override
Definition: RawDataTask.cc:18
bool analyze(void const *, Collections) override
Definition: RawDataTask.h:38
edm::RunNumber_t runNumber_
Definition: RawDataTask.h:30
void beginRun(edm::Run const &, edm::EventSetup const &) override
Definition: RawDataTask.cc:22
void runOnSource(FEDRawDataCollection const &)
Definition: RawDataTask.cc:45
unsigned int RunNumber_t
Definition: Run.h:45