Public Member Functions | |
LHEWriter (const edm::ParameterSet ¶ms) | |
virtual | ~LHEWriter () |
Protected Member Functions | |
virtual void | analyze (const edm::Event &event, const edm::EventSetup &es) |
virtual void | beginRun (const edm::Run &run, const edm::EventSetup &es) |
virtual void | endRun (const edm::Run &run, const edm::EventSetup &es) |
Private Attributes | |
std::ofstream | file |
Definition at line 20 of file LHEWriter.cc.
LHEWriter::LHEWriter | ( | const edm::ParameterSet & | params | ) | [explicit] |
Definition at line 34 of file LHEWriter.cc.
{ }
LHEWriter::~LHEWriter | ( | ) | [virtual] |
Definition at line 38 of file LHEWriter.cc.
{ }
void LHEWriter::analyze | ( | const edm::Event & | event, |
const edm::EventSetup & | es | ||
) | [protected, virtual] |
Implements edm::EDAnalyzer.
Definition at line 58 of file LHEWriter.cc.
References filterCSVwithJSON::copy, and mergeVDriftHistosByStation::file.
{ edm::Handle<LHEEventProduct> product; event.getByLabel("source", product); std::copy(product->begin(), product->end(), std::ostream_iterator<std::string>(file)); }
void LHEWriter::beginRun | ( | const edm::Run & | run, |
const edm::EventSetup & | es | ||
) | [protected, virtual] |
Reimplemented from edm::EDAnalyzer.
Definition at line 42 of file LHEWriter.cc.
References filterCSVwithJSON::copy, mergeVDriftHistosByStation::file, edm::Run::getByLabel(), dbtoconf::out, and estimatePileup_makeJSON::trunc.
{ edm::Handle<LHERunInfoProduct> product; run.getByLabel("source", product); file.open("writer.lhe", std::fstream::out | std::fstream::trunc); std::copy(product->begin(), product->end(), std::ostream_iterator<std::string>(file)); }
void LHEWriter::endRun | ( | const edm::Run & | run, |
const edm::EventSetup & | es | ||
) | [protected, virtual] |
Reimplemented from edm::EDAnalyzer.
Definition at line 52 of file LHEWriter.cc.
References LHERunInfoProduct::endOfFile(), and mergeVDriftHistosByStation::file.
{ file << LHERunInfoProduct::endOfFile(); file.close(); }
std::ofstream LHEWriter::file [private] |
Definition at line 31 of file LHEWriter.cc.