CMS 3D CMS Logo

List of all members | Classes | Public Types | Public Member Functions | Private Attributes
HLTCommonConfig Class Reference

Classes

class  View
 

Public Types

enum  Index { Index::First = 0, Index::Second = 1 }
 

Public Member Functions

View const & getView (Index index) const
 
 HLTCommonConfig (HLTConfigDataEx const &first, HLTConfigDataEx const &second)
 
std::string const & moduleLabel (Index index, unsigned int trigger, unsigned int module) const
 
std::string const & moduleType (Index index, unsigned int trigger, unsigned int module) const
 
bool prescaler (Index index, unsigned int trigger, unsigned int module) const
 
std::string const & processName (Index index) const
 
unsigned int size (Index index) const
 
unsigned int size (Index index, unsigned int trigger) const
 
unsigned int triggerIndex (Index index, unsigned int trigger) const
 
std::string const & triggerName (Index index, unsigned int trigger) const
 

Private Attributes

HLTConfigDataEx const & first_
 
View firstView_
 
HLTConfigDataEx const & second_
 
View secondView_
 
std::vector< std::pair< unsigned int, unsigned int > > triggerIndices_
 

Detailed Description

Definition at line 115 of file hltDiff.cc.

Member Enumeration Documentation

◆ Index

Enumerator
First 
Second 

Definition at line 117 of file hltDiff.cc.

117 { First = 0, Second = 1 };

Constructor & Destructor Documentation

◆ HLTCommonConfig()

HLTCommonConfig::HLTCommonConfig ( HLTConfigDataEx const &  first,
HLTConfigDataEx const &  second 
)
inline

Definition at line 137 of file hltDiff.cc.

139  for (unsigned int f = 0; f < first.size(); ++f)
140  for (unsigned int s = 0; s < second.size(); ++s)
141  if (first.triggerName(f) == second.triggerName(s)) {
142  triggerIndices_.push_back(std::make_pair(f, s));
143  break;
144  }
145  }

References f, first, alignCSCRings::s, edm::second(), and triggerIndices_.

Member Function Documentation

◆ getView()

View const& HLTCommonConfig::getView ( Index  index) const
inline

Definition at line 147 of file hltDiff.cc.

147  {
148  if (index == Index::First)
149  return firstView_;
150  else
151  return secondView_;
152  }

References First, firstView_, and secondView_.

◆ moduleLabel()

std::string const& HLTCommonConfig::moduleLabel ( Index  index,
unsigned int  trigger,
unsigned int  module 
) const
inline

Definition at line 184 of file hltDiff.cc.

184  {
185  if (index == Index::First)
186  return first_.moduleLabel(triggerIndices_.at(trigger).first, module);
187  else
188  return second_.moduleLabel(triggerIndices_.at(trigger).second, module);
189  }

References First, first_, HLTConfigDataEx::moduleLabel(), second_, and triggerIndices_.

◆ moduleType()

std::string const& HLTCommonConfig::moduleType ( Index  index,
unsigned int  trigger,
unsigned int  module 
) const
inline

Definition at line 191 of file hltDiff.cc.

191  {
192  if (index == Index::First)
193  return first_.moduleType(triggerIndices_.at(trigger).first, module);
194  else
195  return second_.moduleType(triggerIndices_.at(trigger).second, module);
196  }

References First, first_, HLTConfigDataEx::moduleType(), second_, and triggerIndices_.

◆ prescaler()

bool HLTCommonConfig::prescaler ( Index  index,
unsigned int  trigger,
unsigned int  module 
) const
inline

Definition at line 198 of file hltDiff.cc.

198  {
199  if (index == Index::First)
200  return first_.prescaler(triggerIndices_.at(trigger).first, module);
201  else
202  return second_.prescaler(triggerIndices_.at(trigger).second, module);
203  }

References First, first_, HLTConfigDataEx::prescaler(), second_, and triggerIndices_.

◆ processName()

std::string const& HLTCommonConfig::processName ( Index  index) const
inline

Definition at line 154 of file hltDiff.cc.

154  {
155  if (index == Index::First)
156  return first_.processName();
157  else
158  return second_.processName();
159  }

References First, first_, HLTConfigDataEx::processName(), and second_.

Referenced by HLTCommonConfig::View::processName().

◆ size() [1/2]

