EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
CbmMCEpoch Class Reference

#include <EicRoot/blob/master/cbmdata/CbmMCEpoch.h>

+ Inheritance diagram for CbmMCEpoch:
+ Collaboration diagram for CbmMCEpoch:

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)
 
FairMCPointGetPoint (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 &)
 
CbmMCEpochoperator= (const CbmMCEpoch &)
 
 ClassDef (CbmMCEpoch, 1)
 

Private Attributes

Double_t fStartTime
 
Double_t fEpochLength
 
TClonesArray * fPoints [kTutDet]
 

Detailed Description

CbmMCEpoch.h

Author
Volker Friese v.fri.nosp@m.ese@.nosp@m.gsi.d.nosp@m.e
Since
13.11.2009
Version
1.0

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

Constructor & Destructor Documentation

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().

+ Here is the call graph for this function:

CbmMCEpoch::CbmMCEpoch ( Double_t  startTime,
Double_t  epochLength 
)
Standard constructor 
Parameters
startTimeBegin of epoch [ns]
epochLengthDuration 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().

+ Here is the call graph for this function:

CbmMCEpoch::~CbmMCEpoch ( )
virtual

Destructor

Definition at line 48 of file CbmMCEpoch.cxx.

View newest version in sPHENIX GitHub at line 48 of file CbmMCEpoch.cxx

CbmMCEpoch::CbmMCEpoch ( const CbmMCEpoch )
private

Member Function Documentation

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.
Parameters
detDetector system identifier
stsPointPointer to MCPoint to be added
eventIdEvent identifier (negative value keeps original event Id)
eventTimeMC 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.

+ Here is the call graph for this function:

CbmMCEpoch::ClassDef ( CbmMCEpoch  ,
 
)
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.

void CbmMCEpoch::CreateArrays ( )
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().

+ Here is the caller graph for this function:

Int_t CbmMCEpoch::GetNofPoints ( DetectorId  det) const
Get number of points in this epoch for a given detector 
Parameters
detDetector 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().

+ Here is the caller graph for this function:

FairMCPoint * CbmMCEpoch::GetPoint ( DetectorId  det,
Int_t  index 
)

Get an MCPoint for a given detector

Parameters
detDetector system identifier
indexIndex 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().

+ Here is the call graph for this function:

TClonesArray* CbmMCEpoch::GetPoints ( DetectorId  det)
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.

Double_t CbmMCEpoch::GetStartTime ( )
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.

+ Here is the call graph for this function:

CbmMCEpoch& CbmMCEpoch::operator= ( const CbmMCEpoch )
private
void CbmMCEpoch::Print ( Option_t *  opt = "") const
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.

+ Here is the call graph for this function:

void CbmMCEpoch::SetStartTime ( Double_t  time)
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.

Member Data Documentation

Double_t CbmMCEpoch::fEpochLength
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

TClonesArray* CbmMCEpoch::fPoints[kTutDet]
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().

Double_t CbmMCEpoch::fStartTime
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().


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