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 | Protected Attributes | Friends
reco::PFBlockElement Class Referenceabstract

Abstract base class for a PFBlock element (track, cluster...) More...

#include <PFBlockElement.h>

Inheritance diagram for reco::PFBlockElement:
reco::PFBlockElementBrem reco::PFBlockElementCluster reco::PFBlockElementGsfTrack reco::PFBlockElementSuperCluster reco::PFBlockElementTrack

Public Types

enum  TrackType {
  DEFAULT =0, T_FROM_DISP, T_TO_DISP, T_FROM_GAMMACONV,
  MUON, T_FROM_V0
}
 
enum  Type {
  NONE =0, TRACK =1, PS1 =2, PS2 =3,
  ECAL =4, HCAL =5, GSF =6, BREM =7,
  HFEM =8, HFHAD =9, SC =10, HO =11
}
 

Public Member Functions

virtual PFBlockElementclone () const =0
 necessary to have the edm::OwnVector<PFBlockElement> working More...
 
virtual PFClusterRef clusterRef () const
 
virtual ConversionRef convRef () const
 
virtual PFDisplacedTrackerVertexRef displacedVertexRef (TrackType trType) const
 
virtual void Dump (std::ostream &out=std::cout, const char *tab=" ") const
 print the object inside the element More...
 
const PFMultilinksTypegetMultilinks () const
 
unsigned index () const
 
virtual bool isLinkedToDisplacedVertex () const
 
bool isMultilinksValide () const
 
virtual bool isPrimary () const
 
virtual bool isSecondary () const
 
void lock ()
 lock element More...
 
bool locked () const
 locked ? More...
 
virtual MuonRef muonRef () const
 
 PFBlockElement (Type type=NONE)
 standard constructor More...
 
virtual void setConversionRef (const ConversionRef &convRef, TrackType trType)
 
virtual void setDisplacedVertexRef (const PFDisplacedTrackerVertexRef &niref, TrackType trType)
 
void setIndex (unsigned index)
 set index More...
 
void setIsValidMultilinks (bool isVal)
 
void setMultilinks (const PFMultiLinksTC &ml)
 
void setMultilinksList (const PFMultilinksType &links)
 
virtual void setMuonRef (const MuonRef &muref)
 
virtual void setTrackType (TrackType trType, bool value)
 the trackType More...
 
virtual void setV0Ref (const VertexCompositeCandidateRef &v0ref, TrackType trType)
 
virtual reco::TrackRef trackRef () const
 
virtual PFRecTrackRef trackRefPF () const
 
virtual bool trackType (TrackType trType) const
 
Type type () const
 
void unLock ()
 unlock element More...
 
virtual VertexCompositeCandidateRef V0Ref () const
 
virtual ~PFBlockElement ()
 destructor More...
 

Protected Attributes

unsigned index_
 index in block vector More...
 
bool locked_
 
PFMultiLinksTC multilinks_
 
Type type_
 

Friends

std::ostream & operator<< (std::ostream &out, const PFBlockElement &element)
 

Detailed Description

Abstract base class for a PFBlock element (track, cluster...)

this class contains a PFRecTrackRef of a PFClusterRef, depending on the type of the element

Definition at line 28 of file PFBlockElement.h.

Member Enumeration Documentation

Enumerator
DEFAULT 
T_FROM_DISP 
T_TO_DISP 
T_FROM_GAMMACONV 
MUON 
T_FROM_V0 

Definition at line 48 of file PFBlockElement.h.

possible types for the element do not modify this enum if you don't know what you're doing!!!

Enumerator
NONE 
TRACK 
PS1 
PS2 
ECAL 
HCAL 
GSF 
BREM 
HFEM 
HFHAD 
SC 
HO 

Definition at line 33 of file PFBlockElement.h.

Constructor & Destructor Documentation

reco::PFBlockElement::PFBlockElement ( Type  type = NONE)
inline

standard constructor

Definition at line 58 of file PFBlockElement.h.

58  :
59  type_(type),
60  locked_(false),
61  index_( static_cast<unsigned>(-1) ) {
62  }
type
Definition: HCALResponse.h:21
unsigned index_
index in block vector
virtual reco::PFBlockElement::~PFBlockElement ( )
inlinevirtual

destructor

Definition at line 66 of file PFBlockElement.h.

66 {}

Member Function Documentation

virtual PFBlockElement* reco::PFBlockElement::clone ( ) const
pure virtual
virtual PFClusterRef reco::PFBlockElement::clusterRef ( ) const
inlinevirtual
virtual ConversionRef reco::PFBlockElement::convRef ( ) const
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 104 of file PFBlockElement.h.

