CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
TransientTrackingRecHitByValue.h
Go to the documentation of this file.
1 #ifndef TransientTrackingRecHitByValue_H
2 #define TransientTrackingRecHitByValue_H
3 
5 
6 template<typename RecHit>
8 public:
10 
12 
13  virtual AlgebraicVector parameters() const {return m_trackingRecHit.parameters();}
14  virtual AlgebraicSymMatrix parametersError() const {return m_trackingRecHit.parametersError();}
15  virtual AlgebraicMatrix projectionMatrix() const {return m_trackingRecHit.projectionMatrix();}
16  virtual int dimension() const {return m_trackingRecHit.dimension();}
17 
18  virtual LocalPoint localPosition() const {return m_trackingRecHit.localPosition();}
19  virtual LocalError localPositionError() const {return m_trackingRecHit.localPositionError();}
20 
21  virtual bool canImproveWithTrack() const {return false;}
22 
23  virtual const RecHit * hit() const {return &m_trackingRecHit;};
24 
25 
26  virtual std::vector<const TrackingRecHit*> recHits() const {
27  return hit()->recHits();
28  }
29  virtual std::vector<TrackingRecHit*> recHits() {
30  return m_trackingRecHit.recHits();
31  }
32 
33  static RecHitPointer build( const GeomDet * geom, const RecHit * rh) {
35  }
36 
37 protected:
38 
39  // private constructors enforce usage of builders
40  TransientTrackingRecHitByValue(const GeomDet * geom, const RecHit& rh) :
42  }
43 
44 
46  TransientTrackingRecHit( other.det(),other), m_trackingRecHit(*other.hit()) {
47  }
48 
49 private:
50 
52 
53  // should not have assignment operator (?)
55  m_trackingRecHit = *t.hit();
56  return *(this);
57  }
58 
59  // hide the clone method for ReferenceCounted. Warning: this method is still
60  // accessible via the bas class TrackingRecHit interface!
63  }
64 
65 };
66 
67 #endif // TransientTrackingRecHitByValue_H
68 
ReferenceCountingPointer< TransientTrackingRecHit > RecHitPointer
virtual AlgebraicVector parameters() const
TransientTrackingRecHitByValue< RecHit > & operator=(const TransientTrackingRecHitByValue< RecHit > &t)
static RecHitPointer build(const GeomDet *geom, const RecHit *rh)
virtual AlgebraicMatrix projectionMatrix() const
CLHEP::HepMatrix AlgebraicMatrix
virtual std::vector< const TrackingRecHit * > recHits() const
Access to component RecHits (if any)
TransientTrackingRecHitByValue(const GeomDet *geom, const RecHit &rh)
virtual AlgebraicSymMatrix parametersError() const
virtual TransientTrackingRecHitByValue< RecHit > * clone() const
virtual LocalError localPositionError() const
TransientTrackingRecHitByValue(const TransientTrackingRecHitByValue< RecHit > &other)
CLHEP::HepVector AlgebraicVector
virtual std::vector< TrackingRecHit * > recHits()
Non-const access to component RecHits (if any)
const GeomDet * det() const
The GomeDet* can be zero for InvalidTransientRecHits and for TConstraintRecHit2Ds.
CLHEP::HepSymMatrix AlgebraicSymMatrix
virtual const RecHit * hit() const