#include <PFBlockElementTrack.h>
Public Member Functions | |
PFBlockElement * | clone () const |
necessary to have the edm::OwnVector<PFBlockElement> working | |
ConversionRef | convRef () const |
PFDisplacedTrackerVertexRef | displacedVertexRef (TrackType trType) const |
void | Dump (std::ostream &out=std::cout, const char *tab=" ") const |
print the object inside the element | |
bool | isLinkedToDisplacedVertex () const |
bool | isPrimary () const |
bool | isSecondary () const |
check if the track is secondary | |
reco::MuonRef | muonRef () const |
PFBlockElementTrack (const PFRecTrackRef &ref) | |
PFBlockElementTrack () | |
const math::XYZPointF & | positionAtECALEntrance () const |
void | setConversionRef (const ConversionRef &convRef, TrackType trType) |
the ref to gamma conversion | |
void | setDisplacedVertexRef (const PFDisplacedTrackerVertexRef &niref, TrackType trType) |
the ref to the displaced vertex interaction | |
void | setMuonRef (const MuonRef &muref) |
reference to the Muon | |
void | setPositionAtECALEntrance (float x, float y, float z) |
set position at ECAL entrance | |
virtual void | setTrackType (TrackType trType, bool value) |
the trackType | |
void | setV0Ref (const VertexCompositeCandidateRef &V0Ref, TrackType trType) |
the ref to V0 | |
reco::TrackRef | trackRef () const |
PFRecTrackRef | trackRefPF () const |
virtual bool | trackType (TrackType trType) const |
VertexCompositeCandidateRef | V0Ref () const |
Private Attributes | |
ConversionRef | convRef_ |
reference to reco conversion | |
PFDisplacedTrackerVertexRef | displacedVertexDaughterRef_ |
reference to the corresponding pf displaced vertex which this track was created | |
PFDisplacedTrackerVertexRef | displacedVertexMotherRef_ |
reference to the corresponding pf displaced vertex where this track was created | |
reco::MuonRef | muonRef_ |
reference to the corresponding muon | |
math::XYZPointF | positionAtECALEntrance_ |
position at ECAL entrance | |
reco::TrackRef | trackRef_ |
reference to the corresponding track | |
PFRecTrackRef | trackRefPF_ |
reference to the corresponding track (transient) | |
unsigned int | trackType_ |
VertexCompositeCandidateRef | v0Ref_ |
reference to V0 |
Track Element.
this class contains a reference to a PFRecTrack
Definition at line 17 of file PFBlockElementTrack.h.
reco::PFBlockElementTrack::PFBlockElementTrack | ( | ) | [inline] |
PFBlockElementTrack::PFBlockElementTrack | ( | const PFRecTrackRef & | ref | ) |
Definition at line 13 of file PFBlockElementTrack.cc.
References reco::PFBlockElement::DEFAULT, reco::PFTrajectoryPoint::ECALEntrance, edm::Ref< C, T, F >::isNull(), reco::PFTrajectoryPoint::isValid(), reco::PFTrajectoryPoint::position(), positionAtECALEntrance_, and setTrackType().
: PFBlockElement( TRACK ), trackRefPF_( ref ), trackRef_( ref->trackRef() ), trackType_(0) { if( ref.isNull() ) throw cms::Exception("NullRef")<<" PFBlockElementTrack constructed from a null reference to PFRecTrack."; const reco::PFTrajectoryPoint& atECAL = ref->extrapolatedPoint( reco::PFTrajectoryPoint::ECALEntrance ); if( atECAL.isValid() ) positionAtECALEntrance_.SetCoordinates( atECAL.position().x(), atECAL.position().y(), atECAL.position().z() ); // if the position at ecal entrance is invalid, // positionAtECALEntrance_ is initialized by default to 0,0,0 setTrackType( DEFAULT, true ); }
PFBlockElement* reco::PFBlockElementTrack::clone | ( | ) | const [inline, virtual] |
necessary to have the edm::OwnVector<PFBlockElement> working
Implements reco::PFBlockElement.
Definition at line 24 of file PFBlockElementTrack.h.
References PFBlockElementTrack().
{ return new PFBlockElementTrack(*this); }
ConversionRef reco::PFBlockElementTrack::convRef | ( | ) | const [inline, virtual] |
Reimplemented from reco::PFBlockElement.
Definition at line 102 of file PFBlockElementTrack.h.
References convRef_.
Referenced by setConversionRef().
{return convRef_;}
PFDisplacedTrackerVertexRef reco::PFBlockElementTrack::displacedVertexRef | ( | TrackType | trType | ) | const [inline, virtual] |
Reimplemented from reco::PFBlockElement.
Definition at line 76 of file PFBlockElementTrack.h.
References displacedVertexDaughterRef_, displacedVertexMotherRef_, reco::PFBlockElement::T_FROM_DISP, and reco::PFBlockElement::T_TO_DISP.
Referenced by PFAlgo::reconstructTrack().
{ if (trType == T_TO_DISP) return displacedVertexDaughterRef_; else if (trType == T_FROM_DISP) return displacedVertexMotherRef_; else return PFDisplacedTrackerVertexRef(); }
void reco::PFBlockElementTrack::Dump | ( | std::ostream & | out = std::cout , |
const char * | tab = " " |
||
) | const [virtual] |
print the object inside the element
Reimplemented from reco::PFBlockElement.
bool reco::PFBlockElementTrack::isLinkedToDisplacedVertex | ( | ) | const [inline, virtual] |
Reimplemented from reco::PFBlockElement.
Definition at line 71 of file PFBlockElementTrack.h.
References isPrimary(), and isSecondary().
{ return isSecondary() || isPrimary(); }
bool reco::PFBlockElementTrack::isPrimary | ( | ) | const [inline, virtual] |
Reimplemented from reco::PFBlockElement.
Definition at line 67 of file PFBlockElementTrack.h.
References reco::PFBlockElement::T_TO_DISP, and trackType().
Referenced by isLinkedToDisplacedVertex().
bool reco::PFBlockElementTrack::isSecondary | ( | ) | const [inline, virtual] |
check if the track is secondary
Reimplemented from reco::PFBlockElement.
Definition at line 60 of file PFBlockElementTrack.h.
References reco::PFBlockElement::T_FROM_DISP, reco::PFBlockElement::T_FROM_GAMMACONV, reco::PFBlockElement::T_FROM_V0, and trackType().
Referenced by isLinkedToDisplacedVertex().
{ return trackType(T_FROM_DISP) || trackType(T_FROM_GAMMACONV) || trackType(T_FROM_V0); }
reco::MuonRef reco::PFBlockElementTrack::muonRef | ( | ) | const [inline, virtual] |
Reimplemented from reco::PFBlockElement.
Definition at line 94 of file PFBlockElementTrack.h.
References muonRef_.
Referenced by PFMuonAlgo::isGlobalLooseMuon(), PFMuonAlgo::isGlobalTightMuon(), PFMuonAlgo::isIsolatedMuon(), PFMuonAlgo::isLooseMuon(), PFMuonAlgo::isMuon(), PFMuonAlgo::isTrackerTightMuon(), and PFAlgo::reconstructTrack().
{ return muonRef_; }
const math::XYZPointF& reco::PFBlockElementTrack::positionAtECALEntrance | ( | ) | const [inline] |
Definition at line 48 of file PFBlockElementTrack.h.
References positionAtECALEntrance_.
Referenced by PFAlgo::reconstructTrack().
{ return positionAtECALEntrance_; }
void reco::PFBlockElementTrack::setConversionRef | ( | const ConversionRef & | convRef, |
TrackType | trType | ||
) | [inline, virtual] |
the ref to gamma conversion
Reimplemented from reco::PFBlockElement.
Definition at line 105 of file PFBlockElementTrack.h.
References convRef(), convRef_, and setTrackType().
{ convRef_ = convRef; setTrackType(trType,true); }
void reco::PFBlockElementTrack::setDisplacedVertexRef | ( | const PFDisplacedTrackerVertexRef & | niref, |
TrackType | trType | ||
) | [inline, virtual] |
the ref to the displaced vertex interaction
Reimplemented from reco::PFBlockElement.
Definition at line 85 of file PFBlockElementTrack.h.
References displacedVertexDaughterRef_, displacedVertexMotherRef_, setTrackType(), reco::PFBlockElement::T_FROM_DISP, and reco::PFBlockElement::T_TO_DISP.
{ if (trType == T_TO_DISP) { displacedVertexDaughterRef_ = niref; setTrackType(trType,true);} else if (trType == T_FROM_DISP) { displacedVertexMotherRef_ = niref; setTrackType(trType,true);} }
void reco::PFBlockElementTrack::setMuonRef | ( | const MuonRef & | muref | ) | [inline, virtual] |
reference to the Muon
Reimplemented from reco::PFBlockElement.
Definition at line 97 of file PFBlockElementTrack.h.
References reco::PFBlockElement::MUON, muonRef_, and setTrackType().
{ muonRef_=muref; setTrackType(MUON,true); }
void reco::PFBlockElementTrack::setPositionAtECALEntrance | ( | float | x, |
float | y, | ||
float | z | ||
) | [inline] |
set position at ECAL entrance
Definition at line 42 of file PFBlockElementTrack.h.
References positionAtECALEntrance_.
{ positionAtECALEntrance_.SetCoordinates(x, y, z); }
virtual void reco::PFBlockElementTrack::setTrackType | ( | TrackType | trType, |
bool | value | ||
) | [inline, virtual] |
the trackType
Reimplemented from reco::PFBlockElement.
Definition at line 35 of file PFBlockElementTrack.h.
References trackType_.
Referenced by PFBlockElementTrack(), setConversionRef(), setDisplacedVertexRef(), setMuonRef(), and setV0Ref().
{ if(value) trackType_ = trackType_ | (1<<trType); else trackType_ = trackType_ ^ (1<<trType); }
void reco::PFBlockElementTrack::setV0Ref | ( | const VertexCompositeCandidateRef & | V0Ref, |
TrackType | trType | ||
) | [inline, virtual] |
the ref to V0
Reimplemented from reco::PFBlockElement.
Definition at line 113 of file PFBlockElementTrack.h.
References setTrackType(), V0Ref(), and v0Ref_.
{ v0Ref_ = V0Ref; setTrackType(trType,true); }
reco::TrackRef reco::PFBlockElementTrack::trackRef | ( | ) | const [inline, virtual] |
Reimplemented from reco::PFBlockElement.
Definition at line 57 of file PFBlockElementTrack.h.
References trackRef_.
Referenced by PFAlgo::reconstructTrack(), PFElectronAlgo::SetCandidates(), PFConversionAlgo::setCandidates(), PFElectronAlgo::SetIDOutputs(), and PFElectronAlgo::SetLinks().
{ return trackRef_; }
PFRecTrackRef reco::PFBlockElementTrack::trackRefPF | ( | ) | const [inline, virtual] |
Reimplemented from reco::PFBlockElement.
Definition at line 54 of file PFBlockElementTrack.h.
References trackRefPF_.
Referenced by PFElectronAlgo::isPrimaryTrack().
{ return trackRefPF_; }
virtual bool reco::PFBlockElementTrack::trackType | ( | TrackType | trType | ) | const [inline, virtual] |
Reimplemented from reco::PFBlockElement.
Definition at line 30 of file PFBlockElementTrack.h.
References trackType_.
Referenced by isPrimary(), isSecondary(), and PFPhotonAlgo::RunPFPhoton().
{ return (trackType_>>trType) & 1; }
VertexCompositeCandidateRef reco::PFBlockElementTrack::V0Ref | ( | ) | const [inline, virtual] |
Reimplemented from reco::PFBlockElement.
Definition at line 110 of file PFBlockElementTrack.h.
References v0Ref_.
Referenced by setV0Ref().
{return v0Ref_;}
reference to reco conversion
Definition at line 142 of file PFBlockElementTrack.h.
Referenced by convRef(), and setConversionRef().
reference to the corresponding pf displaced vertex which this track was created
Definition at line 136 of file PFBlockElementTrack.h.
Referenced by displacedVertexRef(), and setDisplacedVertexRef().
reference to the corresponding pf displaced vertex where this track was created
Definition at line 133 of file PFBlockElementTrack.h.
Referenced by displacedVertexRef(), and setDisplacedVertexRef().
reference to the corresponding muon
Definition at line 139 of file PFBlockElementTrack.h.
Referenced by muonRef(), and setMuonRef().
position at ECAL entrance
Definition at line 130 of file PFBlockElementTrack.h.
Referenced by PFBlockElementTrack(), positionAtECALEntrance(), and setPositionAtECALEntrance().
reference to the corresponding track
Definition at line 125 of file PFBlockElementTrack.h.
Referenced by trackRef().
reference to the corresponding track (transient)
Definition at line 122 of file PFBlockElementTrack.h.
Referenced by trackRefPF().
unsigned int reco::PFBlockElementTrack::trackType_ [private] |
Definition at line 127 of file PFBlockElementTrack.h.
Referenced by setTrackType(), and trackType().
reference to V0
Definition at line 145 of file PFBlockElementTrack.h.
Referenced by setV0Ref(), and V0Ref().