FairShip
Loading...
Searching...
No Matches
TTPoint.cxx
Go to the documentation of this file.
1// SPDX-License-Identifier: LGPL-3.0-or-later
2// SPDX-FileCopyrightText: Copyright CERN for the benefit of the SHiP
3// Collaboration
4
5#include "TTPoint.h"
6
7#include <iostream>
8using std::cout;
9using std::endl;
10
11// ----- Default constructor -------------------------------------------
12TTPoint::TTPoint() : FairMCPoint() {}
13// -------------------------------------------------------------------------
14
15TTPoint::TTPoint(Int_t trackID, Int_t detID, TVector3 pos, TVector3 mom,
16 Double_t tof, Double_t length, Double_t eLoss, Int_t pdgcode)
17 : FairMCPoint(trackID, detID, pos, mom, tof, length, eLoss),
18 fPdgCode(pdgcode) {}
19
20// -------------------------------------------------------------------------
21
22// ----- Destructor ----------------------------------------------------
24// -------------------------------------------------------------------------
25
26// ----- Public method Print -------------------------------------------
27void TTPoint::Print(const Option_t* opt) const {
28 cout << "-I- TargetPoint: ShipRpc point for track " << fTrackID
29 << " in detector " << fDetectorID << endl;
30 cout << " Position (" << fX << ", " << fY << ", " << fZ << ") cm" << endl;
31 cout << " Momentum (" << fPx << ", " << fPy << ", " << fPz << ") GeV"
32 << endl;
33 cout << " Time " << fTime << " ns, Length " << fLength
34 << " cm, Energy loss " << fELoss * 1.0e06 << " keV" << endl;
35}
36// -------------------------------------------------------------------------
TTPoint()
Definition: TTPoint.cxx:12
virtual ~TTPoint()
Definition: TTPoint.cxx:23
virtual void Print(const Option_t *opt) const
Definition: TTPoint.cxx:27