Referenced by PFBlockAlgo::testLinkByVertex().

104 { return ConversionRef();}
edm::Ref< ConversionCollection > ConversionRef
reference to an object in a collection of Conversion objects
Definition: ConversionFwd.h:15
virtual PFDisplacedTrackerVertexRef reco::PFBlockElement::displacedVertexRef ( TrackType  trType) const
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 103 of file PFBlockElement.h.

Referenced by PFBlockAlgo::testLinkByVertex().

103 { return PFDisplacedTrackerVertexRef(); }
edm::Ref< PFDisplacedTrackerVertexCollection > PFDisplacedTrackerVertexRef
persistent reference to a DisplacedTrackerVertex
void PFBlockElement::Dump ( std::ostream &  out = std::cout,
const char *  tab = " " 
) const
virtual

print the object inside the element

Reimplemented in reco::PFBlockElementSuperCluster, reco::PFBlockElementCluster, reco::PFBlockElementGsfTrack, reco::PFBlockElementBrem, and reco::PFBlockElementTrack.

Definition at line 17 of file PFBlockElement.cc.

18  {
19  if(!out) return;
20  out<<pad<<"base element";
21 }
tuple out
Definition: dbtoconf.py:99
const PFMultilinksType& reco::PFBlockElement::getMultilinks ( ) const
inline

Definition at line 132 of file PFBlockElement.h.

References reco::PFMultiLinksTC::linkedClusters, and multilinks_.

Referenced by PFBlockAlgo::link(), and PFBlockAlgo::linkPrefilter().

132 {return multilinks_.linkedClusters;}
PFMultiLinksTC multilinks_
PFMultilinksType linkedClusters
unsigned reco::PFBlockElement::index ( ) const
inline
Returns
index

Definition at line 98 of file PFBlockElement.h.

References index_.

Referenced by PFElectronTranslator::correspondingDaughterCandidate(), PFPhotonTranslator::correspondingDaughterCandidate(), and setIndex().

98 {return index_;}
unsigned index_
index in block vector
virtual bool reco::PFBlockElement::isLinkedToDisplacedVertex ( ) const
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 121 of file PFBlockElement.h.

Referenced by PFBlockAlgo::link().

121 {return false;}
bool reco::PFBlockElement::isMultilinksValide ( ) const
inline

Definition at line 131 of file PFBlockElement.h.

References reco::PFMultiLinksTC::isValid, and multilinks_.

Referenced by PFBlockAlgo::link(), and PFBlockAlgo::linkPrefilter().

131 {return multilinks_.isValid;}
PFMultiLinksTC multilinks_
virtual bool reco::PFBlockElement::isPrimary ( ) const
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 120 of file PFBlockElement.h.

120 { return false; }
virtual bool reco::PFBlockElement::isSecondary ( ) const
inlinevirtual

Reimplemented in reco::PFBlockElementTrack, and reco::PFBlockElementGsfTrack.

Definition at line 119 of file PFBlockElement.h.

119 { return false; }
void reco::PFBlockElement::lock ( )
inline

lock element

Definition at line 76 of file PFBlockElement.h.

References locked_.

Referenced by reco::PFBlock::addElement().

76 {locked_ = true;}
bool reco::PFBlockElement::locked ( ) const
inline

locked ?

Definition at line 92 of file PFBlockElement.h.

References locked_.

92 {return locked_;}
virtual MuonRef reco::PFBlockElement::muonRef ( ) const
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 105 of file PFBlockElement.h.

105 { return MuonRef(); }
edm::Ref< MuonCollection > MuonRef
presistent reference to a Muon
Definition: MuonFwd.h:13
virtual void reco::PFBlockElement::setConversionRef ( const ConversionRef convRef,
TrackType  trType 
)
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 109 of file PFBlockElement.h.

References gather_cfg::cout.

Referenced by PFBlockAlgo::setInput().

109  {
110  std::cout << "Error in PFBlockElement::setConversionRef : this base class method is not implemented" << std::endl;}
tuple cout
Definition: gather_cfg.py:121
virtual void reco::PFBlockElement::setDisplacedVertexRef ( const PFDisplacedTrackerVertexRef niref,
TrackType  trType 
)
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 107 of file PFBlockElement.h.

References gather_cfg::cout.

Referenced by PFBlockAlgo::setInput().

107  {
108  std::cout << "Error in PFBlockElement::setDisplacedVertexRef : this base class method is not implemented" << std::endl;}
tuple cout
Definition: gather_cfg.py:121
void reco::PFBlockElement::setIndex ( unsigned  index)
inline

set index

