00001 // -*- C++ -*- 00002 // 00003 // MultiEventGenerator.h is a part of ThePEG - Toolkit for HEP Event Generation 00004 // Copyright (C) 1999-2007 Leif Lonnblad 00005 // 00006 // ThePEG is licenced under version 2 of the GPL, see COPYING for details. 00007 // Please respect the MCnet academic guidelines, see GUIDELINES for details. 00008 // 00009 #ifndef ThePEG_MultiEventGenerator_H 00010 #define ThePEG_MultiEventGenerator_H 00011 // This is the declaration of the MultiEventGenerator class. 00012 00013 #include "EventGenerator.h" 00014 00015 namespace ThePEG { 00016 00034 class MultiEventGenerator: public EventGenerator { 00035 00036 public: 00037 00043 virtual ~MultiEventGenerator(); 00045 00046 protected: 00047 00054 virtual void doGo(long next, long maxevent, bool tics); 00056 00065 string addInterface(string); 00066 00072 string removeInterface(string); 00074 00078 void heading(ostream &, long, const vector<const InterfaceBase *> &, string) const; 00079 00080 public: 00081 00082 00089 void persistentOutput(PersistentOStream & os) const; 00090 00096 void persistentInput(PersistentIStream & is, int version); 00098 00102 static void Init(); 00103 00104 protected: 00105 00112 virtual IBPtr clone() const; 00113 00118 virtual IBPtr fullclone() const; 00120 00121 protected: 00122 00134 virtual void rebind(const TranslationMap & trans); 00135 00141 virtual IVector getReferences(); 00143 00144 private: 00145 00147 typedef vector<string> StringVector; 00148 00152 IVector theObjects; 00153 00158 StringVector theInterfaces; 00159 00164 StringVector thePosArgs; 00165 00169 vector<StringVector> theValues; 00170 00171 private: 00172 00176 static ClassDescription<MultiEventGenerator> initMultiEventGenerator; 00177 00181 MultiEventGenerator & operator=(const MultiEventGenerator &); 00182 00183 }; 00184 00185 00190 template <> 00191 struct BaseClassTrait<MultiEventGenerator,1>: public ClassTraitsType { 00193 typedef EventGenerator NthBase; 00194 }; 00195 00199 template <> 00200 struct ClassTraits<MultiEventGenerator>: 00201 public ClassTraitsBase<MultiEventGenerator> { 00203 static string className() { return "ThePEG::MultiEventGenerator"; } 00207 static string library() { return "MultiEventGenerator.so"; } 00208 00209 }; 00210 00213 } 00214 00215 #endif /* ThePEG_MultiEventGenerator_H */