Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members  

SiRecObjs.h

Go to the documentation of this file.
00001 
00002 #ifndef __SIRECOBJS_H
00003 #define __SIRECOBJS_H 1
00004 
00005 #include <vector>
00006 #include "GaudiKernel/MsgStream.h"
00007 #include "GaudiKernel/DataObject.h"
00008 #include "TkrRecon/GFcandidates.h"
00009 #include "GlastEvent/Recon/ISiRecObjs.h"
00010 
00011 #include "gui/DisplayRep.h"
00012 
00013 //----------------------------------------------
00014 //
00015 //   SiRecObjs
00016 //
00017 //   Transient Storage Data
00018 //----------------------------------------------
00019 //   It contains the high level recostructed objects
00020 //   of the tracker (gammas and tracks)
00021 //----------------------------------------------
00022 //             J.A Hernando, Santa Cruz 02/29/00
00023 //----------------------------------------------
00024 
00025 extern const CLID& CLID_SiRecObjs;
00026 //const static CLID CLID_SiRecObjs = 254;
00027 
00031 //##########################################################
00032 class SiRecObjs : public ISiRecObjs
00033 //##########################################################
00034 {
00035 
00036 public:
00037 
00039         SiRecObjs()  {ini();}
00041         virtual ~SiRecObjs() {clear();}
00042         
00043         // GAUDI members to be use by the converters
00044         static const CLID& classID() {return CLID_SiRecObjs;}
00045         virtual const CLID& clID() const {return classID();}
00046 
00048         void addGamma(GFgamma* g)       {m_GFgammaList.push_back(g);}
00050         void addParticle(GFparticle* p) {m_GFparticleList.push_back(p);}
00051 
00053         int numGammas() const                                       {return m_GFgammaList.size();}
00055         GFgamma*  Gamma(int i)   const              {return m_GFgammaList[i];}
00057         int numParticles() const                                    {return m_GFparticleList.size();}
00059         GFparticle* Particle(int i) const                       {return m_GFparticleList[i];}
00060         
00062         void update(gui::DisplayRep& v) {draw(v);}
00063 
00065         virtual void clear();
00067         virtual void make() {}
00069         virtual void writeOut(MsgStream& log) const;
00070 
00071     //new methods required for the interface
00073     double getXGFparticleSlope(int i) {return m_GFparticleList[i]->getXGFtrack()->slope();}
00075         double getYGFparticleSlope(int i) { return m_GFparticleList[i]->getYGFtrack()->slope();}
00077     Point getGammaVertex(int i) { return m_GFgammaList[i]->vertex(); }
00079     Vector getGammaDirection(int i) { return m_GFgammaList[i]->direction(); }
00081     double getXGFgammaSlope(int i) {return m_GFgammaList[i]->getPair(SiCluster::X)->slope(); }
00083     double getYGFgammaSlope(int i) { return m_GFgammaList[i]->getPair(SiCluster::Y)->slope(); }
00084 
00085 private:
00086 
00088         virtual void ini();
00090 //      void draw(GraphicsRep& v);
00091         void draw(gui::DisplayRep& v);
00092 
00093 private:
00094 
00096         std::vector<GFparticle*> m_GFparticleList;
00098         std::vector<GFgamma*> m_GFgammaList;
00099 };
00100       
00101 #endif

Generated at Wed Nov 21 12:21:21 2001 by doxygen1.2.3 written by Dimitri van Heesch, © 1997-2000