CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_4_4_5_patch3/src/GeneratorInterface/LHEInterface/interface/LHEReader.h

Go to the documentation of this file.
00001 #ifndef GeneratorInterface_LHEInterface_LHEReader_h
00002 #define GeneratorInterface_LHEInterface_LHEReader_h
00003 
00004 #include <string>
00005 #include <vector>
00006 #include <memory>
00007 
00008 #include <boost/shared_ptr.hpp>
00009 
00010 #include "FWCore/ParameterSet/interface/ParameterSet.h"
00011 
00012 namespace lhef {
00013 
00014 class XMLDocument;
00015 class LHERunInfo;
00016 class LHEEvent;
00017 
00018 class LHEReader {
00019     public:
00020         LHEReader(const edm::ParameterSet &params);
00021         LHEReader(const std::vector<std::string> &fileNames,
00022                   unsigned int skip = 0);
00023         ~LHEReader();
00024 
00025         boost::shared_ptr<LHEEvent> next();
00026 
00027     private:
00028         class Source;
00029         class FileSource;
00030         class XMLHandler;
00031 
00032         const std::vector<std::string>  fileURLs;
00033         unsigned int                    firstEvent;
00034         int                             maxEvents;
00035         unsigned int                    curIndex;
00036 
00037         std::auto_ptr<Source>           curSource;
00038         std::auto_ptr<XMLDocument>      curDoc;
00039         boost::shared_ptr<LHERunInfo>   curRunInfo;
00040         std::auto_ptr<XMLHandler>       handler;
00041 };
00042 
00043 } // namespace lhef
00044 
00045 #endif // GeneratorInterface_LHEInterface_LHEReader_h