PandaRoot
BSEmcDetector Class Reference

Specialization of the FairDetector for a common BSEmcDetector. More...

#include <BSEmcDetector.h>

Inheritance diagram for BSEmcDetector:
BSEmcBarrel BSEmcBwEndcap BSEmcFwEndcap BSEmcShashlikDetector BSEmcShashlik

Public Member Functions

 BSEmcDetector ()
 
 BSEmcDetector (BSEmcDetector &other)
 
 BSEmcDetector (const char *t_name, Bool_t t_active)
 
virtual ~BSEmcDetector ()
 
virtual void Initialize ()
 
virtual Bool_t ProcessHits (FairVolume *t_vol=nullptr)
 
virtual void EndOfEvent ()
 
virtual void FinishRun ()
 
virtual void Register ()
 
virtual TClonesArray * GetCollection (Int_t t_iColl) const
 
virtual void Print () const
 
virtual void SetSpecialPhysicsCuts ()
 
virtual void Reset ()
 
virtual void CopyClones (TClonesArray *t_origin, TClonesArray *t_target, Int_t t_offset)
 
virtual void ConstructGeometry ()
 
virtual void ConstructASCIIGeometry ()
 
void SetFolderName (const TString &t_folder)
 
void SetBranchOutName (const TString &t_branchout)
 
const TString & GetFolderName () const
 
const TString & GetBranchOutName () const
 
void SetSensitiveNames (const std::vector< std::string > &t_sensNames)
 
virtual void SetDefaultSensitiveNames ()
 
const std::vector< std::string > & GetListOfSensitives ()
 
void SetTransformMatrix (TGeoMatrix *t_transform)
 
const TGeoMatrix * GetTransformMatrix () const
 
void SetIdMap (PndSensorNameIdMap *t_map)
 
PndSensorNameIdMapGetIdMap ()
 
void SetPersistency (Bool_t t_storePoints)
 

Protected Member Functions

virtual Int_t GetDetectorId ()
 
Bool_t CheckIfSensitive (std::string t_name)
 
BSEmcMCPointAddHit (Int_t t_trackID, Int_t t_detID, Int_t t_evtID, TVector3 t_pos, TVector3 t_mom, Double_t t_tof, Double_t t_length, Double_t t_eLoss, Bool_t t_enterning, Bool_t t_exiting)
 
void ResetParameters ()
 

Protected Attributes

std::vector< std::string > fListOfSensitives {}
 
PndGeoHandlingfGeoH {nullptr}
 
PndSensorNameIdMapfIdMap {nullptr}
 

Detailed Description

Specialization of the FairDetector for a common BSEmcDetector.

It implements common functionality between the different BSEmc detector components (e.g. Forward/Backward Endcaps, Barrel) such as the ProcessHits, Point-registration, etc. It is almost a one to one copy of T. Stockmanns PndSdsDetector.

Author
Tobias Stockmanns
B. Salisbury salis.nosp@m.bury.nosp@m.@hisk.nosp@m.p.un.nosp@m.i-bon.nosp@m.n.de

Definition at line 43 of file BSEmcDetector.h.

Constructor & Destructor Documentation

◆ BSEmcDetector() [1/3]

BSEmcDetector::BSEmcDetector ( )

Referenced by BSEmcDetector().

◆ BSEmcDetector() [2/3]

BSEmcDetector::BSEmcDetector ( BSEmcDetector other)
inline

Definition at line 47 of file BSEmcDetector.h.

References BSEmcDetector(), ConstructASCIIGeometry(), ConstructGeometry(), CopyClones(), EndOfEvent(), FinishRun(), GetCollection(), Initialize(), Print(), ProcessHits(), Register(), Reset(), ResetParameters(), SetSpecialPhysicsCuts(), and ~BSEmcDetector().

