StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StMuFmsPoint.h
1 /*****************************************************************************
2  *
3  * $Id: StMuFmsPoint.h,v 1.3 2015/10/16 18:13:28 jdb Exp $
4  *
5  * Author: Thomas Burton, 2014
6  *****************************************************************************
7  *
8  * Description: Declaration of StMuFmsPoint, the MuDST FMS "point" class
9  *
10  *****************************************************************************
11  *
12  * $Log: StMuFmsPoint.h,v $
13  * Revision 1.3 2015/10/16 18:13:28 jdb
14  * incremented version # for StMuFmsCollection and StMuFmsPoint
15  *
16  * Revision 1.2 2015/09/02 22:09:58 jdb
17  * Added Akios changes to Fms
18  *
19  *
20  *****************************************************************************/
21 #ifndef STROOT_STMUDSTMAKER_COMMON_STMUFMSPOINT_H_
22 #define STROOT_STMUDSTMAKER_COMMON_STMUFMSPOINT_H_
23 
24 #include "StLorentzVectorF.hh"
25 #include "StThreeVectorF.hh"
26 #include <TObject.h>
27 #include <TRef.h>
28 
29 class StFmsPoint; // The equivalent point structure in StEvent
30 class StMuFmsCluster;
31 
42 class StMuFmsPoint : public TObject {
43  public:
44  StMuFmsPoint(int detectorId = 0, float energy = 0.f,
45  float x = 0.f, float y = 0.f, int id = 0);
46  explicit StMuFmsPoint(const StFmsPoint&);
47  virtual ~StMuFmsPoint();
48 
49  StThreeVectorF momentum(float m = 0.f, float zvertex=0.f) const;
50  StLorentzVectorF fourMomentum(float m = 0.f, float zvertex=0.f) const;
51  StMuFmsCluster* cluster();
52  const StMuFmsCluster* cluster() const;
53  unsigned short detectorId() const;
54  float energy() const;
55  float x() const; // x "center of gravity" of the point (cm) in local coordinate
56  float y() const; // y "center of gravity" of the point (cm) in local coordinate
57  int id() const;
58  StThreeVectorF xyz() const; // XYZ in STAR coordinate
59  void setDetectorId(unsigned short detector);
60  void setEnergy(float energy);
61  void setX(float x);
62  void setY(float y);
63  void setId(int id);
64  void set(const StFmsPoint& point);
65  void setXYZ(const StThreeVectorF xyz);
66  void setCluster(StMuFmsCluster* cluster);
67 
68  protected:
69  UShort_t mDetectorId;
70  Float_t mEnergy;
71  Float_t mX;
72  Float_t mY;
73  Int_t mId;
74  StThreeVectorF mXYZ; // STAR coodinate XYZ
75  TRef mCluster;
76 
77  private:
83  StMuFmsPoint(const StMuFmsPoint&);
89  StMuFmsPoint& operator=(const StMuFmsPoint&);
90  ClassDef(StMuFmsPoint, 2)
91 };
92 
93  inline unsigned short StMuFmsPoint::detectorId() const { return mDetectorId; }
94  inline float StMuFmsPoint::energy() const { return mEnergy; }
95  inline float StMuFmsPoint::x() const { return mX; } // x "center of gravity" of the point (cm).
96  inline float StMuFmsPoint::y() const { return mY; } // y "center of gravity" of the point (cm).
97  inline int StMuFmsPoint::id() const { return mId; }
98  inline StThreeVectorF StMuFmsPoint::xyz() const { return mXYZ; }
99  inline void StMuFmsPoint::setDetectorId(unsigned short detector) { mDetectorId = detector; }
100  inline void StMuFmsPoint::setEnergy(float energy) { mEnergy = energy; }
101  inline void StMuFmsPoint::setX(float x) { mX = x; }
102  inline void StMuFmsPoint::setY(float y) { mY = y; }
103  inline void StMuFmsPoint::setId(int id) { mId = id; }
104  inline void StMuFmsPoint::setXYZ(StThreeVectorF xyz) {mXYZ = xyz;}
105 
106 #endif // STROOT_STMUDSTMAKER_COMMON_STMUFMSPOINT_H_
Float_t mEnergy
Total energy contained in the point.
Definition: StMuFmsPoint.h:70
Float_t mX
Mean x (&quot;center of gravity&quot;)
Definition: StMuFmsPoint.h:71
TRef mCluster
Parent cluster of this photon.
Definition: StMuFmsPoint.h:75
Float_t mY
Mean y (&quot;center of gravity&quot;)
Definition: StMuFmsPoint.h:72
StThreeVectorF mXYZ
point Id
Definition: StMuFmsPoint.h:74
UShort_t mDetectorId
Detector ID as defined in database.
Definition: StMuFmsPoint.h:69