CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HLTConfigProvider.h
Go to the documentation of this file.
1 #ifndef HLTcore_HLTConfigProvider_h
2 #define HLTcore_HLTConfigProvider_h
3 
17 
20 
21 #include "boost/shared_ptr.hpp"
22 
23 #include<map>
24 #include<string>
25 #include<vector>
26 
27 
28 //
29 // class declaration
30 //
31 
33 
34  private:
35  public:
39  // ~HLTConfigProvider();
40 
41  public:
45  bool init(const edm::Run& iRun, const edm::EventSetup& iSetup,
46  const std::string& processName, bool& changed);
47 
49  void dump(const std::string& what) const {
50  hltConfigData_->dump(what);
51  }
52 
54 
56  bool inited() const {
57  return inited_;
58  }
60  bool changed() const {
61  return changed_;
62  }
63 
65  const std::string& processName() const {
66  return hltConfigData_->processName();
67  }
68 
70  const std::string& globalTag() const {
71  return hltConfigData_->globalTag();
72  }
73 
75  const std::string& tableName() const {
76  return hltConfigData_->tableName();
77  }
78 
80  unsigned int size() const {
81  return hltConfigData_->size();
82  }
84  unsigned int size(unsigned int trigger) const {
85  return hltConfigData_->size(trigger);
86  }
87  unsigned int size(const std::string& trigger) const {
88  return hltConfigData_->size(trigger);
89  }
90 
92  const std::vector<std::string>& triggerNames() const {
93  return hltConfigData_->triggerNames();
94  }
95  const std::string& triggerName(unsigned int triggerIndex) const {
96  return hltConfigData_->triggerName(triggerIndex);
97  }
98 
100  unsigned int triggerIndex(const std::string& triggerName) const {
101  return hltConfigData_->triggerIndex(triggerName);
102  }
103 
105  const std::vector<std::string>& moduleLabels(unsigned int trigger) const {
106  return hltConfigData_->moduleLabels(trigger);
107  }
108  const std::vector<std::string>& moduleLabels(const std::string& trigger) const {
109  return hltConfigData_->moduleLabels(trigger);
110  }
111  const std::vector<std::string>& saveTagsModules(unsigned int trigger) const {
112  return hltConfigData_->saveTagsModules(trigger);
113  }
114  const std::vector<std::string>& saveTagsModules(const std::string& trigger) const {
115  return hltConfigData_->saveTagsModules(trigger);
116  }
117  const std::string& moduleLabel(unsigned int trigger, unsigned int module) const {
118  return hltConfigData_->moduleLabel(trigger,module);
119  }
120  const std::string& moduleLabel(const std::string& trigger, unsigned int module) const {
121  return hltConfigData_->moduleLabel(trigger,module);
122  }
123 
125  unsigned int moduleIndex(unsigned int trigger, const std::string& module) const {
126  return hltConfigData_->moduleIndex(trigger,module);
127  }
128  unsigned int moduleIndex(const std::string& trigger, const std::string& module) const {
129  return hltConfigData_->moduleIndex(trigger,module);
130  }
131 
133  const std::string moduleType(const std::string& module) const {
134  return hltConfigData_->moduleType(module);
135  }
136 
139  return hltConfigData_->moduleEDMType(module);
140  }
141 
144  return hltConfigData_->processPSet();
145  }
146 
149  return hltConfigData_->modulePSet(module);
150  }
151 
153  bool saveTags(const std::string& module) const {
154  return hltConfigData_->saveTags(module);
155  }
156 
159  const std::vector<std::vector<std::pair<bool,std::string> > >& hltL1GTSeeds() const {
160  return hltConfigData_->hltL1GTSeeds();
161  }
163  const std::vector<std::pair<bool,std::string> >& hltL1GTSeeds(const std::string& trigger) const {
164  return hltConfigData_->hltL1GTSeeds(trigger);
165  }
167  const std::vector<std::pair<bool,std::string> >& hltL1GTSeeds(unsigned int trigger) const {
168  return hltConfigData_->hltL1GTSeeds(trigger);
169  }
170 
171 
174  const std::vector<std::string>& streamNames() const {
175  return hltConfigData_->streamNames();
176  }
178  const std::string& streamName(unsigned int stream) const {
179  return hltConfigData_->streamName(stream);
180  }
182  unsigned int streamIndex(const std::string& stream) const {
183  return hltConfigData_->streamIndex(stream);
184  }
186  const std::vector<std::vector<std::string> >& streamContents() const {
187  return hltConfigData_->streamContents();
188  }
190  const std::vector<std::string>& streamContent(unsigned int stream) const {
191  return hltConfigData_->streamContent(stream);
192  }
194  const std::vector<std::string>& streamContent(const std::string& stream) const {
195  return hltConfigData_->streamContent(stream);
196  }
197 
198 
201  const std::vector<std::string>& datasetNames() const {
202  return hltConfigData_->datasetNames();
203  }
205  const std::string& datasetName(unsigned int dataset) const {
206  return hltConfigData_->datasetName(dataset);
207  }
209  unsigned int datasetIndex(const std::string& dataset) const {
210  return hltConfigData_->datasetIndex(dataset);
211  }
213  const std::vector<std::vector<std::string> >& datasetContents() const {
215  }
217  const std::vector<std::string>& datasetContent(unsigned int dataset) const {
218  return hltConfigData_->datasetContent(dataset);
219  }
221  const std::vector<std::string>& datasetContent(const std::string& dataset) const {
222  return hltConfigData_->datasetContent(dataset);
223  }
224 
225 
228  unsigned int prescaleSize() const {
229  return hltConfigData_->prescaleSize();
230  }
232  unsigned int prescaleValue(unsigned int set, const std::string& trigger) const {
233  return hltConfigData_->prescaleValue(set,trigger);
234  }
235 
238  int prescaleSet(const edm::Event& iEvent, const edm::EventSetup& iSetup) const;
239  // negative == error
240 
242  unsigned int prescaleValue(const edm::Event& iEvent, const edm::EventSetup& iSetup, const std::string& trigger) const;
243 
245  std::pair<int,int> prescaleValues(const edm::Event& iEvent, const edm::EventSetup& iSetup, const std::string& trigger) const;
246  // any one negative => error in retrieving this (L1T or HLT) prescale
247 
248  // In case of a complex Boolean expression as L1 seed
249  std::pair<std::vector<std::pair<std::string,int> >,int> prescaleValuesInDetail(const edm::Event& iEvent, const edm::EventSetup& iSetup, const std::string& trigger) const;
250 
252  const std::vector<std::string>& prescaleLabels() const {
253  return hltConfigData_->prescaleLabels();
254  }
255  const std::map<std::string,std::vector<unsigned int> >& prescaleTable() const {
256  return hltConfigData_->prescaleTable();
257  }
258 
260  static const std::vector<std::string> matched(const std::vector<std::string>& inputs, const std::string& pattern);
261  static const std::string removeVersion(const std::string& trigger);
262  static const std::vector<std::string> restoreVersion(const std::vector<std::string>& inputs, const std::string& trigger);
263 
264  private:
265 
266  void getDataFrom(const edm::ParameterSetID& iID);
267  void init(const edm::ProcessHistory& iHistory, const std::string& processName);
268  void init(const std::string& processName);
269  void clear();
270 
273  bool inited_;
274  bool changed_;
276  boost::shared_ptr<L1GtUtils> l1GtUtils_;
277 
278 };
279 #endif
unsigned int size() const
number of trigger paths in trigger table
void dump(const std::string &what) const
Dumping config info to cout.
bool saveTags(const std::string &module) const
Is module an L3 filter (ie, tracked saveTags=true)
unsigned int moduleIndex(const std::string &trigger, const std::string &module) const
const std::string moduleType(const std::string &module) const
C++ class name of module.
static const std::vector< std::string > matched(const std::vector< std::string > &inputs, const std::string &pattern)
regexp processing
const std::vector< std::vector< std::string > > & streamContents() const
names of datasets for all streams
const std::string & datasetName(unsigned int dataset) const
name of dataset with index i
const std::string & triggerName(unsigned int triggerIndex) const
const std::vector< std::string > & datasetContent(const std::string &dataset) const
names of trigger paths in dataset with name
const std::string & streamName(unsigned int stream) const
name of stream with index i
void getDataFrom(const edm::ParameterSetID &iID)
const std::vector< std::pair< bool, std::string > > & hltL1GTSeeds(const std::string &trigger) const
HLTLevel1GTSeed modules for trigger path with name.
const std::vector< std::vector< std::pair< bool, std::string > > > & hltL1GTSeeds() const
const std::vector< std::string > & triggerNames() const
names of trigger paths
const std::vector< std::string > & triggerNames() const
names of trigger paths
const std::vector< std::vector< std::pair< bool, std::string > > > & hltL1GTSeeds() const
const std::string & datasetName(unsigned int dataset) const
name of dataset with index i
bool saveTags(const std::string &module) const
Is module an L3 filter (ie, tracked saveTags=true)
std::pair< std::vector< std::pair< std::string, int > >, int > prescaleValuesInDetail(const edm::Event &iEvent, const edm::EventSetup &iSetup, const std::string &trigger) const
const std::string moduleEDMType(const std::string &module) const
C++ base class name of module.
const edm::ParameterSet & modulePSet(const std::string &module) const
ParameterSet of module.
list pattern
Definition: chain.py:104
unsigned int size() const
number of trigger paths in trigger table
unsigned int prescaleValue(unsigned int set, const std::string &trigger) const
HLT prescale value in specific prescale set for a specific trigger path.
const std::string & tableName() const
HLT ConfDB table name.
unsigned int size(const std::string &trigger) const
const edm::ParameterSet & modulePSet(const std::string &module) const
ParameterSet of module.
std::string processName_
data members
unsigned int streamIndex(const std::string &stream) const
index of stream with name
const std::vector< std::string > & datasetNames() const
Datasets.
const std::map< std::string, std::vector< unsigned int > > & prescaleTable() const
bool changed() const
changed?
const std::string & moduleLabel(unsigned int trigger, unsigned int module) const
static const std::string removeVersion(const std::string &trigger)
bool inited() const
Accessors (const methods)
const HLTConfigData * hltConfigData_
const std::vector< std::string > & saveTagsModules(unsigned int trigger) const
unsigned int triggerIndex(const std::string &triggerName) const
slot position of trigger path in trigger table (0 to size-1)
const std::vector< std::string > & streamNames() const
Streams.
boost::shared_ptr< L1GtUtils > l1GtUtils_
unsigned int prescaleValue(unsigned int set, const std::string &trigger) const
HLT prescale value in specific prescale set for a specific trigger path.
int iEvent
Definition: GenABIO.cc:230
const std::vector< std::string > & datasetContent(unsigned int dataset) const
names of trigger paths in dataset with index i
unsigned int moduleIndex(unsigned int trigger, const std::string &module) const
slot position of module on trigger path (0 to size-1)
const std::vector< std::string > & streamNames() const
const edm::ParameterSet & processPSet() const
ParameterSet of process.
const std::string & moduleLabel(const std::string &trigger, unsigned int module) const
const std::vector< std::string > & saveTagsModules(unsigned int trigger) const
const std::vector< std::string > & streamContent(unsigned int stream) const
names of datasets in stream with index i
const std::vector< std::vector< std::string > > & datasetContents() const
names of trigger paths for all datasets
const std::vector< std::string > & moduleLabels(unsigned int trigger) const
label(s) of module(s) on a trigger path
const std::string moduleType(const std::string &module) const
C++ class name of module.
const std::vector< std::string > & saveTagsModules(const std::string &trigger) const
unsigned int triggerIndex(const std::string &triggerName) const
slot position of trigger path in trigger table (0 - size-1)
HLTConfigProvider()
c&#39;tor
unsigned int moduleIndex(unsigned int trigger, const std::string &module) const
slot position of module on trigger path (0 - size-1)
const std::string & processName() const
process name
const std::string & processName() const
Accessors (const methods)
const std::vector< std::string > & moduleLabels(unsigned int trigger) const
label(s) of module(s) on a trigger path
unsigned int streamIndex(const std::string &stream) const
index of stream with name
const std::vector< std::string > & datasetContent(unsigned int dataset) const
names of trigger paths in dataset with index i
const std::string & tableName() const
HLT ConfDB table name.
const std::map< std::string, std::vector< unsigned int > > & prescaleTable() const
const std::vector< std::pair< bool, std::string > > & hltL1GTSeeds(unsigned int trigger) const
HLTLevel1GTSeed modules for trigger path with index i.
int prescaleSet(const edm::Event &iEvent, const edm::EventSetup &iSetup) const
const edm::ParameterSet & processPSet() const
ParameterSet of process.
static const std::vector< std::string > restoreVersion(const std::vector< std::string > &inputs, const std::string &trigger)
bool init(const edm::Run &iRun, const edm::EventSetup &iSetup, const std::string &processName, bool &changed)
d&#39;tor
unsigned int size(unsigned int trigger) const
number of modules on a specific trigger path
tuple dataset
Definition: dataset.py:787
std::pair< int, int > prescaleValues(const edm::Event &iEvent, const edm::EventSetup &iSetup, const std::string &trigger) const
Combined L1T (pair.first) and HLT (pair.second) prescales per HLT path.
unsigned int prescaleSize() const
const std::vector< std::string > & prescaleLabels() const
low-level data member access
const std::string moduleEDMType(const std::string &module) const
C++ base class name of module.
unsigned int datasetIndex(const std::string &dataset) const
index of dataset with name
const std::string & globalTag() const
GlobalTag.globaltag.
const std::vector< std::vector< std::string > > & datasetContents() const
names of trigger paths for all datasets
unsigned int datasetIndex(const std::string &dataset) const
index of dataset with name
const std::vector< std::string > & prescaleLabels() const
low-level data member access
const std::string & streamName(unsigned int stream) const
name of stream with index i
const std::vector< std::string > & streamContent(const std::string &stream) const
names of datasets in stream with name
unsigned int prescaleSize() const
const std::vector< std::vector< std::string > > & streamContents() const
names of datasets for all streams
const std::string & moduleLabel(unsigned int trigger, unsigned int module) const
const std::string & triggerName(unsigned int triggerIndex) const
const std::vector< std::string > & streamContent(unsigned int stream) const
names of datasets in stream with index i
Definition: vlib.h:208
const std::vector< std::string > & moduleLabels(const std::string &trigger) const
void dump(const std::string &what) const
Dumping config info to cout.
Definition: Run.h:41
const std::vector< std::string > & datasetNames() const
const std::string & globalTag() const
global tag