48  : FairDetector(other), fListOfSensitives(other.fListOfSensitives), fGeoH(PndGeoHandling::Instance()), fIdMap(other.fIdMap), fPosIndex(other.fPosIndex),
49  fOutBranchName(other.fOutBranchName), fFolderName(other.fFolderName), fPndEmcCollection(other.fPndEmcCollection), fTransformMatrix(other.fTransformMatrix)
50 
51  {
53  };
PndSensorNameIdMap * fIdMap
void ResetParameters()
static PndGeoHandling * Instance()
PndGeoHandling * fGeoH
std::vector< std::string > fListOfSensitives

◆ BSEmcDetector() [3/3]

BSEmcDetector::BSEmcDetector ( const char *  t_name,
Bool_t  t_active 
)

Standard constructor.

Parameters
namedetector name
activesensitivity flag

◆ ~BSEmcDetector()

virtual BSEmcDetector::~BSEmcDetector ( )
virtual

Destructor

Referenced by BSEmcDetector().

Member Function Documentation

◆ AddHit()

BSEmcMCPoint* BSEmcDetector::AddHit ( Int_t  t_trackID,
Int_t  t_detID,
Int_t  t_evtID,
TVector3  t_pos,
TVector3  t_mom,
Double_t  t_tof,
Double_t  t_length,
Double_t  t_eLoss,
Bool_t  t_enterning,
Bool_t  t_exiting 
)
protected

Private method AddHit

Adds a BSEmcMCPoint to the HitCollection fPndEmcCollection

Referenced by SetPersistency().

◆ CheckIfSensitive()

Bool_t BSEmcDetector::CheckIfSensitive ( std::string  t_name)
protected

Referenced by SetPersistency().

◆ ConstructASCIIGeometry()

virtual void BSEmcDetector::ConstructASCIIGeometry ( )
virtual

Referenced by BSEmcDetector().

◆ ConstructGeometry()

virtual void BSEmcDetector::ConstructGeometry ( )
virtual

Virtual method Construct geometry

Constructs the BSEmcDetector geometry

Referenced by BSEmcDetector().

◆ CopyClones()

virtual void BSEmcDetector::CopyClones ( TClonesArray *  t_origin,
TClonesArray *  t_target,
Int_t  t_offset 
)
virtual

Virtual method CopyClones

Copies the hit collection with a given track index offset

Parameters
cl1Origin
cl2Target
offsetIndex offset

Referenced by BSEmcDetector().

◆ EndOfEvent()

virtual void BSEmcDetector::EndOfEvent ( )
virtual

Virtual method EndOfEvent

If verbosity level is set, Print hit collection at the end of the event and resets it afterwards.

Referenced by BSEmcDetector().

◆ FinishRun()

virtual void BSEmcDetector::FinishRun ( )
virtual

Referenced by BSEmcDetector().

◆ GetBranchOutName()

const TString& BSEmcDetector::GetBranchOutName ( ) const
inline

Definition at line 143 of file BSEmcDetector.h.

143 { return fOutBranchName; }

◆ GetCollection()

virtual TClonesArray* BSEmcDetector::GetCollection ( Int_t  t_iColl) const
virtual

Accessor to the hit collection

Referenced by BSEmcDetector().

◆ GetDetectorId()

virtual Int_t BSEmcDetector::GetDetectorId ( )
protectedvirtual

Reimplemented in BSEmcShashlikDetector.

Referenced by SetPersistency().

◆ GetFolderName()

const TString& BSEmcDetector::GetFolderName ( ) const
inline

Definition at line 142 of file BSEmcDetector.h.

142 { return fFolderName; }

◆ GetIdMap()

PndSensorNameIdMap* BSEmcDetector::GetIdMap ( )
inline

Definition at line 152 of file BSEmcDetector.h.

References fIdMap.

152 { return fIdMap; }
PndSensorNameIdMap * fIdMap

◆ GetListOfSensitives()

const std::vector<std::string>& BSEmcDetector::GetListOfSensitives ( )
inline

Definition at line 147 of file BSEmcDetector.h.

References fListOfSensitives.

147 { return fListOfSensitives; }
std::vector< std::string > fListOfSensitives

◆ GetTransformMatrix()

const TGeoMatrix* BSEmcDetector::GetTransformMatrix ( ) const
inline