unsigned int HLTCommonConfig::size ( Index  index) const
inline

Definition at line 161 of file hltDiff.cc.

161 { return triggerIndices_.size(); }

References triggerIndices_.

Referenced by ntupleDataFormat._Collection::__iter__(), and ntupleDataFormat._Collection::__len__().

◆ size() [2/2]

unsigned int HLTCommonConfig::size ( Index  index,
unsigned int  trigger 
) const
inline

Definition at line 163 of file hltDiff.cc.

163  {
164  if (index == Index::First)
165  return first_.size(trigger);
166  else
167  return second_.size(trigger);
168  }

References First, first_, second_, and HLTConfigDataEx::size().

Referenced by ntupleDataFormat._Collection::__iter__(), and ntupleDataFormat._Collection::__len__().

◆ triggerIndex()

unsigned int HLTCommonConfig::triggerIndex ( Index  index,
unsigned int  trigger 
) const
inline

Definition at line 177 of file hltDiff.cc.

177  {
178  if (index == Index::First)
179  return triggerIndices_.at(trigger).first;
180  else
181  return triggerIndices_.at(trigger).second;
182  }

References First, and triggerIndices_.

◆ triggerName()

std::string const& HLTCommonConfig::triggerName ( Index  index,
unsigned int  trigger 
) const
inline

Definition at line 170 of file hltDiff.cc.

170  {
171  if (index == Index::First)
172  return first_.triggerName(triggerIndices_.at(trigger).first);
173  else
174  return second_.triggerName(triggerIndices_.at(trigger).second);
175  }

References First, first_, second_, triggerIndices_, and HLTConfigDataEx::triggerName().

Member Data Documentation

◆ first_

HLTConfigDataEx const& HLTCommonConfig::first_
private

Definition at line 206 of file hltDiff.cc.

Referenced by moduleLabel(), moduleType(), prescaler(), processName(), size(), and triggerName().

◆ firstView_

View HLTCommonConfig::firstView_
private

Definition at line 209 of file hltDiff.cc.

Referenced by getView().

◆ second_

HLTConfigDataEx const& HLTCommonConfig::second_
private

Definition at line 207 of file hltDiff.cc.

Referenced by moduleLabel(), moduleType(), prescaler(), processName(), size(), and triggerName().

◆ secondView_

View HLTCommonConfig::secondView_
private

Definition at line 210 of file hltDiff.cc.

Referenced by getView().

◆ triggerIndices_

std::vector<std::pair<unsigned int, unsigned int> > HLTCommonConfig::triggerIndices_
private
HLTConfigDataEx::processName
std::string const & processName() const override
Definition: hltDiff.cc:82
f
double f[11][100]
Definition: MuScleFitUtils.cc:78
HLTConfigDataEx::moduleType
std::string const & moduleType(unsigned int trigger, unsigned int module) const override
Definition: hltDiff.cc:98
HLTConfigDataEx::moduleLabel
std::string const & moduleLabel(unsigned int trigger, unsigned int module) const override
Definition: hltDiff.cc:94
edm::second
U second(std::pair< T, U > const &p)
Definition: ParameterSet.cc:222
HLTConfigDataEx::triggerName
std::string const & triggerName(unsigned int trigger) const override
Definition: hltDiff.cc:90
HLTConfigDataEx::prescaler
bool prescaler(unsigned int trigger, unsigned int module) const override
Definition: hltDiff.cc:102
alignCSCRings.s
s
Definition: alignCSCRings.py:92
HLTCommonConfig::triggerIndices_
std::vector< std::pair< unsigned int, unsigned int > > triggerIndices_
Definition: hltDiff.cc:212
first
auto first
Definition: CAHitNtupletGeneratorKernelsImpl.h:112
HLTCommonConfig::second_
HLTConfigDataEx const & second_
Definition: hltDiff.cc:207
HLTCommonConfig::secondView_
View secondView_
Definition: hltDiff.cc:210
HLTConfigDataEx::size
unsigned int size() const override
Definition: hltDiff.cc:84
HLTCommonConfig::firstView_
View firstView_
Definition: hltDiff.cc:209
HLTCommonConfig::Index::Second
HLTCommonConfig::first_
HLTConfigDataEx const & first_
Definition: hltDiff.cc:206
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
trigger
Definition: HLTPrescaleTableCond.h:8
HLTCommonConfig::Index::First