FACT++  1.0
Led.h
Go to the documentation of this file.
1 #ifndef COSY_Led
2 #define COSY_Led
3 
4 #include <stdint.h>
5 
6 class Ring;
7 
8 class Led
9 {
10 private:
11  double fX;
12  double fY;
13  double fPhi;
14 
15  double fMag;
16 
17 public:
18  Led(double x=0, double y=0, double phi=0, double mag=0) :
19  fX(x), fY(y), fPhi(phi), fMag(mag)
20  {
21  }
22 
23  /*
24  int32_t Compare(const TObject *obj) const
25  {
26  const Led *const l = (Led*)obj;
27 
28  if (fPhi<l->fPhi)
29  return -1;
30 
31  if (fPhi>l->fPhi)
32  return 1;
33 
34  return 0;
35  }*/
36 
37  void SetX(double x) { fX=x; }
38  void SetY(double y) { fY=y; }
39  void SetPhi(double phi) { fPhi=phi; }
40 
41  double GetX() const { return fX; }
42  double GetY() const { return fY; }
43  double GetPhi() const { return fPhi; }
44  double GetMag() const { return fMag; }
45 
46  void AddOffset(double dx, double dy) { fX+=dx; fY+=dy; }
47 
48  //bool IsSortable() const { return kTRUE; }
49 
50  double CalcPhi(const Ring &ring);
51 
52  //void Print(Option_t *o=NULL) const;
53 };
54 
55 #endif
void SetPhi(double phi)
Definition: Led.h:39
double GetPhi() const
Definition: Led.h:43
Led(double x=0, double y=0, double phi=0, double mag=0)
Definition: Led.h:18
double GetMag() const
Definition: Led.h:44
double CalcPhi(const Ring &ring)
Definition: Led.cc:9
float mag
Definition: HeadersSQM.h:89
double GetY() const
Definition: Led.h:42
Definition: Led.h:8
double fX
Definition: Led.h:11
double fMag
Definition: Led.h:15
Definition: Ring.h:10
void AddOffset(double dx, double dy)
Definition: Led.h:46
double fY
Definition: Led.h:12
void SetY(double y)
Definition: Led.h:38
double GetX() const
Definition: Led.h:41
void SetX(double x)
Definition: Led.h:37
double fPhi
Definition: Led.h:13