CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PrescaleService.h
Go to the documentation of this file.
1 #ifndef FWCore_PrescaleService_PrescaleService_h
2 #define FWCore_PrescaleService_PrescaleService_h
3 
4 
7 
8 
9 #include <string>
10 #include <vector>
11 #include <map>
12 
13 
14 namespace edm {
15  class ActivityRegistry;
16  class Event;
17  class EventID;
18  class EventSetup;
19  class Timestamp;
21  class ModuleDescription;
22 
23  namespace service {
24 
26  {
27  public:
28  //
29  // construction/destruction
30  //
33 
34 
35  //
36  // member functions
37  //
38 
39  void reconfigure(ParameterSet const& ps);
40 
41  unsigned int getPrescale(unsigned int lvl1Index,
42  std::string const& prescaledPath);
43  unsigned int getPrescale(std::string const& prescaledPath);
44 
45  void setIndex(unsigned int lvl1Index){iLvl1IndexDefault_ = lvl1Index;}
46  void postBeginJob();
47  void postEndJob() {}
48  void preEventProcessing(EventID const&, Timestamp const&) {}
49  void postEventProcessing(Event const&, EventSetup const&) {}
50  void preModule(ModuleDescription const&) {}
51  void postModule(ModuleDescription const&) {}
52 
53  typedef std::vector<std::string> VString_t;
54  typedef std::map<std::string, std::vector<unsigned int> > PrescaleTable_t;
55  unsigned int getLvl1IndexDefault() const {return iLvl1IndexDefault_;}
56  const VString_t& getLvl1Labels() const {return lvl1Labels_;}
58 
59  static void fillDescriptions(edm::ConfigurationDescriptions & descriptions);
60 
61  private:
62  //
63  // private member functions
64  //
65  void configure();
66 
67  //
68  // member data
69  //
70 
73  unsigned int nLvl1Index_;
74  unsigned int iLvl1IndexDefault_;
75  std::vector<ParameterSet> vpsetPrescales_;
77  };
78  }
79 }
80 
81 #endif
std::vector< ParameterSet > vpsetPrescales_
void setIndex(unsigned int lvl1Index)
unsigned int getLvl1IndexDefault() const
const PrescaleTable_t & getPrescaleTable() const
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
void reconfigure(ParameterSet const &ps)
std::map< std::string, std::vector< unsigned int > > PrescaleTable_t
void preEventProcessing(EventID const &, Timestamp const &)
void postModule(ModuleDescription const &)
PrescaleService(ParameterSet const &, ActivityRegistry &)
const VString_t & getLvl1Labels() const
void postEventProcessing(Event const &, EventSetup const &)
std::vector< std::string > VString_t
void preModule(ModuleDescription const &)
unsigned int getPrescale(unsigned int lvl1Index, std::string const &prescaledPath)