Analysis Software
Documentation for sPHENIX simulation software
|
#include <JETSCAPE/blob/main/src/jet/HadronPrinter.h>
Public Member Functions | |
HadronPrinter () | |
virtual | ~HadronPrinter () |
virtual void | Init () |
virtual void | Exec () final |
virtual void | Clear () |
virtual void | WriteTask (weak_ptr< JetScapeWriter > w) |
void | SetFinalHadrons (vector< shared_ptr< Hadron >> &hadrons) |
void | PrintFinalHadron () |
Public Member Functions inherited from Jetscape::JetScapeModuleBase | |
JetScapeModuleBase () | |
JetScapeModuleBase (string m_name) | |
virtual | ~JetScapeModuleBase () |
void | SetXMLMainFileName (string m_name) |
string | GetXMLMainFileName () |
void | SetXMLUserFileName (string m_name) |
string | GetXMLUserFileName () |
shared_ptr< std::mt19937 > | GetMt19937Generator () |
tinyxml2::XMLElement * | GetXMLElement (std::initializer_list< const char * > path, bool isRequired=true) |
std::string | GetXMLElementText (std::initializer_list< const char * > path, bool isRequired=true) |
int | GetXMLElementInt (std::initializer_list< const char * > path, bool isRequired=true) |
double | GetXMLElementDouble (std::initializer_list< const char * > path, bool isRequired=true) |
Public Member Functions inherited from Jetscape::JetScapeTask | |
JetScapeTask () | |
virtual | ~JetScapeTask () |
virtual void | Finish () |
virtual void | ExecuteTasks () |
virtual void | ExecuteTask () |
virtual void | InitTask () |
virtual void | InitTasks () |
virtual void | ClearTasks () |
virtual void | ClearTask () |
virtual void | FinishTask () |
virtual void | FinishTasks () |
virtual void | WriteTasks (weak_ptr< JetScapeWriter > w) |
virtual void | CollectHeader (weak_ptr< JetScapeWriter > w) |
virtual void | CollectHeaders (weak_ptr< JetScapeWriter > w) |
virtual void | Add (shared_ptr< JetScapeTask > m_tasks) |
virtual const int | GetMyTaskNumber () const |
const vector< shared_ptr < JetScapeTask > > | GetTaskList () const |
shared_ptr< JetScapeTask > | GetTaskAt (int i) |
void | EraseTaskLast () |
void | EraseTaskAt (int i) |
void | ResizeTaskList (int i) |
void | ClearTaskList () |
int | GetNumberOfTasks () |
const bool | GetActive () const |
void | SetActive (bool m_active_exec) |
void | SetId (string m_id) |
const string | GetId () const |
const shared_ptr < JetScapeModuleMutex > | GetMutex () const |
void | SetMutex (shared_ptr< JetScapeModuleMutex > m_mutex) |
Public Member Functions inherited from sigslot::has_slots< sigslot::multi_threaded_local > | |
has_slots () | |
has_slots (const has_slots &hs) | |
void | signal_connect (_signal_base< sigslot::multi_threaded_local > *sender) |
void | signal_disconnect (_signal_base< sigslot::multi_threaded_local > *sender) |
virtual | ~has_slots () |
void | disconnect_all () |
Public Attributes | |
sigslot::signal1< vector < shared_ptr< Hadron > > & > | GetFinalHadronList |
Private Attributes | |
vector< shared_ptr< Hadron > > | finalHadrons |
std::ofstream | fHadronOutfile |
the output stream where events are saved to file | |
Static Private Attributes | |
static RegisterJetScapeModule < HadronPrinter > | reg |
Additional Inherited Members | |
Static Public Member Functions inherited from Jetscape::JetScapeModuleBase | |
static int | GetCurrentEvent () |
static void | IncrementCurrentEvent () |
Definition at line 30 of file HadronPrinter.h.
View newest version in sPHENIX GitHub at line 30 of file HadronPrinter.h
Jetscape::HadronPrinter::HadronPrinter | ( | ) |
Definition at line 23 of file HadronPrinter.cc.
View newest version in sPHENIX GitHub at line 23 of file HadronPrinter.cc
|
virtual |
Definition at line 27 of file HadronPrinter.cc.
View newest version in sPHENIX GitHub at line 27 of file HadronPrinter.cc
|
virtual |
A virtual function to define a default Clear() function for a JetScapeModuleBase. It can be overridden by different modules/tasks.
Reimplemented from Jetscape::JetScapeModuleBase.
Definition at line 48 of file HadronPrinter.cc.
View newest version in sPHENIX GitHub at line 48 of file HadronPrinter.cc
References finalHadrons.
|
finalvirtual |
A virtual function to define a default Exec() function for a JetScapeModuleBase. It can be overridden by different modules/tasks.
Reimplemented from Jetscape::JetScapeModuleBase.
Definition at line 41 of file HadronPrinter.cc.
View newest version in sPHENIX GitHub at line 41 of file HadronPrinter.cc
References finalHadrons, GetFinalHadronList, PrintFinalHadron(), and VERBOSE.
|
virtual |
A virtual function for a default initialization of a JetScapeModuleBase. It also checks whether a XML file is loaded or not.
Reimplemented from Jetscape::JetScapeModuleBase.
Definition at line 31 of file HadronPrinter.cc.
View newest version in sPHENIX GitHub at line 31 of file HadronPrinter.cc
References Jetscape::JetScapeSignalManager::ConnectGetFinalHadronListSignal(), fHadronOutfile, Jetscape::JetScapeSignalManager::Instance(), and Jetscape::JetScapeTask::SetId().
void Jetscape::HadronPrinter::PrintFinalHadron | ( | ) |
Definition at line 57 of file HadronPrinter.cc.
View newest version in sPHENIX GitHub at line 57 of file HadronPrinter.cc
References fHadronOutfile, finalHadrons, h, i, it, JSINFO, Jetscape::JetScapeParticleBase::pid(), and Jetscape::JetScapeParticleBase::pstat().
Referenced by Exec(), and SetFinalHadrons().
|
inline |
Definition at line 46 of file HadronPrinter.h.
View newest version in sPHENIX GitHub at line 46 of file HadronPrinter.h
References finalHadrons, and PrintFinalHadron().
|
virtual |
A virtual function to define a default WriteTask() function for a JetScapeTask. It can be overridden by different modules/tasks. Current setup: Every task gets handed a pointer to the writer and can add any information it likes to it (using predefined functions like WriteComment()) This is maximally flexible but makes it difficult to properly store information for a variety of outputs. E.g., sigmaGen: A HardProcess can easily write the xsec to any stream-type output using WriteComment. But to set it in a HepMC file, either HardProcess needs to make a case-by-case selection, meaning a new file format would need to percolate through multiple base classes, or the writer needs to know this information and implement WriteEvent appropriately. The latter is obviously better, but it's non-trivial to collect this information.
Reimplemented from Jetscape::JetScapeTask.
Definition at line 51 of file HadronPrinter.cc.
View newest version in sPHENIX GitHub at line 51 of file HadronPrinter.cc
References VERBOSE, and Jetscape::JetScapeTask::WriteTasks().
|
private |
the output stream where events are saved to file
Definition at line 56 of file HadronPrinter.h.
View newest version in sPHENIX GitHub at line 56 of file HadronPrinter.h
Referenced by Init(), and PrintFinalHadron().
|
private |
Definition at line 55 of file HadronPrinter.h.
View newest version in sPHENIX GitHub at line 55 of file HadronPrinter.h
Referenced by Clear(), Exec(), PrintFinalHadron(), and SetFinalHadrons().
sigslot::signal1<vector<shared_ptr<Hadron> >& > Jetscape::HadronPrinter::GetFinalHadronList |
Definition at line 44 of file HadronPrinter.h.
View newest version in sPHENIX GitHub at line 44 of file HadronPrinter.h
Referenced by Exec().
|
staticprivate |
Definition at line 59 of file HadronPrinter.h.
View newest version in sPHENIX GitHub at line 59 of file HadronPrinter.h