StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StEmcPoint.h
1 
5 /***************************************************************************
6  *
7  * $Id: StEmcPoint.h,v 2.11 2016/02/25 17:10:19 ullrich Exp $
8  *
9  * Author: Akio Ogawa, Mar 2000
10  ***************************************************************************
11  *
12  * Description: Base class for electromagnetic calorimeter Point
13  *
14  ***************************************************************************
15  *
16  * $Log: StEmcPoint.h,v $
17  * Revision 2.11 2016/02/25 17:10:19 ullrich
18  * Implemented detector() which is now a pure abstract method in StHit.
19  *
20  * Revision 2.10 2012/10/23 20:18:33 fisyak
21  * Add/modify print outs
22  *
23  * Revision 2.9 2005/08/31 18:25:41 perev
24  * Class version increased by 1
25  *
26  * Revision 2.8 2005/07/19 21:32:50 perev
27  * Remove clash with IdTruth
28  *
29  * Revision 2.7 2004/07/20 17:07:49 perev
30  * Pavlinov corrs for TBrowser
31  *
32  * Revision 2.6 2004/07/15 16:36:24 ullrich
33  * Removed all clone() declerations and definitions. Use StObject::clone() only.
34  *
35  * Revision 2.5 2002/02/22 22:56:47 jeromel
36  * Doxygen basic documentation in all header files. None of this is required
37  * for QM production.
38  *
39  * Revision 2.4 2001/04/05 04:00:35 ullrich
40  * Replaced all (U)Long_t by (U)Int_t and all redundant ROOT typedefs.
41  *
42  * Revision 2.3 2001/03/24 03:34:45 perev
43  * clone() -> clone() const
44  *
45  * Revision 2.2 2000/05/22 19:21:54 akio
46  * Bug fix, add delta into EMcPoint, wider bits for Eta in RawHit
47  *
48  * Revision 2.1 2000/03/23 22:24:07 akio
49  * Initial version of Emc Point, and Inclusion of track pointers
50  *
51  *
52  **************************************************************************/
53 #ifndef StEmcPoint_hh
54 #define StEmcPoint_hh
55 
56 #include "StHit.h"
57 #include "StEnumerations.h"
58 
59 class StEmcPoint : public StHit {
60 public:
61  StEmcPoint();
63  const StThreeVectorF&,
64  const StThreeVectorF&,
65  unsigned int, float,
66  float, float,
67  unsigned char = 0);
68  ~StEmcPoint();
69 
70  float energy() const;
71  float chiSquare() const;
72  void setEnergy(const float);
73  void setChiSquare(const float);
74  StThreeVectorF size() const;
75  void setSize(const StThreeVectorF&);
76 
77  float energyInDetector(const StDetectorId) const;
78  float sizeAtDetector(const StDetectorId) const;
79  void setEnergyInDetector(const StDetectorId, const float);
80  void setSizeAtDetector(const StDetectorId, const float);
81 
82  float deltaEta() const;
83  float deltaPhi() const;
84  float deltaU() const;
85  float deltaV() const;
86  void setDeltaEta(const float);
87  void setDeltaPhi(const float);
88  void setDeltaU(const float);
89  void setDeltaV(const float);
90 
91  StDetectorId detector() const;
92 
93  StPtrVecEmcCluster& cluster(const StDetectorId);
94  const StPtrVecEmcCluster& cluster(const StDetectorId) const;
95  StPtrVecEmcCluster& cluster(Int_t);
96  const StPtrVecEmcCluster& cluster(Int_t) const;
97 
98  void addCluster(const StDetectorId, const StEmcCluster*);
99 
100  StPtrVecEmcPoint& neighbor();
101  const StPtrVecEmcPoint& neighbor() const;
102 
103  void addNeighbor(const StEmcPoint*);
104 
105  int nTracks() const; // *MENU*
106  StPtrVecTrack& track();
107  const StPtrVecTrack& track() const;
108 
109  void addTrack(StTrack*);
110  // 11-nov-03 by PAI
111 
112  void print(); // *MENU*
113  void Print(Option_t *option = "") const;
114 
115  void setQuality(int qua) {myQuality = qua ;}
116  int quality() const {return myQuality;}
117 
118 protected:
119  Float_t mEnergy;
120  Float_t mChiSquare;
121  StThreeVectorF mSize;
122  Float_t mEnergyInDetector[4];
123  Float_t mSizeAtDetector[4];
124  Float_t mDelta[2];
125  StPtrVecEmcCluster mCluster[4];
126  StPtrVecEmcPoint mNeighbors;
127  StPtrVecTrack mTracks;
128  int myQuality;
129  int getDetId(const StDetectorId) const;
130  int getDetId(Int_t /* id */) const;
131  ClassDef(StEmcPoint,2)
132 };
133 
134 inline StDetectorId StEmcPoint::detector() const {return static_cast<StDetectorId>(StHit::bits(0, 4));}
135 
136 ostream& operator<<(ostream&, const StEmcPoint&); // Printing operator
137 #endif
138 
139 
Definition: StHit.h:125