Definition at line 95 of file PFBlockElement.h.

References index(), and index_.

Referenced by reco::PFBlock::addElement().

95 { index_ = index; }
unsigned index() const
unsigned index_
index in block vector
void reco::PFBlockElement::setIsValidMultilinks ( bool  isVal)
inline

Definition at line 128 of file PFBlockElement.h.

References reco::PFMultiLinksTC::isValid, and multilinks_.

128 {multilinks_.isValid = isVal;}
PFMultiLinksTC multilinks_
void reco::PFBlockElement::setMultilinks ( const PFMultiLinksTC ml)
inline

Definition at line 127 of file PFBlockElement.h.

References multilinks_.

127 {multilinks_ = ml;}
PFMultiLinksTC multilinks_
void reco::PFBlockElement::setMultilinksList ( const PFMultilinksType links)
inline
virtual void reco::PFBlockElement::setMuonRef ( const MuonRef muref)
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 111 of file PFBlockElement.h.

References gather_cfg::cout.

Referenced by PFBlockAlgo::setInput().

111  {
112  std::cout << "Error in PFBlockElement::setMuonRef : this base class method is not implemented" << std::endl;}
tuple cout
Definition: gather_cfg.py:121
virtual void reco::PFBlockElement::setTrackType ( TrackType  trType,
bool  value 
)
inlinevirtual

the trackType

Reimplemented in reco::PFBlockElementGsfTrack, and reco::PFBlockElementTrack.

Definition at line 88 of file PFBlockElement.h.

References gather_cfg::cout.

Referenced by PFBlockAlgo::setInput().

88  {
89  std::cout << "Error in PFBlockElement::setTrackType : this base class method is not implemented" << std::endl;}
tuple cout
Definition: gather_cfg.py:121
virtual void reco::PFBlockElement::setV0Ref ( const VertexCompositeCandidateRef v0ref,
TrackType  trType 
)
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 113 of file PFBlockElement.h.

References gather_cfg::cout.

Referenced by PFBlockAlgo::setInput().

113  {
114 
115  std::cout << "Error in PFBlockElement::setV0Ref : this base class method is not implemented" << std::endl;
116  }
tuple cout
Definition: gather_cfg.py:121
virtual reco::TrackRef reco::PFBlockElement::trackRef ( ) const
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 100 of file PFBlockElement.h.

Referenced by PFPhotonAlgo::EvaluateGCorrMVA(), PFEGammaAlgo::EvaluateGCorrMVA(), PFPhotonAlgo::EvaluateResMVA(), PFEGammaAlgo::EvaluateResMVA(), PFBlockAlgo::link(), and FWPFBlockProxyBuilder::setupTrackElement().

100 {return reco::TrackRef(); }
edm::Ref< TrackCollection > TrackRef
persistent reference to a Track
Definition: TrackFwd.h:14
virtual PFRecTrackRef reco::PFBlockElement::trackRefPF ( ) const
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 101 of file PFBlockElement.h.

Referenced by PFBlockAlgo::link().

101 {return PFRecTrackRef(); }
edm::Ref< PFRecTrackCollection > PFRecTrackRef
persistent reference to PFRecTrack objects
Definition: PFRecTrackFwd.h:15
virtual bool reco::PFBlockElement::trackType ( TrackType  trType) const
inlinevirtual
Type reco::PFBlockElement::type ( ) const
inline
void reco::PFBlockElement::unLock ( )
inline

unlock element

Definition at line 79 of file PFBlockElement.h.

References locked_.

79 {locked_ = false;}
virtual VertexCompositeCandidateRef reco::PFBlockElement::V0Ref ( ) const
inlinevirtual

Reimplemented in reco::PFBlockElementTrack.

Definition at line 106 of file PFBlockElement.h.

Referenced by PFBlockAlgo::testLinkByVertex().

106 { return VertexCompositeCandidateRef(); }
edm::Ref< VertexCompositeCandidateCollection > VertexCompositeCandidateRef
persistent reference to an object in a collection of Candidate objects

Friends And Related Function Documentation

std::ostream& operator<< ( std::ostream &  out,
const PFBlockElement element 
)
friend

Member Data Documentation

unsigned reco::PFBlockElement::index_
protected

index in block vector

Definition at line 147 of file PFBlockElement.h.

Referenced by index(), and setIndex().

bool reco::PFBlockElement::locked_
protected

locked flag.

Definition at line 144 of file PFBlockElement.h.

Referenced by lock(), locked(), and unLock().

PFMultiLinksTC reco::PFBlockElement::multilinks_
protected
Type reco::PFBlockElement::type_
protected