StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StTofSlat.h
1 
5 /***************************************************************************
6  *
7  * $Id: StTofSlat.h,v 2.9 2004/02/05 17:58:51 ullrich Exp $
8  *
9  * Author: Wei-Ming Zhang, Dec 2000
10  ***************************************************************************
11  *
12  * Description:
13  *
14  ***************************************************************************
15  *
16  * $Log: StTofSlat.h,v $
17  * Revision 2.9 2004/02/05 17:58:51 ullrich
18  * Changed $LINK to StLink mechanism.
19  *
20  * Revision 2.8 2003/07/28 21:00:22 ullrich
21  * Revised version: new but not inheriting from StHit as before.
22  *
23  * Revision 2.7 2003/07/11 00:01:04 jeromel
24  * Re-adding preceeding revision
25  *
26  * Revision 2.4 2003/05/21 18:23:18 ullrich
27  * Major Revision of ToF classes (F. Geurts)
28  *
29  * Revision 2.3 2002/02/22 22:56:52 jeromel
30  * Doxygen basic documentation in all header files. None of this is required
31  * for QM production.
32  *
33  * Revision 2.2 2001/04/05 04:00:43 ullrich
34  * Replaced all (U)Long_t by (U)Int_t and all redundant ROOT typedefs.
35  *
36  * Revision 2.1 2000/12/21 23:52:23 ullrich
37  * Initial Revision.
38  *
39  **************************************************************************/
40 #ifndef StTofSlat_hh
41 #define StTofSlat_hh
42 
43 #include "StObject.h"
44 #include "StThreeVectorF.hh"
45 #include "StContainers.h"
46 class StTrack;
47 
48 class StTofSlat : public StObject {
49 public:
50  StTofSlat();
51  StTofSlat(unsigned short, unsigned short, unsigned short, StTrack*,
52  float, unsigned short, unsigned short);
53  ~StTofSlat();
54 
55  int operator==(const StTofSlat&) const;
56  int operator!=(const StTofSlat&) const;
57 
58  unsigned short slatIndex() const;
59  unsigned short adc() const;
60  unsigned short tdc() const;
61  StTrack* associatedTrack();
62  const StTrack* associatedTrack() const;
63  float zHit() const;
64  unsigned short hitProf() const;
65  unsigned short matchFlag() const;
66  const StThreeVectorF& position() const;
67 
68  void setSlatIndex(unsigned short);
69  void setAdc(unsigned short);
70  void setTdc(unsigned short);
71  void setAssociatedTrack(StTrack*);
72  void setZHit(float);
73  void setHitProf(unsigned short);
74  void setMatchFlag(unsigned short);
75  void setPosition(const StThreeVectorF&);
76 
77 protected:
78  UShort_t mSlatIndex;
79  UShort_t mAdc;
80  UShort_t mTdc;
81  // StTrack *mAssociatedTrack; //$LINK
82 #ifdef __CINT__
83  StObjLink mAssociatedTrack;
84 #else
85  StLink<StTrack> mAssociatedTrack;
86 #endif //__CINT__
87  Float_t mZhit;
88  UShort_t mHitProf;
89  UShort_t mMatchFlag;
90  StThreeVectorF mPosition;
91 
92  ClassDef(StTofSlat,4)
93 };
94 
95 inline void
96 StTofSlat::setSlatIndex(unsigned short slatId) {mSlatIndex = slatId;}
97 
98 inline void
99 StTofSlat::setAdc(unsigned short rawAdc) {mAdc = rawAdc;}
100 
101 inline void
102 StTofSlat::setTdc(unsigned short rawTdc) {mTdc = rawTdc;}
103 
104 inline void
105 StTofSlat::setZHit(float zhit) {mZhit = zhit;}
106 
107 inline void
108 StTofSlat::setHitProf(unsigned short hitprof) {mHitProf = hitprof;}
109 
110 inline void
111 StTofSlat::setMatchFlag(unsigned short matchflag) {mMatchFlag = matchflag;}
112 
113 inline unsigned short
114 StTofSlat::slatIndex() const {return mSlatIndex;}
115 
116 inline unsigned short
117 StTofSlat::adc() const {return mAdc;}
118 
119 inline unsigned short
120 StTofSlat::tdc() const {return mTdc;}
121 
122 inline float
123 StTofSlat::zHit() const {return mZhit;}
124 
125 inline unsigned short
126 StTofSlat::hitProf() const {return mHitProf;}
127 
128 inline unsigned short
129 StTofSlat::matchFlag() const {return mMatchFlag;}
130 
131 #endif