BmnRoot
26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
Toggle main menu visibility
Loading...
Searching...
No Matches
BmnTOF1Point.h
Go to the documentation of this file.
1
//--------------------------------------------------------------------------------------------------------------------------------------
2
#ifndef __BMNTOF1POINT_H
3
#define __BMNTOF1POINT_H 1
4
5
#include "FairMCPoint.h"
6
7
#include <
TVector3.h
>
8
9
//--------------------------------------------------------------------------------------------------------------------------------------
10
class
BmnTOF1Point
:
public
FairMCPoint
11
{
12
public
:
13
BmnTOF1Point
();
14
virtual
~BmnTOF1Point
();
15
16
/** Constructor with arguments
17
*@param trackID Index of MCTrack
18
*@param detID Detector ID: kTOF1 for TOF400 or kTOF701 fot TOF700
19
*@param pos Ccoordinates at entrance to active volume [cm]
20
*@param mom Momentum of track at entrance [GeV]
21
*@param tof Time since event start [ns]
22
*@param length Track length since creation [cm]
23
*@param eLoss Energy deposit [GeV]
24
*@param detUID Unique Identification Number
25
**/
26
BmnTOF1Point
(
Int_t
trackID,
27
Int_t
detID,
28
TVector3
pos,
29
TVector3
mom,
30
Double_t
tof,
31
Double_t
length,
32
Double_t
eLoss,
33
Int_t
detUID);
34
35
virtual
void
Print
(
const
Option_t
* opt)
const
;
36
37
// CATION: stripID MAX_VALUE = 255, moduleID MAX_VALUE = 255, regionID MAX_VALUE = 255
38
Int_t
GetStrip
()
const
{
return
(
fDetectorUID
& 0x000000FF); };
39
Int_t
GetModule
()
const
{
return
(
fDetectorUID
& 0x0000FF00) >> 8; };
40
Int_t
GetRegion
()
const
{
return
(
fDetectorUID
& 0x00FF0000) >> 16; };
41
Int_t
GetVolumeUID
()
const
{
return
fDetectorUID
; };
42
43
static
Int_t
GetStrip
(
Int_t
uid) {
return
(uid & 0x000000FF); };
44
static
Int_t
GetModule
(
Int_t
uid) {
return
(uid & 0x0000FF00) >> 8; };
45
static
Int_t
GetRegion
(
Int_t
uid) {
return
(uid & 0x00FF0000) >> 16; };
46
static
Int_t
GetVolumeUID
(
Int_t
regID,
Int_t
modID,
Int_t
stripID)
47
{
48
#ifdef DEBUG
49
Int_t
uid = (regID << 16) | (modID << 8) | stripID;
50
Int_t
region =
GetRegion
(uid);
51
Int_t
module =
GetModule
(uid);
52
Int_t
strip =
GetStrip
(uid);
53
assert(region == regID);
54
assert(module == modID);
55
assert(strip == stripID);
56
return
uid;
57
#else
58
return
(regID << 16) | (modID << 8) | stripID;
59
#endif
60
};
61
62
private
:
63
Int_t
fDetectorUID
;
///< Unique Identification Number.
64
65
ClassDef
(
BmnTOF1Point
, 2)
66
};
67
68
#endif
69
//--------------------------------------------------------------------------------------------------------------------------------------
Int_t
int Int_t
Double_t
double Double_t
Option_t
const char Option_t
ClassDef
#define ClassDef(name, id)
TVector3.h
BmnTOF1Point
Definition
BmnTOF1Point.h:11
BmnTOF1Point::~BmnTOF1Point
virtual ~BmnTOF1Point()
BmnTOF1Point::GetVolumeUID
Int_t GetVolumeUID() const
Definition
BmnTOF1Point.h:41
BmnTOF1Point::BmnTOF1Point
BmnTOF1Point()
BmnTOF1Point::GetStrip
static Int_t GetStrip(Int_t uid)
Definition
BmnTOF1Point.h:43
BmnTOF1Point::GetModule
Int_t GetModule() const
Definition
BmnTOF1Point.h:39
BmnTOF1Point::Print
virtual void Print(const Option_t *opt) const
BmnTOF1Point::GetRegion
Int_t GetRegion() const
Definition
BmnTOF1Point.h:40
BmnTOF1Point::fDetectorUID
Int_t fDetectorUID
Unique Identification Number.
Definition
BmnTOF1Point.h:63
BmnTOF1Point::BmnTOF1Point
BmnTOF1Point(Int_t trackID, Int_t detID, TVector3 pos, TVector3 mom, Double_t tof, Double_t length, Double_t eLoss, Int_t detUID)
Constructor with arguments.
BmnTOF1Point::GetStrip
Int_t GetStrip() const
Definition
BmnTOF1Point.h:38
BmnTOF1Point::GetModule
static Int_t GetModule(Int_t uid)
Definition
BmnTOF1Point.h:44
BmnTOF1Point::GetRegion
static Int_t GetRegion(Int_t uid)
Definition
BmnTOF1Point.h:45
BmnTOF1Point::GetVolumeUID
static Int_t GetVolumeUID(Int_t regID, Int_t modID, Int_t stripID)
Definition
BmnTOF1Point.h:46
FairMCPoint
TVector3
install
include
BmnTOF1Point.h
Generated on
for BmnRoot by
1.17.0