CbmRoot
CbmModuleList Class Reference

Manages module Ids and names. More...

#include <CbmModuleList.h>

Public Member Functions

 CbmModuleList ()
 
virtual ~CbmModuleList ()
 

Static Public Member Functions

static TString GetModuleName (ECbmModuleId moduleId)
 
static TString GetModuleNameCaps (ECbmModuleId moduleId)
 
static ECbmModuleId GetModuleId (const char *moduleName)
 

Static Private Member Functions

static std::map< ECbmModuleId, TString > DefineModules ()
 

Static Private Attributes

static std::map< ECbmModuleId, TString > fModules
 

Detailed Description

Manages module Ids and names.

Author
V.Friese v.fri.nosp@m.ese@.nosp@m.gsi.d.nosp@m.e
Version
1.0

CbmModuleList is a tool to assess module names from their identifier and vice versa through static methods. Modules can be (detector) systems or passive ones.

Definition at line 27 of file CbmModuleList.h.

Constructor & Destructor Documentation

◆ CbmModuleList()

CbmModuleList::CbmModuleList ( )
inline

Constructor

Definition at line 31 of file CbmModuleList.h.

◆ ~CbmModuleList()

virtual CbmModuleList::~CbmModuleList ( )
inlinevirtual

Destructor

Definition at line 35 of file CbmModuleList.h.

Member Function Documentation

◆ DefineModules()

map< ECbmModuleId, TString > CbmModuleList::DefineModules ( )
staticprivate

Initialisation of module map

Definition at line 16 of file CbmModuleList.cxx.

References kCave, kDummyDet, kEcal, kHodo, kMagnet, kMuch, kMvd, kPipe, kPlatform, kPsd, kRef, kRich, kShield, kSts, kT0, kTarget, kTof, and kTrd.

◆ GetModuleId()

ECbmModuleId CbmModuleList::GetModuleId ( const char *  moduleName)
static

Get module Id from module name

Parameters
moduleNameName of module (case insensitive)
Returns
Unique module Id

Definition at line 52 of file CbmModuleList.cxx.

References fModules, and kNotExist.

◆ GetModuleName()

TString CbmModuleList::GetModuleName ( ECbmModuleId  moduleId)
static

Get module name from module Id

Parameters
moduleIdUnique module identifier (SystemId or kMagnet/kTarget/kPipe)
Returns
Name of module

Definition at line 66 of file CbmModuleList.cxx.

References fModules.

Referenced by CbmDigitization::GetGeoTag(), and GetModuleNameCaps().

◆ GetModuleNameCaps()

TString CbmModuleList::GetModuleNameCaps ( ECbmModuleId  moduleId)
static

Get module name in capitals from module Id

Parameters
moduleIdUnique module identifier (SystemId or kMagnet/kTarget/kPipe)
Returns
Name of module (in capitals)

Definition at line 77 of file CbmModuleList.cxx.

References GetModuleName().

Referenced by CbmDigitization::CheckInput(), CbmBuildEventsIdeal::Exec(), CbmDaq::FillTimeSlice(), CbmDaq::GetBufferStatus(), PairAnalysisHelper::GetDetName(), CbmBuildEventsIdeal::Init(), CbmBuildEventsIdealNew::Init(), CbmEventStore::ToString(), CbmSetup::ToString(), and CbmTimeSlice::ToString().

Member Data Documentation

◆ fModules

map< ECbmModuleId, TString > CbmModuleList::fModules
staticprivate

Map of module identifier to module name

Definition at line 61 of file CbmModuleList.h.

Referenced by GetModuleId(), and GetModuleName().


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