PandaRoot
PndMdtHit.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 PNDMDTHIT_HH
14 #define PNDMDTHIT_HH
15 
16 #include "FairHit.h"
17 #include "TVector3.h"
18 #include "TMath.h"
19 #include "PndMdtID.h"
20 
21 class PndMdtHit : public FairHit {
22 
23  public:
24  PndMdtHit();
25 
26  PndMdtHit(Int_t detID, TVector3 &pos, TVector3 &dpos, Int_t index);
27  PndMdtHit(Int_t detID, Int_t stripID, TVector3 &pos, TVector3 &dpos, Int_t bIndex, Int_t sIndex);
28 
29  PndMdtHit(Int_t detID, Int_t detID1, TVector3 &pos, TVector3 &dpos, Int_t bIndex);
30 
31  virtual ~PndMdtHit();
32 
34  virtual void Print(const Option_t *opt = nullptr) const;
35 
39  // void Clear(); // not implemented
40 
42  Short_t GetModule() const { return PndMdtID::Module(GetDetectorID()); }
43  Short_t GetSector() const { return PndMdtID::Sector(GetDetectorID()); }
44  Short_t GetLayerID() const { return PndMdtID::Layer(GetDetectorID()); }
45  Short_t GetBox() const { return PndMdtID::Box(GetDetectorID()); }
46  Short_t GetWire() const { return PndMdtID::Wire(GetDetectorID()); }
47  Short_t GetStrip1() const { return PndMdtID::Strip(fDetID1); }
48  Short_t GetStrip() const { return fStripID; };
49  Int_t GetStripIndex() const { return fStripIndex; };
50 
51  private:
52  Int_t fDetID1;
53  Short_t fStripID;
54  Int_t fStripIndex;
55 
56  ClassDef(PndMdtHit, 3);
57 };
58 
59 #endif
static Short_t Box(Int_t detID)
Definition: PndMdtID.h:31
static Short_t Module(Int_t detID)
Definition: PndMdtID.h:28
virtual void Print(const Option_t *opt=nullptr) const
static Short_t Layer(Int_t detID)
Definition: PndMdtID.h:30
Short_t GetSector() const
Definition: PndMdtHit.h:43
virtual ~PndMdtHit()
static Short_t Sector(Int_t detID)
Definition: PndMdtID.h:29
static Short_t Strip(Int_t detID)
Definition: PndMdtID.h:33
Short_t GetStrip() const
Definition: PndMdtHit.h:48
Short_t GetStrip1() const
Definition: PndMdtHit.h:47
static Short_t Wire(Int_t detID)
Definition: PndMdtID.h:32
Short_t GetLayerID() const
Definition: PndMdtHit.h:44
Int_t GetStripIndex() const
Definition: PndMdtHit.h:49
Short_t GetModule() const
Definition: PndMdtHit.h:42
Short_t GetWire() const
Definition: PndMdtHit.h:46
Short_t GetBox() const
Definition: PndMdtHit.h:45