EIC Software
Reference for
EIC
simulation and reconstruction software on GitHub
|
#include <eic-smear/blob/master/include/eicsmear/erhic/File.h>
Public Member Functions | |
LogReader * | CreateReader (const EventBase &event) const |
LogReader * | CreateReader (const std::string &name) const |
LogReader * | CreateReader (std::istream &) const |
std::string | Locate (const std::string &mcFile) const |
Static Public Member Functions | |
static LogReaderFactory & | GetInstance () |
Protected Types | |
typedef std::map< std::string, LogReader * > | Map |
Protected Member Functions | |
LogReaderFactory () | |
~LogReaderFactory () | |
Protected Attributes | |
Map | prototypes_ |
Factory class for LogReaders.
Singleton class. Creates a LogReader instance corresponding to a Monte Carlo generator type.
Definition at line 364 of file File.h.
View newest version in sPHENIX GitHub at line 364 of file File.h
|
protected |
|
protected |
Constructor.
Definition at line 473 of file File.cxx.
View newest version in sPHENIX GitHub at line 473 of file File.cxx
References prototypes_.
|
protected |
Destructor.
Definition at line 485 of file File.cxx.
View newest version in sPHENIX GitHub at line 485 of file File.cxx
References prototypes_.
Returns a LogReader instance of the type for reading log files from the Monte Carlo generator event type 'event'. Returns NULL in the case of an unsupported generator. The LogReader must be deleted by the user.
Definition at line 364 of file File.cxx.
View newest version in sPHENIX GitHub at line 364 of file File.cxx
References name.
Referenced by erhic::File< T >::CreateLogReader(), and CreateReader().
LogReader * erhic::LogReaderFactory::CreateReader | ( | const std::string & | name | ) | const |
Returns a LogReader instance of the type for reading log files from the Monte Carlo generator named 'name'. Returns NULL in the case of an unsupported generator. The LogReader must be deleted by the user.
Definition at line 380 of file File.cxx.
View newest version in sPHENIX GitHub at line 380 of file File.cxx
References prototypes_, and reader().
LogReader * erhic::LogReaderFactory::CreateReader | ( | std::istream & | is | ) | const |
Returns a LogReader instance of the type for reading log files from the Monte Carlo generator which produced the content in an istream, by reading the first line of that stream. Returns NULL in the case of an unsupported generator. The LogReader must be deleted by the user.
Returns a LogReader instance of the type for reading log files from the Monte Carlo generator named 'name'. Returns NULL in the case of an unsupported generator. The LogReader must be deleted by the user.
Definition at line 398 of file File.cxx.
View newest version in sPHENIX GitHub at line 398 of file File.cxx
References CreateReader(), getline, and reader().
|
static |
Returns the single instance of LogReaderFactory.
Definition at line 353 of file File.cxx.
View newest version in sPHENIX GitHub at line 353 of file File.cxx
Referenced by BuildTree(), and erhic::File< T >::CreateLogReader().
std::string erhic::LogReaderFactory::Locate | ( | const std::string & | mcFile | ) | const |
Attempts to locate a log file corresponding to the named Monte Carlo file. Searches for a file with the same base name and extension '.log'. Looks in the current directory and, if mcFile gives a path containing 'TXTFILES', in the corresonding directory substituting 'LOGFILES'.
Definition at line 428 of file File.cxx.
View newest version in sPHENIX GitHub at line 428 of file File.cxx
References configureMap::inFileName.
Referenced by BuildTree().
|
protected |
Definition at line 418 of file File.h.
View newest version in sPHENIX GitHub at line 418 of file File.h
Referenced by CreateReader(), LogReaderFactory(), and ~LogReaderFactory().