00001 #ifndef CsIClusterList_H 00002 #define CsIClusterList_H 00003 00004 #include <vector> 00005 #include "geometry/Point.h" 00006 #include "geometry/Vector.h" 00007 // #include "Event/trsDataVI.h" 00008 #include "GaudiKernel/DataObject.h" 00009 00010 #include "GlastEvent/Recon/ICsIClusters.h" 00011 00012 #include "CalRecon/CalDisplay.h" 00013 00014 extern const CLID& CLID_CalClusterList; 00015 00016 00017 //---------------------------------------------- 00018 // 00019 // CsICluster 00020 // 00021 // Transient Storage Data 00022 //---------------------------------------------- 00023 // It contains the high level data for the Calorimeter 00024 //---------------------------------------------- 00025 // J.A Hernando, Santa Cruz 02/29/00 00026 //---------------------------------------------- 00027 00029 00044 //##################################### 00045 class CsICluster : public ICsICluster 00046 //##################################### 00047 { 00048 public: 00049 00051 CsICluster(double e, Point p); 00052 00054 ~CsICluster() {} 00055 00056 void setDirection(Vector v) {m_direction = v;} 00057 00059 00061 void setEnergyCorrected(double e) {m_energyCorrected = e;} 00063 void setEneLayer(std::vector<double> v){m_eneLayer = v;} 00065 void setPosLayer(std::vector<Vector> v){m_pLayer = v;} 00067 void setRmsLayer(std::vector<Vector> v){m_rmsLayer = v;} 00069 void setRmsLong(double r) {m_rmslong=r;} 00071 void setRmsTrans(double r) {m_rmstrans=r;} 00073 void setEneLeak(double e) {m_leakEnergy = e;} 00075 void setFitEnergy(double e) { m_fitEnergy = e;} 00077 void setProfChisq(double k) { m_ProfChisq = k;} 00079 void setCsiAlpha(double a) { m_CsiAlpha =a;} 00081 void setCsiLambda(double l) { m_CsiLambda = l;} 00083 void setCsiStart(double s) { m_start = s;} 00085 void setTransvOffset (double offset) {m_transvOffset = offset;} 00086 00087 // access 00088 double energySum() const {return m_energySum;} 00089 double energyLeak() const {return m_leakEnergy;} 00090 double energyCorrected() const {return m_energyCorrected;} 00091 double getEneLayer(int i) const {return m_eneLayer[i];} 00092 const Vector& getPosLayer(int i) const {return m_pLayer[i];} 00093 const std::vector<double>& getEneLayer() const {return m_eneLayer;} 00094 const std::vector<Vector>& getPosLayer() const {return m_pLayer;} 00095 const std::vector<Vector>& getRmsLayer() const {return m_rmsLayer;} 00096 double getRmsLong() const {return m_rmslong;} 00097 double getRmsTrans() const {return m_rmstrans;} 00098 double getTransvOffset() const {return m_transvOffset;} 00099 00100 Point position() const {return m_position;} 00101 Vector direction() const {return m_direction;} 00102 double getFitEnergy() const {return m_fitEnergy;} 00103 double getProfChisq() const {return m_ProfChisq;} 00104 double getCsiAlpha() const {return m_CsiAlpha;} 00105 double getCsiLambda() const {return m_CsiLambda;} 00106 double getCsiStart() const {return m_start;} 00107 // operations 00108 void writeOut() const; 00109 00110 protected: 00111 00112 virtual void ini(); 00113 00114 private: 00115 00117 double m_energySum; 00119 double m_leakEnergy; 00121 double m_energyCorrected; 00123 std::vector<double> m_eneLayer; 00125 std::vector<Vector> m_pLayer; 00127 std::vector<Vector> m_rmsLayer; 00129 double m_rmslong; 00131 double m_rmstrans; 00133 double m_transvOffset; 00134 00136 double m_fitEnergy; 00138 double m_ProfChisq; 00140 double m_CsiAlpha; 00142 double m_CsiLambda; 00144 double m_start; 00145 00146 Point m_position; 00147 Vector m_direction; 00148 }; 00149 00150 00152 00165 //##################################### 00166 class CsIClusterList : public ICsIClusterList 00167 //##################################### 00168 { 00169 public: 00170 00171 CsIClusterList() { m_calDisp = 0;clear();} 00172 ~CsIClusterList() { if(m_calDisp) m_calDisp->clearClusterDisp();clear();} 00173 00174 00175 // GAUDI members to be use by the converters 00176 static const CLID& classID() {return CLID_CalClusterList;} 00177 virtual const CLID& clID() const {return classID();} 00178 00179 00180 void add(CsICluster* cl) {m_CsIClustersList.push_back(cl);} 00181 00182 // access 00183 int num() const {return m_CsIClustersList.size();} 00184 ICsICluster* Cluster(int i) const {return m_CsIClustersList[i];} 00185 00186 //operations 00187 virtual void clear(); 00188 virtual void make() {} 00189 00190 virtual void writeOut() const; 00191 void setCalDisplay(CalDisplay* calDisp) {m_calDisp = calDisp;} 00192 00193 protected: 00194 00195 virtual void ini(); 00196 00197 private: 00198 00199 std::vector<CsICluster*> m_CsIClustersList; 00200 00201 CalDisplay* m_calDisp; 00202 }; 00203 #endif 00204 00205 00206 00207 00208 00209