CMS 3D CMS Logo

List of all members | Public Member Functions | Protected Member Functions
CandMatcher< C1, C2 > Class Template Reference

#include <CandMatcher.h>

Inheritance diagram for CandMatcher< C1, C2 >:
CandMatcherBase< C1, C2 >

Public Member Functions

 CandMatcher (const typename CandMatcherBase< C1, C2 >::map_type &map)
 constructor More...
 
 CandMatcher (const typename CandMatcherBase< C1, C2 >::map_vector &maps)
 constructor More...
 
virtual ~CandMatcher ()
 destructor More...
 
- Public Member Functions inherited from CandMatcherBase< C1, C2 >
 CandMatcherBase (const map_type &map)
 constructor More...
 
 CandMatcherBase (const map_vector &maps)
 constructor More...
 
ref_type operator() (const reco::Candidate &) const
 get match from transient reference More...
 
virtual ~CandMatcherBase ()
 destructor More...
 

Protected Member Functions

virtual bool compositePreselect (const reco::Candidate &c, const reco::Candidate &m) const
 composite candidate preselection More...
 
virtual std::vector< const reco::Candidate * > getDaughters (const reco::Candidate *) const
 get ultimate daughter (get all in the general case) More...
 
- Protected Member Functions inherited from CandMatcherBase< C1, C2 >
void initMaps ()
 init maps More...
 
const std::vector< const map_type * > & maps () const
 

Additional Inherited Members

- Public Types inherited from CandMatcherBase< C1, C2 >
typedef reco::helper::CandMapTrait< C1, C2 >::type map_type
 map type More...
 
typedef std::vector< const map_type * > map_vector
 map vector More...
 
typedef reco::helper::CandRefTrait< C2 >::ref_type ref_type
 ref type More...
 
typedef map_type::key_type reference_type
 concrete candidate reference type More...
 
typedef reco::helper::CandRefTrait< C2 >::refProd_type refProd_type
 refProd type More...
 
typedef reference_type::value_type value_type
 concrete candidate reference type More...
 

Detailed Description

template<typename C1, typename C2 = C1>
class CandMatcher< C1, C2 >

Definition at line 69 of file CandMatcher.h.

Constructor & Destructor Documentation

◆ CandMatcher() [1/2]

template<typename C1 , typename C2 >
CandMatcher< C1, C2 >::CandMatcher ( const typename CandMatcherBase< C1, C2 >::map_vector maps)
explicit

constructor

Definition at line 211 of file CandMatcher.h.

References CandMatcherBase< C1, C2 >::initMaps().

◆ CandMatcher() [2/2]

template<typename C1 , typename C2 >
CandMatcher< C1, C2 >::CandMatcher ( const typename CandMatcherBase< C1, C2 >::map_type map)
explicit

constructor

Definition at line 217 of file CandMatcher.h.

References CandMatcherBase< C1, C2 >::initMaps().

◆ ~CandMatcher()

template<typename C1 , typename C2 >
CandMatcher< C1, C2 >::~CandMatcher ( )
virtual

destructor

Definition at line 223 of file CandMatcher.h.

223  {
224 }

Member Function Documentation

◆ compositePreselect()

template<typename C1 , typename C2 >
bool CandMatcher< C1, C2 >::compositePreselect ( const reco::Candidate c,
const reco::Candidate m 
) const
protectedvirtual

composite candidate preselection

Implements CandMatcherBase< C1, C2 >.

Definition at line 234 of file CandMatcher.h.

234  {
235  // By default, check that the number of daughters is identical
236  return( c.numberOfDaughters() == m.numberOfDaughters() );
237 }

References c, and visualization-live-secondInstance_cfg::m.

◆ getDaughters()

template<typename C1 , typename C2 >
std::vector< const reco::Candidate * > CandMatcher< C1, C2 >::getDaughters ( const reco::Candidate c) const
protectedvirtual

get ultimate daughter (get all in the general case)

Implements CandMatcherBase< C1, C2 >.

Definition at line 227 of file CandMatcher.h.

227  {
228  std::vector<const reco::Candidate *> v;
229  v.push_back( c );
230  return v;
231 }

References c, and findQualityFiles::v.

CandMatcherBase::maps
const std::vector< const map_type * > & maps() const
Definition: CandMatcher.h:48
findQualityFiles.v
v
Definition: findQualityFiles.py:179
visualization-live-secondInstance_cfg.m
m
Definition: visualization-live-secondInstance_cfg.py:78
CandMatcherBase
Definition: CandMatcher.h:16
genParticles_cff.map
map
Definition: genParticles_cff.py:11
c
auto & c
Definition: CAHitNtupletGeneratorKernelsImpl.h:56
CandMatcherBase::initMaps
void initMaps()
init maps
Definition: CandMatcher.h:114