00001 // ================================================ 00002 // GridletForger class description 00003 // ================================================ 00004 // 00005 // Namespace Atlfast:: 00006 // 00007 // class: GridletForger 00008 // 00009 // Description: 00010 // 00011 // Entrance class to the Atlfast Shower Paramterisation 00012 // 00013 // 00014 // ................................................................ 00015 // 00016 00017 #ifndef FASTSHOWER_GRIDLETFORGER_H 00018 #define FASTSHOWER_GRIDLETFORGER_H 00019 00020 #ifndef ATLAS_IDEBUG_H 00021 #include "FastShowerUtils/IDebug.h" 00022 #endif 00023 00024 #ifndef ATLAS_DEBUGBASE_H 00025 #include "FastShowerUtils/DebugBase.h" 00026 #endif 00027 00028 #ifndef FASTSHOWER_SP_H 00029 #include "FastShowerUtils/SP.h" 00030 #endif 00031 00032 #ifndef FASTSHOWER_GRIDLET_H 00033 #include "FastShowerUtils/Gridlet.h" 00034 #endif 00035 00036 #ifndef FASTSHOWER_ISHOWERERSELECTOR_H 00037 #include "FastShowerUtils/IShowererSelector.h" 00038 #endif 00039 00040 #ifndef FASTSHOWER_PARTICLEPARAMETERS_H 00041 #include "FastShowerUtils/ParticleParameters.h" 00042 #endif 00043 00044 #ifndef FASTSHOWER_PARTICLEINFO_H 00045 #include "FastShowerUtils/ParticleInfo.h" 00046 #endif 00047 00048 #ifndef STD_VECTOR_H 00049 #define STD_VECTOR_H 00050 #include <vector> 00051 #endif 00052 00053 namespace FastShower{ 00062 // class TransportedParticleCollection; 00063 00064 class GridletForger: virtual public IDebug, private DebugBase{ 00065 public: 00067 GridletForger(); 00068 GridletForger(const std::string); 00069 GridletForger(std::vector<IShowererSelector*>); 00070 00072 00074 ~GridletForger(); 00075 00077 // Gridlet* makeGridlet(const TransportedParticleCollectionCIter&); 00078 // Gridlet* makeGridlet(ParticleParameters&); 00079 Gridlet* makeGridlet(ParticleInfo&) const; 00080 00082 virtual void components(IDebug::Cpts&) const; 00083 00084 private: 00085 00086 // ParticleParameters makeParameters(const TransportedParticleCollectionCIter&); 00087 // ParticleParameters makeParameters(const ParticleParameters&); 00088 ParticleParameters makeParameters(const ParticleInfo&) const; 00089 00091 std::vector<IShowererSelector*> m_showererSelectors; 00092 00093 //########################################################################## 00094 // function object used by STL algorithm find_if 00095 class selectShowerer{ 00096 public: 00097 selectShowerer(ParticleParameters& pp, Gridlet* g):m_pp(pp),m_g(g){} 00098 bool operator()(IShowererSelector* iss){ 00099 //selection conditions using pp 00100 return iss->accept(m_pp, m_g); 00101 } 00102 private: 00103 ParticleParameters m_pp; 00104 Gridlet* m_g; 00105 }; 00106 //########################################################################## 00107 00109 static const double phiStart; 00110 static const double phiStep; 00111 static const double etaStart; 00112 static const double etaStep; 00113 }; 00114 } 00115 00116 #endif 00117 00118 00119 00120