CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Private Types | Private Member Functions | Private Attributes
NamedCandCombinerBase Class Referenceabstract

#include <NamedCandCombinerBase.h>

Inheritance diagram for NamedCandCombinerBase:
NamedCandCombiner< Selector, PairSelector, Cloner, Setup > NamedCandCombiner< Selector, PairSelector, Cloner, Setup >

Public Types

typedef std::vector< std::string > string_coll
 
typedef std::vector< std::string > string_coll
 

Public Member Functions

std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const std::vector< reco::CandidatePtrVector > &, string_coll const &) const
 return all selected candidate pairs More...
 
std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const std::vector< reco::CandidatePtrVector > &, string_coll const &) const
 return all selected candidate pairs More...
 
std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const reco::CandidatePtrVector &, string_coll const &) const
 return all selected candidate pairs More...
 
std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const reco::CandidatePtrVector &, string_coll const &) const
 return all selected candidate pairs More...
 
std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, string_coll const &) const
 return all selected candidate pairs More...
 
std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, string_coll const &) const
 return all selected candidate pairs More...
 
std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, string_coll const &) const
 return all selected candidate pairs More...
 
std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, string_coll const &) const
 return all selected candidate pairs More...
 
std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, string_coll const &) const
 return all selected candidate pairs More...
 
std::auto_ptr
< reco::NamedCompositeCandidateCollection
combine (const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, const reco::CandidatePtrVector &, string_coll const &) const
 return all selected candidate pairs More...
 
 NamedCandCombinerBase (std::string name)
 default construct More...
 
 NamedCandCombinerBase (std::string name)
 default construct More...
 
 NamedCandCombinerBase (std::string name, int, int)
 construct from two charge values More...
 
 NamedCandCombinerBase (std::string name, int, int)
 construct from two charge values More...
 
 NamedCandCombinerBase (std::string name, int, int, int)
 construct from three charge values More...
 
 NamedCandCombinerBase (std::string name, int, int, int)
 construct from three charge values More...
 
 NamedCandCombinerBase (std::string name, int, int, int, int)
 construct from four charge values More...
 
 NamedCandCombinerBase (std::string name, int, int, int, int)
 construct from four charge values More...
 
 NamedCandCombinerBase (std::string name, bool checkCharge, const std::vector< int > &)
 constructor from a selector, specifying optionally to check for charge More...
 
 NamedCandCombinerBase (std::string name, bool checkCharge, bool checkOverlap, const std::vector< int > &)
 constructor from a selector, specifying optionally to check for charge More...
 
virtual ~NamedCandCombinerBase ()
 destructor More...
 
virtual ~NamedCandCombinerBase ()
 destructor More...
 

Private Types

typedef std::vector< std::pair
< std::pair
< reco::CandidatePtr, size_t >
, std::vector
< reco::CandidatePtrVector >
::const_iterator > > 
CandStack
 temporary candidate stack More...
 
typedef std::vector< std::pair
< std::pair
< reco::CandidatePtr, size_t >
, std::vector
< reco::CandidatePtrVector >
::const_iterator > > 
CandStack
 temporary candidate stack More...
 
typedef std::vector< int > ChargeStack
 
typedef std::vector< int > ChargeStack
 

Private Member Functions

virtual void addDaughter (reco::NamedCompositeCandidate &cmp, const reco::CandidatePtr &c, std::string name) const =0
 add candidate daughter More...
 
virtual void addDaughter (reco::NamedCompositeCandidate &cmp, const reco::CandidatePtr &c, std::string name) const =0
 add candidate daughter More...
 
void combine (reco::NamedCompositeCandidate &, const reco::CandidatePtr &, const reco::CandidatePtr &, std::string, std::string) const
 returns a composite candidate combined from two daughters More...
 
void combine (reco::NamedCompositeCandidate &, const reco::CandidatePtr &, const reco::CandidatePtr &, std::string, std::string) const
 returns a composite candidate combined from two daughters More...
 
void combine (size_t collectionIndex, CandStack &, ChargeStack &, string_coll const &names, std::vector< reco::CandidatePtrVector >::const_iterator begin, std::vector< reco::CandidatePtrVector >::const_iterator end, std::auto_ptr< reco::NamedCompositeCandidateCollection > &comps) const
 returns a composite candidate combined from two daughters More...
 
void combine (size_t collectionIndex, CandStack &, ChargeStack &, string_coll const &names, std::vector< reco::CandidatePtrVector >::const_iterator begin, std::vector< reco::CandidatePtrVector >::const_iterator end, std::auto_ptr< reco::NamedCompositeCandidateCollection > &comps) const
 returns a composite candidate combined from two daughters More...
 
bool preselect (const reco::Candidate &, const reco::Candidate &) const
 verify that the two candidate don't overlap and check charge More...
 
bool preselect (const reco::Candidate &, const reco::Candidate &) const
 verify that the two candidate don't overlap and check charge More...
 
virtual bool select (const reco::Candidate &) const =0
 select a candidate More...
 
virtual bool select (const reco::Candidate &) const =0
 select a candidate More...
 
