CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
TrackingRecHit.h
Go to the documentation of this file.
1 #ifndef TrackingRecHit_h
2 #define TrackingRecHit_h
3 
9 
11 public:
12 
14 
15  typedef unsigned int id_type;
16 
24  enum Type { valid = 0, missing = 1, inactive = 2, bad = 3 };
27 
28  explicit TrackingRecHit(DetId id, Type type=valid ) : m_id(id), m_status(type) {}
29  explicit TrackingRecHit(id_type id=0, Type type=valid ) : m_id(id), m_status(type) {}
30 
31  virtual ~TrackingRecHit() {}
32 
33  virtual TrackingRecHit * clone() const = 0;
34 
35  virtual AlgebraicVector parameters() const = 0;
36 
37  virtual AlgebraicSymMatrix parametersError() const = 0;
38 
39  virtual AlgebraicMatrix projectionMatrix() const = 0;
40 
41  virtual void getKfComponents( KfComponentsHolder & holder ) const ;
42 
43  virtual int dimension() const = 0;
44 
46  virtual std::vector<const TrackingRecHit*> recHits() const = 0;
47  virtual void recHitsV(std::vector<const TrackingRecHit*> & ) const;
48 
50  virtual std::vector<TrackingRecHit*> recHits() = 0;
51  virtual void recHitsV(std::vector<TrackingRecHit*> & );
52 
53  DetId geographicalId() const {return m_id;}
54 
55  virtual LocalPoint localPosition() const = 0;
56 
57  virtual LocalError localPositionError() const = 0;
58 
59  virtual float weight() const {return 1.;}
60 
61  Type type() const { return Type(m_status); }
62  Type getType() const { return Type(m_status); }
63  bool isValid() const {return getType()==valid;}
64 
70  virtual bool sharesInput( const TrackingRecHit* other, SharedInputType what) const;
71 
72 protected:
73  // used by muon...
74  void setId(id_type iid) { m_id=iid;}
75  inline void setType(Type ttype) { m_status=ttype;}
76 
77 private:
78 
80  int m_status;
81 
82 };
83 
84 #endif
SharedInputType
definition of equality via shared input
type
Definition: HCALResponse.h:22
virtual int dimension() const =0
virtual void getKfComponents(KfComponentsHolder &holder) const
virtual float weight() const
unsigned int id_type
void setId(id_type iid)
virtual bool sharesInput(const TrackingRecHit *other, SharedInputType what) const
Type type() const
virtual AlgebraicVector parameters() const =0
CLHEP::HepMatrix AlgebraicMatrix
void setType(Type ttype)
virtual ~TrackingRecHit()
virtual std::vector< const TrackingRecHit * > recHits() const =0
Access to component RecHits (if any)
virtual TrackingRecHit * clone() const =0
TrackingRecHit(DetId id, Type type=valid)
Definition: DetId.h:20
CLHEP::HepVector AlgebraicVector
Type getType() const
virtual LocalError localPositionError() const =0
bool isValid() const
TrackingRecHit(id_type id=0, Type type=valid)
virtual AlgebraicMatrix projectionMatrix() const =0
CLHEP::HepSymMatrix AlgebraicSymMatrix
DetId geographicalId() const
virtual void recHitsV(std::vector< const TrackingRecHit * > &) const
virtual LocalPoint localPosition() const =0
virtual AlgebraicSymMatrix parametersError() const =0