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

#include <CbmPlutoGenerator.h>

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

Public Member Functions

 CbmPlutoGenerator ()
 
 CbmPlutoGenerator (const Char_t *fileName)
 
 CbmPlutoGenerator (std::vector< std::string > fileNames)
 
 CbmPlutoGenerator (const CbmPlutoGenerator &)=delete
 
CbmPlutoGeneratoroperator= (const CbmPlutoGenerator &)=delete
 
virtual ~CbmPlutoGenerator ()
 
virtual Bool_t ReadEvent (FairPrimaryGenerator *primGen)
 
void SetManualPDG (Int_t pdg)
 
Int_t GetNumAvailableEvents ()
 Get the maximum number of events available in the input file.
 

Private Member Functions

void CloseInput ()
 Maximum number of events in the input file.
 
 ClassDef (CbmPlutoGenerator, 5)
 

Private Attributes

PStaticDatafdata {makeStaticData()}
 
PDataBasefbase {makeDataBase()}
 pluto static data
 
Int_t iEvent {0}
 pluto data base
 
const Char_t * fFileName {""}
 Event number.
 
TChain * fInputChain {nullptr}
 Input file name.
 
TClonesArray * fParticles {new TClonesArray("PParticle", 100)}
 Pointer to input file.
 
Int_t fPDGmanual {0}
 Particle array from PLUTO.
 
Int_t fAvailableEvents {0}
 forced pdg value for undefined pluto codes
 

Detailed Description

Definition at line 35 of file CbmPlutoGenerator.h.

Constructor & Destructor Documentation

◆ CbmPlutoGenerator() [1/4]

CbmPlutoGenerator::CbmPlutoGenerator ( )

Default constructor (should not be used)

Definition at line 27 of file CbmPlutoGenerator.cxx.

◆ CbmPlutoGenerator() [2/4]

CbmPlutoGenerator::CbmPlutoGenerator ( const Char_t * fileName)

Standard constructor

Parameters
fileNameThe input (PLUTO) file name

Definition at line 31 of file CbmPlutoGenerator.cxx.

References fAvailableEvents, fInputChain, fParticles, and Cbm::File::IsRootFile().

◆ CbmPlutoGenerator() [3/4]

CbmPlutoGenerator::CbmPlutoGenerator ( std::vector< std::string > fileNames)

Constructor with list of input files

Parameters
fileNamesA list of (PLUTO) input file names

Definition at line 48 of file CbmPlutoGenerator.cxx.

References fAvailableEvents, fInputChain, fParticles, and Cbm::File::IsRootFile().

◆ CbmPlutoGenerator() [4/4]

CbmPlutoGenerator::CbmPlutoGenerator ( const CbmPlutoGenerator & )
delete

◆ ~CbmPlutoGenerator()

CbmPlutoGenerator::~CbmPlutoGenerator ( )
virtual

Destructor

Definition at line 66 of file CbmPlutoGenerator.cxx.

References CloseInput(), fbase, and fdata.

Member Function Documentation

◆ ClassDef()

CbmPlutoGenerator::ClassDef ( CbmPlutoGenerator ,
5  )
private

◆ CloseInput()

void CbmPlutoGenerator::CloseInput ( )
private

Maximum number of events in the input file.

Private method CloseInput. Just for convenience. Closes the input file properly. Called from destructor and from ReadEvent.

Definition at line 161 of file CbmPlutoGenerator.cxx.

References fFileName, and fInputChain.

Referenced by ReadEvent(), and ~CbmPlutoGenerator().

◆ GetNumAvailableEvents()

Int_t CbmPlutoGenerator::GetNumAvailableEvents ( )
inline

Get the maximum number of events available in the input file.

Returns
number of available ebvents

Definition at line 69 of file CbmPlutoGenerator.h.

References fAvailableEvents.

Referenced by CbmTransport::Run().

◆ operator=()

CbmPlutoGenerator & CbmPlutoGenerator::operator= ( const CbmPlutoGenerator & )
delete

◆ ReadEvent()

Bool_t CbmPlutoGenerator::ReadEvent ( FairPrimaryGenerator * primGen)
virtual

Reads on event from the input file and pushes the tracks onto the stack. Abstract method in base class.

Parameters
primGenpointer to the FairPrimaryGenerator

Definition at line 76 of file CbmPlutoGenerator.cxx.

References CloseInput(), fbase, fInputChain, fParticles, fPDGmanual, PParticle::GetDaughterIndex(), PDataBase::GetParamInt(), PParticle::GetParentIndex(), PParticle::getVertex(), PParticle::ID(), iEvent, and PParticle::Vect4().

◆ SetManualPDG()

void CbmPlutoGenerator::SetManualPDG ( Int_t pdg)
inline

Definition at line 64 of file CbmPlutoGenerator.h.

References fPDGmanual.

Member Data Documentation

◆ fAvailableEvents

Int_t CbmPlutoGenerator::fAvailableEvents {0}
private

forced pdg value for undefined pluto codes

Definition at line 80 of file CbmPlutoGenerator.h.

Referenced by CbmPlutoGenerator(), CbmPlutoGenerator(), and GetNumAvailableEvents().

◆ fbase

PDataBase* CbmPlutoGenerator::fbase {makeDataBase()}
private

pluto static data

Definition at line 73 of file CbmPlutoGenerator.h.

Referenced by ReadEvent(), and ~CbmPlutoGenerator().

◆ fdata

PStaticData* CbmPlutoGenerator::fdata {makeStaticData()}
private

Definition at line 72 of file CbmPlutoGenerator.h.

Referenced by ~CbmPlutoGenerator().

◆ fFileName

const Char_t* CbmPlutoGenerator::fFileName {""}
private

Event number.

Definition at line 76 of file CbmPlutoGenerator.h.

Referenced by CloseInput().

◆ fInputChain

TChain* CbmPlutoGenerator::fInputChain {nullptr}
private

Input file name.

Definition at line 77 of file CbmPlutoGenerator.h.

Referenced by CbmPlutoGenerator(), CbmPlutoGenerator(), CloseInput(), and ReadEvent().

◆ fParticles

TClonesArray* CbmPlutoGenerator::fParticles {new TClonesArray("PParticle", 100)}
private

Pointer to input file.

Definition at line 78 of file CbmPlutoGenerator.h.

Referenced by CbmPlutoGenerator(), CbmPlutoGenerator(), and ReadEvent().

◆ fPDGmanual

Int_t CbmPlutoGenerator::fPDGmanual {0}
private

Particle array from PLUTO.

Definition at line 79 of file CbmPlutoGenerator.h.

Referenced by ReadEvent(), and SetManualPDG().

◆ iEvent

Int_t CbmPlutoGenerator::iEvent {0}
private

pluto data base

Definition at line 75 of file CbmPlutoGenerator.h.

Referenced by ReadEvent().


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