CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
egHLT::EgDiEleUserCut< Key > Struct Template Reference

#include <EgHLTDQMCut.h>

Inheritance diagram for egHLT::EgDiEleUserCut< Key >:
egHLT::EgHLTDQMCut< OffEle >

Public Member Functions

EgHLTDQMCut< OffEle > * clone () const override
 
 EgDiEleUserCut (int(OffEle::*cutCodeFunc)(const Key &) const, const Key &key, int cutsNotToMask=~0x0)
 
bool pass (const OffEle &obj, const OffEvt &evt) const override
 
 ~EgDiEleUserCut () override=default
 
- Public Member Functions inherited from egHLT::EgHLTDQMCut< OffEle >
 EgHLTDQMCut ()=default
 
virtual ~EgHLTDQMCut ()=default
 

Private Attributes

int(OffEle::* cutCodeFunc_ )(const Key &) const
 
int cutsNotToMask_
 
const Keykey_
 

Additional Inherited Members

- Protected Member Functions inherited from egHLT::EgHLTDQMCut< OffEle >
 EgHLTDQMCut (const EgHLTDQMCut &rhs)=default
 

Detailed Description

template<class Key>
struct egHLT::EgDiEleUserCut< Key >

Definition at line 403 of file EgHLTDQMCut.h.

Constructor & Destructor Documentation

◆ EgDiEleUserCut()

template<class Key>
egHLT::EgDiEleUserCut< Key >::EgDiEleUserCut ( int(OffEle::*)(const Key &) const  cutCodeFunc,
const Key key,
int  cutsNotToMask = ~0x0 
)
inline

Definition at line 410 of file EgHLTDQMCut.h.

411  : cutCodeFunc_(cutCodeFunc), key_(key), cutsNotToMask_(cutsNotToMask) {}

Referenced by egHLT::EgDiEleUserCut< Key >::clone().

◆ ~EgDiEleUserCut()

template<class Key>
egHLT::EgDiEleUserCut< Key >::~EgDiEleUserCut ( )
overridedefault

Member Function Documentation

◆ clone()

template<class Key>
EgHLTDQMCut<OffEle>* egHLT::EgDiEleUserCut< Key >::clone ( void  ) const
inlineoverridevirtual

Implements egHLT::EgHLTDQMCut< OffEle >.

Definition at line 415 of file EgHLTDQMCut.h.

415  {
416  return new EgDiEleUserCut(*this);
417  } //default copy constructor is fine

References egHLT::EgDiEleUserCut< Key >::EgDiEleUserCut().

◆ pass()

template<class Key >
bool egHLT::EgDiEleUserCut< Key >::pass ( const OffEle obj,
const OffEvt evt 
) const
overridevirtual

Implements egHLT::EgHLTDQMCut< OffEle >.

Definition at line 421 of file EgHLTDQMCut.h.

421  {
422  const std::vector<OffEle>& eles = evt.eles();
423  for (const auto& ele : eles) {
424  if (&ele != &obj) { //different electrons
425  int diEleCutCode = (obj.*cutCodeFunc_)(key_) | (ele.*cutCodeFunc_)(key_);
426  if ((diEleCutCode & cutsNotToMask_) == 0x0)
427  return true;
428  }
429  }
430  return false;
431  }

References hltEgammaEleL1TrkIsoL1Seeded_cfi::eles, egHLT::OffEvt::eles(), and getGTfromDQMFile::obj.

Member Data Documentation

◆ cutCodeFunc_

template<class Key>
int(OffEle::* egHLT::EgDiEleUserCut< Key >::cutCodeFunc_) (const Key &) const
private

Definition at line 405 of file EgHLTDQMCut.h.

◆ cutsNotToMask_

template<class Key>
int egHLT::EgDiEleUserCut< Key >::cutsNotToMask_
private

Definition at line 407 of file EgHLTDQMCut.h.

◆ key_

template<class Key>
const Key& egHLT::EgDiEleUserCut< Key >::key_
private

Definition at line 406 of file EgHLTDQMCut.h.

egHLT::EgDiEleUserCut::key_
const Key & key_
Definition: EgHLTDQMCut.h:406
hltEgammaEleL1TrkIsoL1Seeded_cfi.eles
eles
Definition: hltEgammaEleL1TrkIsoL1Seeded_cfi.py:5
getGTfromDQMFile.obj
obj
Definition: getGTfromDQMFile.py:32
egHLT::EgDiEleUserCut::cutCodeFunc_
int(OffEle::* cutCodeFunc_)(const Key &) const
Definition: EgHLTDQMCut.h:405
egHLT::EgDiEleUserCut::cutsNotToMask_
int cutsNotToMask_
Definition: EgHLTDQMCut.h:407
egHLT::EgDiEleUserCut::EgDiEleUserCut
EgDiEleUserCut(int(OffEle::*cutCodeFunc)(const Key &) const, const Key &key, int cutsNotToMask=~0x0)
Definition: EgHLTDQMCut.h:410
crabWrapper.key
key
Definition: crabWrapper.py:19