test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
RecoChargedRefCandidate.h
Go to the documentation of this file.
1 #ifndef RecoCandidate_RecoChargedRefCandidate_h
2 #define RecoCandidate_RecoChargedRefCandidate_h
3 
7 
8 namespace reco {
9 
10 
12 
13 
15  public:
18 
20 
21  RecoChargedRefCandidate * clone() const { return new RecoChargedRefCandidate(*this);}
22 
24  return getRef<reco::TrackRef>();
25  }
26  // return a pointer to the best track, if available.
27  // otherwise, return a null pointer
28  virtual const reco::Track * bestTrack() const {
29  if ( track().isNonnull() && track().isAvailable() )
30  return &(*track());
31  else
32  return nullptr;
33  }
34 
36  virtual float dzError() const { const Track * tr=bestTrack(); if(tr!=nullptr) return tr->dzError(); else return 0; }
38  virtual float dxyError() const { const Track * tr=bestTrack(); if(tr!=nullptr) return tr->dxyError(); else return 0; }
39 
40  };
41 }
42 
43 #endif
virtual const reco::Track * bestTrack() const
double dxyError() const
error on dxy
Definition: TrackBase.h:791
RecoChargedRefCandidate * clone() const
returns a clone of the Candidate object
RecoChargedRefCandidate(TrackRef ref, float m)
virtual float dxyError() const
uncertainty on dxy
LeafRefCandidateT RecoChargedRefCandidateBase
virtual float dzError() const
uncertainty on dz
double dzError() const
error on dz
Definition: TrackBase.h:809