virtual bool selectPair (const reco::Candidate &c1, const reco::Candidate &c2) const =0
 select a candidate pair More...
 
virtual bool selectPair (const reco::Candidate &c1, const reco::Candidate &c2) const =0
 select a candidate pair More...
 
virtual void setup (reco::NamedCompositeCandidate &) const =0
 set kinematics to reconstructed composite More...
 
virtual void setup (reco::NamedCompositeCandidate &) const =0
 set kinematics to reconstructed composite More...
 

Private Attributes

bool checkCharge_
 flag to specify the checking of electric charge More...
 
bool checkOverlap_
 flag to specify the checking of overlaps More...
 
std::vector< int > dauCharge_
 electric charges of the daughters More...
 
std::string name_
 Name. More...
 
OverlapChecker overlap_
 utility to check candidate daughters overlap More...
 

Detailed Description

Definition at line 13 of file NamedCandCombinerBase.h.

Member Typedef Documentation

typedef std::vector<std::pair<std::pair<reco::CandidatePtr, size_t>, std::vector<reco::CandidatePtrVector>::const_iterator> > NamedCandCombinerBase::CandStack
private

temporary candidate stack

Definition at line 65 of file NamedCandCombinerBase.h.

typedef std::vector<std::pair<std::pair<reco::CandidatePtr, size_t>, std::vector<reco::CandidatePtrVector>::const_iterator> > NamedCandCombinerBase::CandStack
private

temporary candidate stack

Definition at line 65 of file NamedCandCombinerBase.h.

typedef std::vector<int> NamedCandCombinerBase::ChargeStack
private

Definition at line 66 of file NamedCandCombinerBase.h.

typedef std::vector<int> NamedCandCombinerBase::ChargeStack
private

Definition at line 66 of file NamedCandCombinerBase.h.

typedef std::vector<std::string> NamedCandCombinerBase::string_coll

Definition at line 15 of file NamedCandCombinerBase.h.

typedef std::vector<std::string> NamedCandCombinerBase::string_coll

Definition at line 15 of file NamedCandCombinerBase.h.

Constructor & Destructor Documentation

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name)

default construct

Definition at line 6 of file NamedCandCombinerBase.cc.

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name,
int  q1,
int  q2 
)

construct from two charge values

Definition at line 10 of file NamedCandCombinerBase.cc.

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name,
int  q1,
int  q2,
int  q3 
)

construct from three charge values

Definition at line 16 of file NamedCandCombinerBase.cc.

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name,
int  q1,
int  q2,
int  q3,
int  q4 
)

construct from four charge values

Definition at line 23 of file NamedCandCombinerBase.cc.

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name,
bool  checkCharge,
bool  checkOverlap,
const std::vector< int > &  dauCharge 
)

constructor from a selector, specifying optionally to check for charge

Definition at line 31 of file NamedCandCombinerBase.cc.

NamedCandCombinerBase::~NamedCandCombinerBase ( )
virtual

destructor

Definition at line 35 of file NamedCandCombinerBase.cc.

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name)

default construct

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name,
int  ,
int   
)

construct from two charge values

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name,
int  ,
int  ,
int   
)

construct from three charge values

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name,
int  ,
int  ,
int  ,
int   
)

construct from four charge values

NamedCandCombinerBase::NamedCandCombinerBase ( std::string  name,
bool  checkCharge,
const std::vector< int > &  dauCharge 
)

constructor from a selector, specifying optionally to check for charge

Definition at line 31 of file NamedCandCombinerBase.cc.

virtual NamedCandCombinerBase::~NamedCandCombinerBase ( )
virtual

destructor

Member Function Documentation

virtual void NamedCandCombinerBase::addDaughter ( reco::NamedCompositeCandidate cmp,
const reco::CandidatePtr c,
std::string  name 
) const
privatepure virtual
virtual void NamedCandCombinerBase::addDaughter ( reco::NamedCompositeCandidate cmp,
const reco::CandidatePtr c,
std::string  name 
) const
privatepure virtual
auto_ptr< NamedCompositeCandidateCollection > NamedCandCombinerBase::combine ( const std::vector< reco::CandidatePtrVector > &  src,
string_coll const &  names 
) const

return all selected candidate pairs

Definition at line 56 of file NamedCandCombinerBase.cc.

std::auto_ptr<reco::NamedCompositeCandidateCollection> NamedCandCombinerBase::combine ( const std::vector< reco::CandidatePtrVector > &  ,
string_coll const &   
) const

return all selected candidate pairs

auto_ptr< NamedCompositeCandidateCollection > NamedCandCombinerBase::combine ( const reco::CandidatePtrVector src,
string_coll const &  names 
) const

return all selected candidate pairs

Definition at line 110 of file NamedCandCombinerBase.cc.

std::auto_ptr<reco::NamedCompositeCandidateCollection> NamedCandCombinerBase::combine ( const reco::CandidatePtrVector ,
string_coll const &   
) const

return all selected candidate pairs

auto_ptr< NamedCompositeCandidateCollection > NamedCandCombinerBase::combine ( const reco::CandidatePtrVector src1,
const reco::CandidatePtrVector src2,
string_coll const &  names 
) const

