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

#include <CbmTofDetectorId_v14a.h>

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

Public Member Functions

 CbmTofDetectorId_v14a ()
 
 ~CbmTofDetectorId_v14a ()
 
CbmTofDetectorInfo GetDetectorInfo (const int32_t detectorId)
 
int32_t GetSystemId (int32_t detectorId)
 
int32_t GetSMType (const int32_t detectorId)
 
int32_t GetModuleType (const int32_t detectorId)
 
int32_t GetSModule (const int32_t detectorId)
 
int32_t GetModuleId (const int32_t detectorId)
 
int32_t GetCounter (const int32_t detectorId)
 
int32_t GetGap (const int32_t detectorId)
 
int32_t GetSide (const int32_t detectorId)
 
int32_t GetCell (const int32_t detectorId)
 
int32_t GetStrip (const int32_t detectorId)
 
int32_t GetRegion (const int32_t detectorId)
 
int32_t GetCellId (const int32_t detectorId)
 
int32_t SetDetectorInfo (const CbmTofDetectorInfo detectorInfo)
 

Private Attributes

int32_t result_array [array_length]
 
int32_t maskarray [array_length]
 
int32_t modulemask
 

Static Private Attributes

static const int32_t array_length = 6
 
static const int32_t shiftarray [] = {0, 4, 12, 16, 23, 24}
 
static const int32_t bitarray [] = {4, 8, 4, 7, 1, 8}
 

Detailed Description

CbmTofDetectorId.h Defines unique detector identifier for all TOF modules. This class is the implementation for tof geometry version v14a nh, 11.03.2014 PAL, 23.09.2015: make the class common to both v14 and v15 geometries Field 4 used as Side index (or fake Gap index in digitizer) Naming as in TDR: SM -> Module, Module -> Counter, Cell -> Strip All classes which uses this scheme should have a data member of this class

Author
F. Uhlig f.uhl.nosp@m.ig@g.nosp@m.si.de Current definition: 10987654321098765432109876543210 System ID (kTOF=6) on bits 0-3 00000000000000000000000000001111 15 Module ID on bits 4-11 00000000000000000000111111110000 <<4 255 Module Type on bits 12-15 00000000000000001111000000000000 <<12 15 Counter ID on bits 16-23 00000000011111110000000000000000 <<16 127 Side/Gap NR on bits 20-23 00000000100000000000000000000000 <<23 1 Strip ID on bits 24-31 11111111000000000000000000000000 <<24 255

Definition at line 41 of file CbmTofDetectorId_v14a.h.

Constructor & Destructor Documentation

◆ CbmTofDetectorId_v14a()

CbmTofDetectorId_v14a::CbmTofDetectorId_v14a ( )

Constructor

Definition at line 17 of file CbmTofDetectorId_v14a.cxx.

References array_length, bitarray, maskarray, modulemask, and shiftarray.

◆ ~CbmTofDetectorId_v14a()

CbmTofDetectorId_v14a::~CbmTofDetectorId_v14a ( )
inline

Destructor

Definition at line 48 of file CbmTofDetectorId_v14a.h.

Member Function Documentation

◆ GetCell()

int32_t CbmTofDetectorId_v14a::GetCell ( const int32_t detectorId)
virtual

Get cell number from detector ID

Implements CbmTofDetectorId.

Definition at line 72 of file CbmTofDetectorId_v14a.cxx.

References maskarray, and shiftarray.

Referenced by GetStrip().

◆ GetCellId()

int32_t CbmTofDetectorId_v14a::GetCellId ( const int32_t detectorId)
virtual

Get full cell number from detector ID. This is masking the the gap number if this is set.

Implements CbmTofDetectorId.

Definition at line 83 of file CbmTofDetectorId_v14a.cxx.

References modulemask.

◆ GetCounter()

int32_t CbmTofDetectorId_v14a::GetCounter ( const int32_t detectorId)
virtual

Get counter ID from detector ID

Implements CbmTofDetectorId.

Definition at line 57 of file CbmTofDetectorId_v14a.cxx.

References maskarray, and shiftarray.

◆ GetDetectorInfo()

CbmTofDetectorInfo CbmTofDetectorId_v14a::GetDetectorInfo ( const int32_t detectorId)
virtual

Get complete system info from detector ID This will return a pointer to an integer array of length array_length

Implements CbmTofDetectorId.

Definition at line 27 of file CbmTofDetectorId_v14a.cxx.

