PandaRoot
PndSttTube.h
Go to the documentation of this file.
1 #ifndef PNDSTTTUBE_H
2 #define PNDSTTTUBE_H 1
3 
4 #include "TVector3.h"
5 #include "TMatrixT.h"
6 #include "TObject.h"
7 #include "TArrayI.h"
8 #include "PndSttTubeParameters.h"
9 
11 class PndSttTube : public TObject {
12 
13  public:
15  PndSttTube();
16  PndSttTube(PndSttTube &tube);
17 
18  ~PndSttTube();
19  PndSttTube(PndSttTubeParameters *parms, Double_t x, Double_t y, Double_t z, Double_t r11, Double_t r12, Double_t r13, Double_t r21, Double_t r22, Double_t r23, Double_t r31,
20  Double_t r32, Double_t r33, Double_t radin, Double_t radout);
21 
23  {
24  fTubeParms = o.fTubeParms;
25  fCenPosition = o.fCenPosition;
26  fRotationMatrix = o.fRotationMatrix;
27  fRadIn = o.fRadIn;
28  fRadOut = o.fRadOut;
29  fSectorID = o.fSectorID;
30  fLayerID = o.fLayerID;
31  fNeighborings = o.fNeighborings;
32  fLayerLimit = o.fLayerLimit;
33  fSectorLimit = o.fSectorLimit;
34  return *this;
35  };
36 
37  TVector3 GetPosition();
38  TMatrixT<Double_t> GetRotationMatrix();
39  Double_t GetRadIn();
40  Double_t GetRadOut();
41  Double_t GetHalfLength();
42  TVector3 GetWireDirection();
44  Int_t GetTubeID();
45  void SetSectorID(int id);
46  void SetLayerID(int id);
47  int GetLayerID();
48  int GetSectorID();
49  void SetNeighborings(TArrayI neighborings);
50  TArrayI GetNeighborings();
51  Int_t GetNeighboring(int i);
52  Double_t GetDistance(PndSttTube *tube);
53  Bool_t IsNeighboring(int tubeID);
54 
55  void SetSectorLimitFlag(Int_t flag) { fSectorLimit = flag; }
56  void SetLayerLimitFlag(Bool_t flag = kTRUE) { fLayerLimit = flag; }
57  bool IsLayerLimit() { return fLayerLimit; }
58  int IsSectorLimit() { return fSectorLimit; }
59 
60  bool IsParallel() { return (GetWireDirection().Z() == 1); }
61 
62  bool IsSkew() { return !(GetWireDirection().Z() == 1); }
63 
64  private:
65  PndSttTubeParameters *fTubeParms;
66  TVector3 fCenPosition;
67  TMatrixT<double> fRotationMatrix;
68  Double_t fRadIn, fRadOut;
69  Int_t fSectorID, fLayerID;
70  TArrayI fNeighborings;
71  Bool_t fLayerLimit;
72  Int_t fSectorLimit;
73 
74  ClassDef(PndSttTube, 1);
75 };
76 
77 #endif
void SetSectorID(int id)
Double_t GetHalfLength()
void SetLayerLimitFlag(Bool_t flag=kTRUE)
Definition: PndSttTube.h:56
void SetSectorLimitFlag(Int_t flag)
Definition: PndSttTube.h:55
Double_t GetDistance(PndSttTube *tube)
unsigned int i
Definition: P4_F32vec4.h:21
void SetNeighborings(TArrayI neighborings)
Double_t GetRadIn()
int GetLayerID()
TMatrixT< Double_t > GetRotationMatrix()
PndSttTube & operator=(const PndSttTube &o)
Definition: PndSttTube.h:22
Bool_t IsNeighboring(int tubeID)
Int_t GetTubeID()
TArrayI GetNeighborings()
TVector3 GetPosition()
PndSttTubeParameters * GetTubeParameters()
int IsSectorLimit()
Definition: PndSttTube.h:58
Int_t GetNeighboring(int i)
bool IsParallel()
Definition: PndSttTube.h:60
int GetSectorID()
Double_t GetRadOut()
TVector3 GetWireDirection()
void SetLayerID(int id)
bool IsSkew()
Definition: PndSttTube.h:62
bool IsLayerLimit()
Definition: PndSttTube.h:57