EIC Software
Reference for
EIC
simulation and reconstruction software on GitHub
Home page
Related Pages
Modules
Namespaces
Classes
Files
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
FairHit.h
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file FairHit.h
1
#ifndef FAIRHIT_H
2
#define FAIRHIT_H
3
4
#include "
FairTimeStamp.h
"
5
#include "TVector3.h"
6
13
class
FairHit
:
public
FairTimeStamp
14
{
15
16
public
:
17
19
FairHit
();
20
21
23
FairHit
(Int_t detID, TVector3&
pos
, TVector3& dpos, Int_t index);
24
FairHit
(Int_t detID, TVector3& pos, Int_t index);
25
26
28
virtual
~FairHit
();
29
30
32
Double_t
GetDx
()
const
{
return
fDx
; };
33
Double_t
GetDy
()
const
{
return
fDy
; };
34
Double_t
GetDz
()
const
{
return
fDz
; };
35
Int_t
GetRefIndex
()
const
{
return
fRefIndex
; };
36
void
PositionError
(TVector3& dpos)
const
;
37
Int_t
GetDetectorID
()
const
{
return
fDetectorID
; };
38
Double_t
GetX
()
const
{
return
fX
; };
39
Double_t
GetY
()
const
{
return
fY
; };
40
Double_t
GetZ
()
const
{
return
fZ
; };
41
void
Position
(TVector3& pos)
const
;
42
43
44
46
void
SetDx
(Double_t
dx
) {
fDx
=
dx
; }
47
void
SetDy
(Double_t
dy
) {
fDy
=
dy
; }
48
void
SetDz
(Double_t
dz
) {
fDz
=
dz
; }
49
void
SetDxyz
(Double_t
dx
, Double_t
dy
, Double_t
dz
);
50
void
SetPositionError
(
const
TVector3& dpos);
51
void
SetRefIndex
(Int_t index) {
fRefIndex
= index; }
52
void
SetDetectorID
(Int_t detID) {
fDetectorID
= detID; }
53
void
SetX
(Double_t
x
) {
fX
=
x
; }
54
void
SetY
(Double_t
y
) {
fY
=
y
; }
55
void
SetZ
(Double_t
z
) {
fZ
=
z
; }
56
void
SetXYZ
(Double_t
x
, Double_t
y
, Double_t
z
);
57
void
SetPosition
(
const
TVector3& pos);
58
59
60
/*** Output to screen */
61
virtual
void
Print
(
const
Option_t* opt =
""
)
const
{;}
62
63
64
65
protected
:
66
67
Double32_t
fDx
,
fDy
,
fDz
;
68
Int_t
fRefIndex
;
69
Int_t
fDetectorID
;
70
Double32_t
fX
,
fY
,
fZ
;
71
72
73
ClassDef
(
FairHit
,2);
74
75
76
};
77
78
79
inline
void
FairHit::PositionError
(TVector3& dpos)
const
80
{
81
dpos.SetXYZ(
fDx
,
fDy
,
fDz
);
82
}
83
84
85
inline
void
FairHit::SetDxyz
(Double_t
dx
, Double_t
dy
, Double_t
dz
)
86
{
87
fDx
=
dx
;
88
fDy
=
dy
;
89
fDz
=
dz
;
90
}
91
92
93
inline
void
FairHit::SetPositionError
(
const
TVector3& dpos)
94
{
95
fDx
= dpos.X();
96
fDy
= dpos.Y();
97
fDz
= dpos.Z();
98
}
99
100
inline
void
FairHit::Position
(TVector3&
pos
)
const
101
{
102
pos.SetXYZ(
fX
,
fY
,
fZ
);
103
}
104
105
106
inline
void
FairHit::SetXYZ
(Double_t
x
, Double_t
y
, Double_t
z
)
107
{
108
fX
=
x
;
109
fY
=
y
;
110
fZ
=
z
;
111
}
112
113
114
inline
void
FairHit::SetPosition
(
const
TVector3&
pos
)
115
{
116
fX
= pos.X();
117
fY
= pos.Y();
118
fZ
= pos.Z();
119
}
120
121
#endif
EicRoot
blob
master
base
FairHit.h
Built by
Jin Huang
. updated:
Mon Jan 22 2024 12:43:32
using
1.8.2 with
EIC GitHub integration