1 |
#ifndef HbbAnalysis_BeamSpot_hh
|
2 |
#define HbbAnalysis_BeamSpot_hh
|
3 |
|
4 |
#include <vector>
|
5 |
#include <string>
|
6 |
|
7 |
#include "UserCode/HbbAnalysis/interface/Objects.hh"
|
8 |
|
9 |
namespace HbbAnalysis {
|
10 |
|
11 |
class BeamSpot {
|
12 |
|
13 |
public:
|
14 |
|
15 |
|
16 |
/** Constructors */
|
17 |
|
18 |
BeamSpot(){
|
19 |
//Clear();
|
20 |
};
|
21 |
|
22 |
~BeamSpot(){};
|
23 |
|
24 |
BeamSpot(const HbbAnalysis::BeamSpotVars & aBs){
|
25 |
Clear();
|
26 |
bsVars(aBs);
|
27 |
};
|
28 |
|
29 |
inline const HbbAnalysis::BeamSpotVars & bsVars() const {
|
30 |
return bs_;
|
31 |
};
|
32 |
|
33 |
inline void bsVars(const HbbAnalysis::BeamSpotVars & aBs) {
|
34 |
bs_ = aBs;
|
35 |
};
|
36 |
|
37 |
inline void Clear(){
|
38 |
|
39 |
bs_.x0 = 0;
|
40 |
bs_.y0 = 0;
|
41 |
bs_.z0 = 0;
|
42 |
bs_.sigmaZ = 0;
|
43 |
bs_.BeamWidthX = 0;
|
44 |
bs_.BeamWidthY = 0;
|
45 |
bs_.x0Error = 0;
|
46 |
bs_.y0Error = 0;
|
47 |
bs_.z0Error = 0;
|
48 |
bs_.sigmaZ0Error = 0;
|
49 |
bs_.BeamWidthXError = 0;
|
50 |
bs_.BeamWidthYError = 0;
|
51 |
};
|
52 |
|
53 |
inline void print(std::ostream & aOs){
|
54 |
|
55 |
aOs << "=======================================================" << std::endl
|
56 |
<< "================== Print BeamSpot ==================" << std::endl
|
57 |
<< "=======================================================" << std::endl
|
58 |
<< "====== x = " << bs_.x0 << std::endl
|
59 |
<< "====== y = " << bs_.y0 << std::endl
|
60 |
<< "====== z = " << bs_.z0 << std::endl
|
61 |
<< "====== xError = " << bs_.x0Error << std::endl
|
62 |
<< "====== yError = " << bs_.y0Error << std::endl
|
63 |
<< "====== zError = " << bs_.z0Error << std::endl
|
64 |
<< "=======================================================" << std::endl;
|
65 |
|
66 |
};
|
67 |
|
68 |
private:
|
69 |
|
70 |
HbbAnalysis::BeamSpotVars bs_;
|
71 |
|
72 |
};
|
73 |
|
74 |
}//namespace
|
75 |
#endif
|