00001 // $Header: /cvs/lcd/slic/include/StdHepEventSource.hh,v 1.8 2007/04/27 01:54:32 jeremy Exp $ 00002 00003 #ifndef SLIC_STDHEPEVENTSOURCE_HH 00004 #define SLIC_STDHEPEVENTSOURCE_HH 1 00005 00006 // slic 00007 #include "StdHepLoader.hh" 00008 #include "StdHepToLcioConvertor.hh" 00009 #include "EventSourceWithInputFile.hh" 00010 00011 namespace slic 00012 { 00018 class StdHepEventSource : public EventSourceWithInputFile 00019 { 00020 public: 00021 StdHepEventSource(const std::string& fname); 00022 00023 public: 00024 00025 virtual void generate(G4Event* anEvent); 00026 00027 // open the current file 00028 virtual void open(); 00029 00030 // close the current file 00031 virtual void close(); 00032 00033 // read the next event 00034 virtual void readNextEvent(); 00035 00036 virtual void dumpCurrentEvent(); 00037 00038 virtual void beginRun(const G4Run* aRun); 00039 00040 virtual void beginEvent(const G4Event* anEvent); 00041 00042 private: 00043 StdHepLoader* m_loader; 00044 StdHepToLcioConvertor* m_convertor; 00045 }; 00046 } 00047 00048 #endif
1.5.4