EIC Software
Reference for
EIC
simulation and reconstruction software on GitHub
|
#include <EicRoot/blob/master/cbmdata/CbmMCEpoch.h>
Public Member Functions | |
CbmMCEpoch () | |
CbmMCEpoch (Double_t startTime, Double_t epochLength) | |
virtual | ~CbmMCEpoch () |
void | AddPoint (DetectorId det, FairMCPoint *point, Int_t eventId=-1, Double_t eventTime=0.) |
void | Clear () |
Int_t | GetNofPoints (DetectorId det) const |
TClonesArray * | GetPoints (DetectorId det) |
FairMCPoint * | GetPoint (DetectorId det, Int_t index) |
Double_t | GetStartTime () |
Bool_t | IsEmpty () |
virtual void | Print (Option_t *opt="") const |
void | SetStartTime (Double_t time) |
Private Member Functions | |
void | CreateArrays () |
CbmMCEpoch (const CbmMCEpoch &) | |
CbmMCEpoch & | operator= (const CbmMCEpoch &) |
ClassDef (CbmMCEpoch, 1) | |
Private Attributes | |
Double_t | fStartTime |
Double_t | fEpochLength |
TClonesArray * | fPoints [kTutDet] |
CBM data class representing one read-out epoch (time slice) on MC level. It manages all CBM MCPoint collections within this time slice in arrays. Within each array, the points are sorted w.r.t. time.
Definition at line 30 of file CbmMCEpoch.h.
View newest version in sPHENIX GitHub at line 30 of file CbmMCEpoch.h
CbmMCEpoch::CbmMCEpoch | ( | ) |
Default constructor
Definition at line 21 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 21 of file CbmMCEpoch.cxx
References CreateArrays().
CbmMCEpoch::CbmMCEpoch | ( | Double_t | startTime, |
Double_t | epochLength | ||
) |
Standard constructor
startTime | Begin of epoch [ns] |
epochLength | Duration of epoch [ns] |
Definition at line 34 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 34 of file CbmMCEpoch.cxx
References CreateArrays().
|
virtual |
Destructor
Definition at line 48 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 48 of file CbmMCEpoch.cxx
|
private |
void CbmMCEpoch::AddPoint | ( | DetectorId | det, |
FairMCPoint * | point, | ||
Int_t | eventId = -1 , |
||
Double_t | eventTime = 0. |
||
) |
Add one MCPoint The point will be copied to the internal array using its copy constructor. The original object is kept. The point time is recalculated relative to the epoch start time.
det | Detector system identifier |
stsPoint | Pointer to MCPoint to be added |
eventId | Event identifier (negative value keeps original event Id) |
eventTime | MC event time |
Definition at line 55 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 55 of file CbmMCEpoch.cxx
References FairLogger::endl(), FATAL, fPoints, fStartTime, GetNofPoints(), kMUCH, and kSTS.
|
private |
void CbmMCEpoch::Clear | ( | ) |
Clear data
Definition at line 89 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 89 of file CbmMCEpoch.cxx
References fPoints, fStartTime, kREF, and kTutDet.
|
private |
Array of arrays with MCPoints Create MCPoint arrays Used from the constructors.
Definition at line 182 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 182 of file CbmMCEpoch.cxx
References fPoints, kMUCH, kREF, kSTS, and kTutDet.
Referenced by CbmMCEpoch().
Int_t CbmMCEpoch::GetNofPoints | ( | DetectorId | det | ) | const |
Get number of points in this epoch for a given detector
det | Detector system identifier |
Definition at line 106 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 106 of file CbmMCEpoch.cxx
References fPoints.
Referenced by AddPoint(), GetPoint(), IsEmpty(), and Print().
FairMCPoint * CbmMCEpoch::GetPoint | ( | DetectorId | det, |
Int_t | index | ||
) |
Get an MCPoint for a given detector
det | Detector system identifier |
index | Index of point in array Check for index range included. |
Definition at line 122 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 122 of file CbmMCEpoch.cxx
References fPoints, and GetNofPoints().
|
inline |
Get array of MC points for a given detector
Definition at line 75 of file CbmMCEpoch.h.
View newest version in sPHENIX GitHub at line 75 of file CbmMCEpoch.h
References fPoints.
|
inline |
Get epoch start time
Definition at line 87 of file CbmMCEpoch.h.
View newest version in sPHENIX GitHub at line 87 of file CbmMCEpoch.h
References fStartTime.
Bool_t CbmMCEpoch::IsEmpty | ( | ) |
Check whether epoch is empty (no MC points)
Definition at line 145 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 145 of file CbmMCEpoch.cxx
References fPoints, GetNofPoints(), kREF, and kTutDet.
|
private |
|
virtual |
Print info
Definition at line 163 of file CbmMCEpoch.cxx.
View newest version in sPHENIX GitHub at line 163 of file CbmMCEpoch.cxx
References fPoints, fStartTime, GetNofPoints(), CbmDetectorList::GetSystemName(), kREF, and kTutDet.
|
inline |
Set epoch start time
Definition at line 99 of file CbmMCEpoch.h.
View newest version in sPHENIX GitHub at line 99 of file CbmMCEpoch.h
References fStartTime, and Acts::Test::time.
|
private |
Start time of epoch [ns]
Definition at line 107 of file CbmMCEpoch.h.
View newest version in sPHENIX GitHub at line 107 of file CbmMCEpoch.h
|
private |
Duration of epoch [ns]
Definition at line 109 of file CbmMCEpoch.h.
View newest version in sPHENIX GitHub at line 109 of file CbmMCEpoch.h
Referenced by AddPoint(), Clear(), CreateArrays(), GetNofPoints(), GetPoint(), GetPoints(), IsEmpty(), and Print().
|
private |
Definition at line 106 of file CbmMCEpoch.h.
View newest version in sPHENIX GitHub at line 106 of file CbmMCEpoch.h
Referenced by AddPoint(), Clear(), GetStartTime(), Print(), and SetStartTime().