CMS 3D CMS Logo

DeviationsFromFileSensor2D.h
Go to the documentation of this file.
1 // COCOA class header file
2 //Id: DeviationsFromFileSensor2D.h
3 //CAT: Model
4 //
5 // Base class to describe Optical Objects of type sensor 2D
6 //
7 // History: v1.0
8 // Pedro Arce
9 
10 #ifndef _DEVIATIONSTRAVERSINGSENSOR2D_HH
11 #define _DEVIATIONSTRAVERSINGSENSOR2D_HH
12 
15 
16 #include <vector>
17 
18 class ALIFileIn;
19 
20 typedef std::vector<std::vector<DeviationSensor2D*> > vvd;
21 typedef std::vector<DeviationSensor2D*> vd;
22 
24 public:
25  //---------- Constructors / Destructor
27  theOffsetX = 0.;
28  theOffsetY = 0.;
29  };
31 
32  // read file
33  void readFile(ALIFileIn& ifdevi);
34 
35  // get the deviation in the matrix corresponding to the intersection point (intersx, intersy)
36  std::pair<ALIdouble, ALIdouble> getDevis(ALIdouble intersX, ALIdouble intersY);
37 
38  // set offsetX/Y
39  void setOffset(ALIdouble offX, ALIdouble offY) {
40  theOffsetX = offX;
41  theOffsetY = offY;
42  }
43 
44  // Access data
45  static const ALIbool apply() { return theApply; }
46 
47  // Set data
48  static void setApply(ALIbool val) { theApply = val; }
49 
50 private:
53 
56  static ALIbool theApply;
57 
59 
61 };
62 
63 #endif
long double ALIdouble
Definition: CocoaGlobals.h:11
std::pair< ALIdouble, ALIdouble > getDevis(ALIdouble intersX, ALIdouble intersY)
int ALIint
Definition: CocoaGlobals.h:15
std::vector< std::vector< DeviationSensor2D * > > vvd
bool ALIbool
Definition: CocoaGlobals.h:19
std::vector< DeviationSensor2D * > vd
static void setApply(ALIbool val)
void setOffset(ALIdouble offX, ALIdouble offY)
unsigned int ALIuint
Definition: CocoaGlobals.h:17