FairRoot/PandaRoot
PndSciTPoint.cxx
Go to the documentation of this file.
1 //
3 // PndSciTPoint
4 //
5 // MC point for Barrel tof detector
6 // created by A. Sanchez
7 // modified by D. Steinschaden
8 // last update 04.2015/
10 
11 #include "PndSciTPoint.h"
12 #include "FairEventHeader.h"
13 #include "FairRun.h"
14 
15 #include <iostream>
16 
17 using std::cout;
18 using std::endl;
19 
20 // ----- Default constructor -------------------------------------------
21 PndSciTPoint::PndSciTPoint() : FairMCPoint() ,
22  fDetName(""),
23  fXout(0.), fYout(0.), fZout(0.),
24  fPxout(0.),fPyout(0.),fPzout(0.)
25 {
26 }
27 // -------------------------------------------------------------------------
28 
29 // ----- Standard constructor ------------------------------------------
30 PndSciTPoint::PndSciTPoint( Int_t eventID, Int_t trackID,
31  Int_t detectorID, TString detName,
32  TVector3 posin,
33  TVector3 momin,
34  TVector3 posout,
35  TVector3 momout,
36  Double_t tof, Double_t length,
37  Double_t eLoss)
38  : FairMCPoint(trackID, detectorID, posin, momin, tof, length, eLoss, (UInt_t) eventID) ,
39  fDetName(detName),
40  fXout(posout.X()), fYout(posout.Y()), fZout(posout.Z()),
41  fPxout(momout.Px()),fPyout(momout.Py()),fPzout(momout.Pz())
42 {
43  //FIXME: Do we need to call the event header here?
44  //FairEventHeader* evtHeader = FairRun::Instance()->GetEventHeader();
45  SetLink(FairLink(-1, eventID, "MCTrack", trackID));
46 }
47 
48 
49 // ----- Destructor ----------------------------------------------------
51 // -------------------------------------------------------------------------
52 
53 // ----- Public method Print -------------------------------------------
54 void PndSciTPoint::Print(const Option_t* opt) const {
55  cout << "-I- PndSciTPoint: forward tof Point for track "
56  <<" in detector " << endl;
57  cout << " Position (" << fX << ", " << fY << ", " << fZ
58  << ") cm" << endl;
59  cout << " Momentum (" << fPx << ", " << fPy << ", " << fPz
60  << ") GeV" << " opt="<<opt<< endl;
61 
62 }
63 // -------------------------------------------------------------------------
64 
65 
66 
Double_t fX
Definition: PndCaloDraw.cxx:34
virtual void Print(const Option_t *opt) const
double Y
Definition: anaLmdDigi.C:68
Double_t fZ
Definition: PndCaloDraw.cxx:34
Double_t
double X
Definition: anaLmdDigi.C:68
Double_t fY
Definition: PndCaloDraw.cxx:34
virtual ~PndSciTPoint()
ClassImp(PndAnaContFact)
double Z
Definition: anaLmdDigi.C:68