PandaRoot
CbmPlanePoint.h
Go to the documentation of this file.
1 //****************************************************************************
2 //* This file is part of PandaRoot. *
3 //* *
4 //* PandaRoot is distributed under the terms of the *
5 //* GNU General Public License (GPL) version 3, *
6 //* copied verbatim in the file "LICENSE". *
7 //* *
8 //* Copyright (C) 2006 - 2024 FAIR GmbH and copyright holders of PandaRoot *
9 //* The copyright holders are listed in the file "COPYRIGHTHOLDERS". *
10 //* The authors are listed in the file "AUTHORS". *
11 //****************************************************************************
12 
13 #ifndef CBMPlanePOINT_H
14 #define CBMPlanePOINT_H
15 
16 #include "TObject.h"
17 #include "TVector3.h"
18 #include "FairMCPoint.h"
19 
20 class CbmPlanePoint : public FairMCPoint {
21 
22  public:
24  CbmPlanePoint();
25 
37  // CbmPlanePoint(Int_t trackID, Int_t detID, TVector3 posIn,
38  // TVector3 posOut, TVector3 momIn, TVector3 momOut,
39  // Double_t tof, Double_t length, Double_t eLoss);
40 
41  CbmPlanePoint(Int_t trackID, Int_t detID, TVector3 posIn, TVector3 posOut, TVector3 momIn, TVector3 momOut, Double_t tof, Double_t length, Double_t eLoss, Double_t charge,
42  Double_t mass, Bool_t preflag, Bool_t postflag, TString nam, Int_t eventID);
43 
45  CbmPlanePoint(const CbmPlanePoint &point) { *this = point; };
46 
48  virtual ~CbmPlanePoint();
49 
51  Double_t GetXOut() const { return fX_out; }
52  Double_t GetYOut() const { return fY_out; }
53  Double_t GetZOut() const { return fZ_out; }
54  Double_t GetPxOut() const { return fPx_out; }
55  Double_t GetPyOut() const { return fPy_out; }
56  Double_t GetPzOut() const { return fPz_out; }
57  Double_t GetXIn() const { return fX_in; }
58  Double_t GetYIn() const { return fY_in; }
59  Double_t GetZIn() const { return fZ_in; }
60  Double_t GetPxIn() const { return fPx_in; }
61  Double_t GetPyIn() const { return fPy_in; }
62  Double_t GetPzIn() const { return fPz_in; }
63  Double_t GetMass() const { return fmass; }
64 
65  Int_t GetTrackID() const { return ftrackID; }
66  Int_t GetEventID() const { return feventID; }
67  Int_t GetCopyNo() const { return fCopyNo; }
68  Bool_t GetPreFlag() const { return fpreflag; }
69  Bool_t GetPostFlag() const { return fpostflag; }
70 
71  void PositionOut(TVector3 &pos) { pos.SetXYZ(fX_out, fY_out, fZ_out); }
72  void MomentumOut(TVector3 &mom) { mom.SetXYZ(fPx_out, fPy_out, fPz_out); }
73  TString GetNam() const { return fPlanenam; }
74 
76  void SetPositionOut(TVector3 pos);
77  void SetMomentumOut(TVector3 mom);
78 
79  // aggiunte
80  void SetPositionIn(TVector3 posin);
81  void SetMomentumIn(TVector3 momin);
82 
84  virtual void Print(const Option_t *opt) const;
85 
86  protected:
87  Double32_t fX_in, fY_in, fZ_in;
88  Double32_t fPx_in, fPy_in, fPz_in;
89  Double32_t fX_out, fY_out, fZ_out;
90  Double32_t fPx_out, fPy_out, fPz_out;
91  Double_t fmass;
93  Double_t fcharge;
94  Int_t fCopyNo;
95  TString fPlanenam;
96  Int_t ftrackID;
97  Int_t feventID;
98  ClassDef(CbmPlanePoint, 1)
99 };
100 
101 inline void CbmPlanePoint::SetPositionOut(TVector3 pos)
102 {
103  fX_out = pos.X();
104  fY_out = pos.Y();
105  fZ_out = pos.Z();
106 }
107 
108 inline void CbmPlanePoint::SetMomentumOut(TVector3 mom)
109 {
110  fPx_out = mom.Px();
111  fPy_out = mom.Py();
112  fPz_out = mom.Pz();
113 }
114 
115 inline void CbmPlanePoint::SetPositionIn(TVector3 posin)
116 {
117  fX_in = posin.X();
118  fY_in = posin.Y();
119  fZ_in = posin.Z();
120 }
121 
122 inline void CbmPlanePoint::SetMomentumIn(TVector3 momin)
123 {
124  fPx_in = momin.Px();
125  fPy_in = momin.Py();
126  fPz_in = momin.Pz();
127 }
128 
129 #endif
Double_t GetYOut() const
Definition: CbmPlanePoint.h:52
Double_t GetPxOut() const
Definition: CbmPlanePoint.h:54
Double_t GetPyOut() const
Definition: CbmPlanePoint.h:55
Double_t fcharge
Definition: CbmPlanePoint.h:93
Double32_t fX_in
Definition: CbmPlanePoint.h:87
Bool_t fpostflag
Definition: CbmPlanePoint.h:92
void MomentumOut(TVector3 &mom)
Definition: CbmPlanePoint.h:72
Int_t GetTrackID() const
Definition: CbmPlanePoint.h:65
Double32_t fPz_out
Definition: CbmPlanePoint.h:90
Double_t GetZOut() const
Definition: CbmPlanePoint.h:53
Double32_t fY_out
Definition: CbmPlanePoint.h:89
Double_t GetYIn() const
Definition: CbmPlanePoint.h:58
Double_t GetPyIn() const
Definition: CbmPlanePoint.h:61
virtual void Print(const Option_t *opt) const
virtual ~CbmPlanePoint()
Bool_t GetPreFlag() const
Definition: CbmPlanePoint.h:68
Double32_t fPz_in
Definition: CbmPlanePoint.h:88
Double32_t fX_out
Definition: CbmPlanePoint.h:89
Double_t GetXIn() const
Definition: CbmPlanePoint.h:57
Double32_t fPy_out
Definition: CbmPlanePoint.h:90
TString GetNam() const
Definition: CbmPlanePoint.h:73
Double_t GetPxIn() const
Definition: CbmPlanePoint.h:60
Double32_t fZ_in
Definition: CbmPlanePoint.h:87
void SetPositionIn(TVector3 posin)
Double32_t fPy_in
Definition: CbmPlanePoint.h:88
Double32_t fY_in
Definition: CbmPlanePoint.h:87
Double32_t fPx_out
Definition: CbmPlanePoint.h:90
void SetMomentumIn(TVector3 momin)
void PositionOut(TVector3 &pos)
Definition: CbmPlanePoint.h:71
Double32_t fZ_out
Definition: CbmPlanePoint.h:89
void SetPositionOut(TVector3 pos)
Double_t GetXOut() const
Definition: CbmPlanePoint.h:51
Int_t GetCopyNo() const
Definition: CbmPlanePoint.h:67
CbmPlanePoint(const CbmPlanePoint &point)
Definition: CbmPlanePoint.h:45
Double_t GetPzOut() const
Definition: CbmPlanePoint.h:56
Double_t fmass
Definition: CbmPlanePoint.h:91
void SetMomentumOut(TVector3 mom)
Double_t GetMass() const
Definition: CbmPlanePoint.h:63
Int_t GetEventID() const
Definition: CbmPlanePoint.h:66
TString fPlanenam
Definition: CbmPlanePoint.h:95
Double32_t fPx_in
Definition: CbmPlanePoint.h:88
Bool_t GetPostFlag() const
Definition: CbmPlanePoint.h:69
Double_t GetPzIn() const
Definition: CbmPlanePoint.h:62
Double_t GetZIn() const
Definition: CbmPlanePoint.h:59