return all selected candidate pairs

Definition at line 139 of file NamedCandCombinerBase.cc.

std::auto_ptr<reco::NamedCompositeCandidateCollection> NamedCandCombinerBase::combine ( const reco::CandidatePtrVector ,
const reco::CandidatePtrVector ,
string_coll const &   
) const

return all selected candidate pairs

auto_ptr< NamedCompositeCandidateCollection > NamedCandCombinerBase::combine ( const reco::CandidatePtrVector src1,
const reco::CandidatePtrVector src2,
const reco::CandidatePtrVector src3,
string_coll const &  names 
) const

return all selected candidate pairs

Definition at line 147 of file NamedCandCombinerBase.cc.

std::auto_ptr<reco::NamedCompositeCandidateCollection> NamedCandCombinerBase::combine ( const reco::CandidatePtrVector ,
const reco::CandidatePtrVector ,
const reco::CandidatePtrVector ,
string_coll const &   
) const

return all selected candidate pairs

std::auto_ptr<reco::NamedCompositeCandidateCollection> NamedCandCombinerBase::combine ( const reco::CandidatePtrVector ,
const reco::CandidatePtrVector ,
const reco::CandidatePtrVector ,
const reco::CandidatePtrVector ,
string_coll const &   
) const

return all selected candidate pairs

auto_ptr< NamedCompositeCandidateCollection > NamedCandCombinerBase::combine ( const reco::CandidatePtrVector src1,
const reco::CandidatePtrVector src2,
const reco::CandidatePtrVector src3,
const reco::CandidatePtrVector src4,
string_coll const &  names 
) const

return all selected candidate pairs

Definition at line 157 of file NamedCandCombinerBase.cc.

void NamedCandCombinerBase::combine ( reco::NamedCompositeCandidate ,
const reco::CandidatePtr ,
const reco::CandidatePtr ,
std::string  ,
std::string   
) const
private

returns a composite candidate combined from two daughters

void NamedCandCombinerBase::combine ( reco::NamedCompositeCandidate cmp,
const reco::CandidatePtr c1,
const reco::CandidatePtr c2,
std::string  n1,
std::string  n2 
) const
private

returns a composite candidate combined from two daughters

Definition at line 48 of file NamedCandCombinerBase.cc.

void NamedCandCombinerBase::combine ( size_t  collectionIndex,
CandStack ,
ChargeStack ,
string_coll const &  names,
std::vector< reco::CandidatePtrVector >::const_iterator  begin,
std::vector< reco::CandidatePtrVector >::const_iterator  end,
std::auto_ptr< reco::NamedCompositeCandidateCollection > &  comps 
) const
private

returns a composite candidate combined from two daughters

void NamedCandCombinerBase::combine ( size_t  collectionIndex,
CandStack ,
ChargeStack ,
string_coll const &  names,
std::vector< reco::CandidatePtrVector >::const_iterator  begin,
std::vector< reco::CandidatePtrVector >::const_iterator  end,
std::auto_ptr< reco::NamedCompositeCandidateCollection > &  comps 
) const
private

returns a composite candidate combined from two daughters

bool NamedCandCombinerBase::preselect ( const reco::Candidate c1,
const reco::Candidate c2 
) const
private

verify that the two candidate don't overlap and check charge

Definition at line 38 of file NamedCandCombinerBase.cc.

bool NamedCandCombinerBase::preselect ( const reco::Candidate ,
const reco::Candidate  
) const
private

verify that the two candidate don't overlap and check charge

virtual bool NamedCandCombinerBase::select ( const reco::Candidate ) const
privatepure virtual
virtual bool NamedCandCombinerBase::select ( const reco::Candidate ) const
privatepure virtual
virtual bool NamedCandCombinerBase::selectPair ( const reco::Candidate c1,
const reco::Candidate c2 
) const
privatepure virtual
virtual bool NamedCandCombinerBase::selectPair ( const reco::Candidate c1,
const reco::Candidate c2 
) const
privatepure virtual
virtual void NamedCandCombinerBase::setup ( reco::NamedCompositeCandidate ) const
privatepure virtual
virtual void NamedCandCombinerBase::setup ( reco::NamedCompositeCandidate ) const
privatepure virtual

Member Data Documentation

bool NamedCandCombinerBase::checkCharge_
private

flag to specify the checking of electric charge

Definition at line 83 of file NamedCandCombinerBase.h.

bool NamedCandCombinerBase::checkOverlap_
private

flag to specify the checking of overlaps

Definition at line 85 of file NamedCandCombinerBase.h.

std::vector< int > NamedCandCombinerBase::dauCharge_
private

electric charges of the daughters

Definition at line 87 of file NamedCandCombinerBase.h.

std::string NamedCandCombinerBase::name_
private

Name.

Definition at line 91 of file NamedCandCombinerBase.h.

OverlapChecker NamedCandCombinerBase::overlap_
private

utility to check candidate daughters overlap

Definition at line 89 of file NamedCandCombinerBase.h.