CbmRoot
Loading...
Searching...
No Matches
CbmMCPointSource Class Reference

#include <CbmMCPointSource.h>

Inheritance diagram for CbmMCPointSource:
[legend]
Collaboration diagram for CbmMCPointSource:
[legend]

Public Member Functions

 CbmMCPointSource ()=default
 
virtual ~CbmMCPointSource ()
 

Protected Member Functions

virtual void InitTask ()
 
virtual bool ConditionalRun ()
 

Protected Attributes

uint64_t fMaxEvents {0}
 
std::string fFileName {""}
 
std::vector< std::string > fInputFileList {}
 List of input files.
 
uint64_t fFileCounter {}
 
uint64_t fEventNumber {0}
 
uint64_t fEventCounter {0}
 
uint64_t fMessageCounter {0}
 
int fMaxMemory {0}
 

Private Member Functions

bool SendData ()
 
void CalcRuntime ()
 
void ConnectChannelIfNeeded (int, std::string, std::string, FairRootManager *)
 
template<class T >
void PrintMCPoint (TClonesArray *arr)
 
template<class T >
std::vector< T > Convert (TClonesArray *arr)
 
template<class T >
bool ConvertAndSend (TClonesArray *arr, int i)
 

Private Attributes

std::chrono::steady_clock::time_point fTime {}
 
std::vector< std::string > fAllowedChannels
 
CbmMQChannels fChan {fAllowedChannels}
 
std::vector< int > fComponentsToSend {}
 
std::vector< std::vector< std::string > > fChannelsToSend {{}}
 
std::vector< TClonesArray * > fArrays {fAllowedChannels.size(), nullptr}
 

Detailed Description

Definition at line 33 of file CbmMCPointSource.h.

Constructor & Destructor Documentation

◆ CbmMCPointSource()

CbmMCPointSource::CbmMCPointSource ( )
default

◆ ~CbmMCPointSource()

CbmMCPointSource::~CbmMCPointSource ( )
virtual

Definition at line 224 of file CbmMCPointSource.cxx.

Member Function Documentation

◆ CalcRuntime()

void CbmMCPointSource::CalcRuntime ( )
private

Definition at line 226 of file CbmMCPointSource.cxx.

References fTime.

Referenced by ConditionalRun().

◆ ConditionalRun()

bool CbmMCPointSource::ConditionalRun ( )
protectedvirtual

◆ ConnectChannelIfNeeded()

void CbmMCPointSource::ConnectChannelIfNeeded ( int chan_number,
std::string channel_name,
std::string branchname,
FairRootManager * rootman )
private

Definition at line 146 of file CbmMCPointSource.cxx.

References fArrays, and fComponentsToSend.

Referenced by InitTask().

◆ Convert()

template<class T >
std::vector< T > CbmMCPointSource::Convert ( TClonesArray * arr)
inlineprivate

Definition at line 75 of file CbmMCPointSource.h.

◆ ConvertAndSend()

template<class T >
bool CbmMCPointSource::ConvertAndSend ( TClonesArray * arr,
int i )
inlineprivate

Definition at line 93 of file CbmMCPointSource.h.

References fChannelsToSend, and fComponentsToSend.

Referenced by ConditionalRun().

◆ InitTask()

◆ PrintMCPoint()

template<class T >
void CbmMCPointSource::PrintMCPoint ( TClonesArray * arr)
inlineprivate

Definition at line 60 of file CbmMCPointSource.h.

◆ SendData()

bool CbmMCPointSource::SendData ( )
private

Member Data Documentation

◆ fAllowedChannels

std::vector<std::string> CbmMCPointSource::fAllowedChannels
private
Initial value:
= {"MvdPoint", "StsPoint", "RichPoint", "MuchPoint",
"Trdpoint", "TofPoint", "PsdPoint"}

Definition at line 139 of file CbmMCPointSource.h.

◆ fArrays

std::vector<TClonesArray*> CbmMCPointSource::fArrays {fAllowedChannels.size(), nullptr}
private

Definition at line 152 of file CbmMCPointSource.h.

Referenced by ConditionalRun(), ConnectChannelIfNeeded(), and InitTask().

◆ fChan

CbmMQChannels CbmMCPointSource::fChan {fAllowedChannels}
private

Definition at line 148 of file CbmMCPointSource.h.

Referenced by InitTask().

◆ fChannelsToSend

std::vector<std::vector<std::string> > CbmMCPointSource::fChannelsToSend {{}}
private

Definition at line 151 of file CbmMCPointSource.h.

Referenced by ConditionalRun(), ConvertAndSend(), and InitTask().

◆ fComponentsToSend

std::vector<int> CbmMCPointSource::fComponentsToSend {}
private

◆ fEventCounter

uint64_t CbmMCPointSource::fEventCounter {0}
protected

Definition at line 46 of file CbmMCPointSource.h.

Referenced by ConditionalRun().

◆ fEventNumber

uint64_t CbmMCPointSource::fEventNumber {0}
protected

Definition at line 45 of file CbmMCPointSource.h.

◆ fFileCounter

uint64_t CbmMCPointSource::fFileCounter {}
protected

Definition at line 43 of file CbmMCPointSource.h.

◆ fFileName

std::string CbmMCPointSource::fFileName {""}
protected

Definition at line 41 of file CbmMCPointSource.h.

Referenced by InitTask().

◆ fInputFileList

std::vector<std::string> CbmMCPointSource::fInputFileList {}
protected

List of input files.

Definition at line 42 of file CbmMCPointSource.h.

◆ fMaxEvents

uint64_t CbmMCPointSource::fMaxEvents {0}
protected

Definition at line 39 of file CbmMCPointSource.h.

Referenced by ConditionalRun(), and InitTask().

◆ fMaxMemory

int CbmMCPointSource::fMaxMemory {0}
protected

Definition at line 49 of file CbmMCPointSource.h.

◆ fMessageCounter

uint64_t CbmMCPointSource::fMessageCounter {0}
protected

Definition at line 47 of file CbmMCPointSource.h.

◆ fTime

std::chrono::steady_clock::time_point CbmMCPointSource::fTime {}
private

Definition at line 137 of file CbmMCPointSource.h.

Referenced by CalcRuntime(), and InitTask().


The documentation for this class was generated from the following files: