CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
lhef::LHEReader::StringSource Class Reference
Inheritance diagram for lhef::LHEReader::StringSource:
lhef::LHEReader::Source

Public Member Functions

XMLDocumentcreateReader (XMLDocument::Handler &handler) override
 
 StringSource (const std::string &inputs)
 
 ~StringSource () override
 
- Public Member Functions inherited from lhef::LHEReader::Source
 Source ()
 
virtual ~Source ()
 

Private Attributes

std::unique_ptr< std::istream > fileStream
 

Detailed Description

Definition at line 67 of file LHEReader.cc.

Constructor & Destructor Documentation

◆ StringSource()

lhef::LHEReader::StringSource::StringSource ( const std::string &  inputs)
inline

Definition at line 69 of file LHEReader.cc.

69  {
70  if (inputs.empty())
71  throw cms::Exception("StreamOpenError") << "Empty LHE file string name \"" << std::endl;
72 
73  std::stringstream *tmpis = new std::stringstream(inputs);
74  fileStream.reset(tmpis);
75  }

References fileStream, and PixelMapPlotter::inputs.

◆ ~StringSource()

lhef::LHEReader::StringSource::~StringSource ( )
inlineoverride

Definition at line 77 of file LHEReader.cc.

77 {}

Member Function Documentation

◆ createReader()

XMLDocument* lhef::LHEReader::StringSource::createReader ( XMLDocument::Handler handler)
inlineoverridevirtual

Implements lhef::LHEReader::Source.

Definition at line 79 of file LHEReader.cc.

79 { return new XMLDocument(fileStream, handler); }

References fileStream, and lhef::LHEReader::handler.

Member Data Documentation

◆ fileStream

std::unique_ptr<std::istream> lhef::LHEReader::StringSource::fileStream
private

Definition at line 82 of file LHEReader.cc.

Referenced by createReader(), and StringSource().

XMLDocument
Definition: HcalDbXml.cc:60
PixelMapPlotter.inputs
inputs
Definition: PixelMapPlotter.py:490
lhef::LHEReader::StringSource::fileStream
std::unique_ptr< std::istream > fileStream
Definition: LHEReader.cc:82
cms::Exception
Definition: Exception.h:70
lhef::LHEReader::handler
std::unique_ptr< XMLHandler > handler
Definition: LHEReader.h:41