CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
DQWorkerClient.h
Go to the documentation of this file.
1 #ifndef DQWorkerClient_H
2 #define DQWorkerClient_H
3 
4 #include <utility>
5 
7 
8 class DetId;
9 
10 namespace ecaldqm
11 {
12  class StatusManager;
13 
14  class DQWorkerClient : public DQWorker {
15  public:
16  enum ProcessType {
20  };
21 
23  virtual ~DQWorkerClient() {}
24 
26 
27  void endLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) override;
28 
29  void bookMEs(DQMStore::IBooker&) override;
30  void releaseMEs() override;
31 
32  void releaseSource();
34 
35  bool runsOn(ProcessType _type) const { return _type == kJob || hasLumiPlots_; }
36  void resetMEs();
37  virtual void producePlots(ProcessType) = 0;
38 
39  void setStatusManager(StatusManager const& _manager) { statusManager_ = &_manager; }
40 
41  enum Quality {
42  kBad = 0,
43  kGood = 1,
44  kUnknown = 2,
45  kMBad = 3,
46  kMGood = 4,
48  };
49 
50  protected:
51  void setME(edm::ParameterSet const& _ps) final { DQWorker::setME(_ps); }
52  void setSource(edm::ParameterSet const&) override;
53 
54  bool using_(std::string const& _name, ProcessType _type = kJob) const
55  {
56  MESetCollection::const_iterator itr(sources_.find(_name));
57  if(itr == sources_.end()) return false;
58  if(_type == kJob) return true;
59  else return itr->second->getLumiFlag();
60  }
61 
62  void towerAverage_(MESet&, MESet const&, float);
63 
65  std::set<std::string> qualitySummaries_;
66 
68 
70  };
71 }
72 #endif
void towerAverage_(MESet &, MESet const &, float)
void setStatusManager(StatusManager const &_manager)
bool using_(std::string const &_name, ProcessType _type=kJob) const
bool retrieveSource(DQMStore::IGetter &, ProcessType)
virtual void producePlots(ProcessType)=0
std::set< std::string > qualitySummaries_
static void fillDescriptions(edm::ParameterSetDescription &)
StatusManager const * statusManager_
boost::ptr_map< std::string, MESet > MESetCollection
Definition: MESet.h:326
MESetCollection sources_
Definition: DetId.h:18
virtual void setME(edm::ParameterSet const &)
Definition: DQWorker.cc:56
void releaseMEs() override
bool runsOn(ProcessType _type) const
void setSource(edm::ParameterSet const &) override
void bookMEs(DQMStore::IBooker &) override
void endLuminosityBlock(edm::LuminosityBlock const &, edm::EventSetup const &) override
void setME(edm::ParameterSet const &_ps) final