00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef STSSDPOINT_HH
00018 #define STSSDPOINT_HH
00019 #include "Rtypes.h"
00020 class StSsdPoint
00021 {
00022 public:
00023 StSsdPoint(Int_t rNPoint, Int_t rNWafer, Int_t rNumPackage, Int_t rKindPackage);
00024 StSsdPoint(Int_t rNId , Int_t rMcHit , Int_t rMcTrack , Float_t *rXg , Float_t rDe, Float_t *rAngle);
00025 StSsdPoint(const StSsdPoint & originalPoint);
00026 ~StSsdPoint() {}
00027
00028 StSsdPoint& operator=(const StSsdPoint originalPoint);
00029
00030 void setAngle(Float_t rAngle, Int_t iR) { mAngle[iR] = rAngle; }
00031 void setDe(Float_t rEnergyLoss, Int_t iR) { mDe[iR] = rEnergyLoss; }
00032 void setEnergyLoss(Float_t adcP, Float_t adcN) {setDe((adcP + adcN)/2.,0); setDe((adcP - adcN)/2.,1); }
00033 void setEnergyLossCorrected(Float_t adcP,Float_t adcN, Float_t gain);
00034 void setFlag(Int_t rFlag) { mFlag = rFlag; }
00035 void setIdClusterP(Int_t iIdClusterP) { mIdClusterP = iIdClusterP; }
00036 void setIdClusterN(Int_t iIdClusterN) { mIdClusterN = iIdClusterN; }
00037 void setMcHit(Int_t rMcHit, Int_t i = 0) {setNMchit(rMcHit,i);}
00038 void setMcTrack(Int_t rMcTrack) { mMcTrack = rMcTrack; }
00039 void setNextPoint(StSsdPoint *rNextPoint) { mNextPoint = rNextPoint; }
00040 void setNId(Int_t rNId) { mNId = rNId; }
00041 void setNPoint(Int_t rNPoint) { mNPoint = rNPoint; }
00042 void setNCluster(Int_t rNCluster) { mNCluster = rNCluster; }
00043 void setNMatched(Int_t rNMatched) { mNMatched = rNMatched; }
00044 void setNMchit(Int_t rNMchit, Int_t iR=0) { mMcHit[iR] = rNMchit; }
00045 void setNWafer(Int_t rNWafer) { mNWafer = rNWafer; }
00046 void setPrevPoint(StSsdPoint *rPrevPoint) { mPrevPoint = rPrevPoint; }
00047 void setPositionU(Float_t rPositionU, Int_t iR) { mPositionU[iR] = rPositionU; }
00048 void setUpos(Float_t rUpos, Int_t iR) {setPositionU(rUpos,iR);}
00049 void setXg(Float_t rXg, Int_t iR) { mXg[iR] = rXg; }
00050 void setXl(Float_t rXl, Int_t iR) { mXl[iR] = rXl; }
00051
00052
00053 Float_t getDe(Int_t iR=0) { return mDe[iR]; }
00054 Int_t getIdClusterP() { return mIdClusterP; }
00055 Int_t getIdClusterN() { return mIdClusterN; }
00056 Int_t getFlag() { return mFlag; }
00057 Int_t getMcHit(Int_t i=0) { return getNMchit(i); }
00058 Int_t getMcTrack() { return mMcTrack; }
00059 Int_t getNId() { return mNId; }
00060 Int_t getNPoint() { return mNPoint; }
00061 Int_t getNCluster() { return mNCluster; }
00062 Int_t getNMatched() { return mNMatched; }
00063 Int_t getNMchit(Int_t iR) { return mMcHit[iR]; }
00064 Int_t getNWafer() { return mNWafer; }
00065 Float_t getPositionU(Int_t iR) { return mPositionU[iR]; }
00066 Float_t getXg(Int_t iR) { return mXg[iR]; }
00067
00068 Float_t getXl(Int_t iR) { return mXl[iR]; }
00069
00070 StSsdPoint* getPrevPoint() { return mPrevPoint; }
00071 StSsdPoint* getNextPoint() { return mNextPoint; }
00072
00073 StSsdPoint* giveCopy();
00074
00075 private:
00076 Char_t first[1];
00077 Int_t mNId;
00078 Int_t mMcHit[5];
00079 Int_t mMcTrack;
00080 Int_t mFlag;
00081 Int_t mNPoint;
00082 Int_t mNCluster;
00083 Int_t mNMatched;
00084 Int_t mIdClusterP;
00085 Int_t mIdClusterN;
00086 Int_t mNWafer;
00087 Float_t mDe[2];
00088 Float_t mPositionU[2];
00089 Float_t mAngle[2];
00090 Float_t mXg[3];
00091
00092 Float_t mXl[3];
00093
00094 StSsdPoint *mPrevPoint;
00095 StSsdPoint *mNextPoint;
00096 Char_t last[1];
00097 };
00098
00099 #endif