Definition at line 149 of file BSEmcDetector.h.

149 { return fTransformMatrix; }

◆ Initialize()

virtual void BSEmcDetector::Initialize ( )
virtual

Referenced by BSEmcDetector().

◆ Print()

virtual void BSEmcDetector::Print ( ) const
virtual

Virtual method Print

Screen output of hit collection.

Referenced by BSEmcDetector().

◆ ProcessHits()

virtual Bool_t BSEmcDetector::ProcessHits ( FairVolume *  t_vol = nullptr)
virtual

Virtual method ProcessHits

Defines the action to be taken when a step is inside the active volume. Creates CbmTrdPoints and adds them to the collection.

Parameters
volPointer to the active volume

Referenced by BSEmcDetector().

◆ Register()

virtual void BSEmcDetector::Register ( )
virtual

Virtual method Register

Registers the hit collection in the ROOT manager.

Referenced by BSEmcDetector().

◆ Reset()

virtual void BSEmcDetector::Reset ( )
virtual

Virtual method Reset

Clears the hit collection

Referenced by BSEmcDetector().

◆ ResetParameters()

void BSEmcDetector::ResetParameters ( )
protected

Private method ResetParameters

Resets the private members for the fPosIndex

Referenced by BSEmcDetector(), and SetPersistency().

◆ SetBranchOutName()

void BSEmcDetector::SetBranchOutName ( const TString &  t_branchout)
inline

Definition at line 141 of file BSEmcDetector.h.

141 { fOutBranchName = t_branchout; }

◆ SetDefaultSensitiveNames()

virtual void BSEmcDetector::SetDefaultSensitiveNames ( )
inlinevirtual

Definition at line 146 of file BSEmcDetector.h.

References fListOfSensitives.

146 { fListOfSensitives = {"Crystal"}; } /*override*/;
std::vector< std::string > fListOfSensitives

◆ SetFolderName()

void BSEmcDetector::SetFolderName ( const TString &  t_folder)
inline

Definition at line 140 of file BSEmcDetector.h.

140 { fFolderName = t_folder; }

◆ SetIdMap()

void BSEmcDetector::SetIdMap ( PndSensorNameIdMap t_map)
inline

Definition at line 151 of file BSEmcDetector.h.

References fIdMap.

151 { fIdMap = t_map; }
PndSensorNameIdMap * fIdMap

◆ SetPersistency()

void BSEmcDetector::SetPersistency ( Bool_t  t_storePoints)
inline

Definition at line 154 of file BSEmcDetector.h.

References AddHit(), CheckIfSensitive(), GetDetectorId(), and ResetParameters().

154 { fPersistency = t_storePoints; }

◆ SetSensitiveNames()

void BSEmcDetector::SetSensitiveNames ( const std::vector< std::string > &  t_sensNames)
inline

Definition at line 145 of file BSEmcDetector.h.

References fListOfSensitives.

145 { fListOfSensitives = t_sensNames; };
std::vector< std::string > fListOfSensitives

◆ SetSpecialPhysicsCuts()

virtual void BSEmcDetector::SetSpecialPhysicsCuts ( )
virtual

Virtual Method SetSpecialPhysicsCuts

replaces some Geant initialisation via g3Config.C and so on

Reimplemented in BSEmcShashlikDetector.

Referenced by BSEmcDetector().

◆ SetTransformMatrix()

void BSEmcDetector::SetTransformMatrix ( TGeoMatrix *  t_transform)
inline

Definition at line 148 of file BSEmcDetector.h.

148 { fTransformMatrix = t_transform; }

Member Data Documentation

◆ fGeoH

PndGeoHandling* BSEmcDetector::fGeoH {nullptr}
protected

Definition at line 175 of file BSEmcDetector.h.

◆ fIdMap

PndSensorNameIdMap* BSEmcDetector::fIdMap {nullptr}
protected

Definition at line 176 of file BSEmcDetector.h.

Referenced by GetIdMap(), and SetIdMap().

◆ fListOfSensitives

std::vector<std::string> BSEmcDetector::fListOfSensitives {}
protected

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