References array_length, maskarray, result_array, and shiftarray.

◆ GetGap()

int32_t CbmTofDetectorId_v14a::GetGap ( const int32_t detectorId)
virtual

Get sector number from detector ID

Implements CbmTofDetectorId.

Definition at line 68 of file CbmTofDetectorId_v14a.cxx.

References GetSide().

◆ GetModuleId()

int32_t CbmTofDetectorId_v14a::GetModuleId ( const int32_t detectorId)

Definition at line 53 of file CbmTofDetectorId_v14a.cxx.

References GetSModule().

◆ GetModuleType()

int32_t CbmTofDetectorId_v14a::GetModuleType ( const int32_t detectorId)

Definition at line 45 of file CbmTofDetectorId_v14a.cxx.

References GetSMType().

◆ GetRegion()

int32_t CbmTofDetectorId_v14a::GetRegion ( const int32_t detectorId)
virtual

Get region number from detector ID

Implements CbmTofDetectorId.

Definition at line 81 of file CbmTofDetectorId_v14a.cxx.

◆ GetSide()

int32_t CbmTofDetectorId_v14a::GetSide ( const int32_t detectorId)

Get sector number from detector ID

Definition at line 64 of file CbmTofDetectorId_v14a.cxx.

References maskarray, and shiftarray.

Referenced by GetGap().

◆ GetSModule()

int32_t CbmTofDetectorId_v14a::GetSModule ( const int32_t detectorId)
virtual

Get Module ID from detector ID

Implements CbmTofDetectorId.

Definition at line 49 of file CbmTofDetectorId_v14a.cxx.

References maskarray, and shiftarray.

Referenced by GetModuleId().

◆ GetSMType()

int32_t CbmTofDetectorId_v14a::GetSMType ( const int32_t detectorId)
virtual

Get Module Type from detector ID

Implements CbmTofDetectorId.

Definition at line 41 of file CbmTofDetectorId_v14a.cxx.

References maskarray, and shiftarray.

Referenced by GetModuleType().

◆ GetStrip()

int32_t CbmTofDetectorId_v14a::GetStrip ( const int32_t detectorId)

Get Strip ID from detector ID

Definition at line 77 of file CbmTofDetectorId_v14a.cxx.

References GetCell().

◆ GetSystemId()

int32_t CbmTofDetectorId_v14a::GetSystemId ( int32_t detectorId)
virtual

Get the global sytem ID

Implements CbmTofDetectorId.

Definition at line 37 of file CbmTofDetectorId_v14a.cxx.

References maskarray.

◆ SetDetectorInfo()

int32_t CbmTofDetectorId_v14a::SetDetectorInfo ( const CbmTofDetectorInfo detectorInfo)
virtual

Calculate the unique detector ID This will return a pointer to an integer array of length array_length

Implements CbmTofDetectorId.

Definition at line 87 of file CbmTofDetectorId_v14a.cxx.

References CbmTofDetectorInfo::fCell, CbmTofDetectorInfo::fCounter, CbmTofDetectorInfo::fDetectorSystem, CbmTofDetectorInfo::fGap, CbmTofDetectorInfo::fSModule, and CbmTofDetectorInfo::fSMtype.

Member Data Documentation

◆ array_length

const int32_t CbmTofDetectorId_v14a::array_length = 6
staticprivate

Definition at line 97 of file CbmTofDetectorId_v14a.h.

Referenced by CbmTofDetectorId_v14a(), and GetDetectorInfo().

◆ bitarray

const int32_t CbmTofDetectorId_v14a::bitarray = {4, 8, 4, 7, 1, 8}
staticprivate

Definition at line 14 of file CbmTofDetectorId_v14a.h.

Referenced by CbmTofDetectorId_v14a().

◆ maskarray

int32_t CbmTofDetectorId_v14a::maskarray[array_length]
private

◆ modulemask

int32_t CbmTofDetectorId_v14a::modulemask
private

Definition at line 102 of file CbmTofDetectorId_v14a.h.

Referenced by CbmTofDetectorId_v14a(), and GetCellId().

◆ result_array

int32_t CbmTofDetectorId_v14a::result_array[array_length]
private

Definition at line 100 of file CbmTofDetectorId_v14a.h.

Referenced by GetDetectorInfo().

◆ shiftarray

const int32_t CbmTofDetectorId_v14a::shiftarray = {0, 4, 12, 16, 23, 24}
staticprivate

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