1 | // $Id: RecoTrackDirection.cc 1356 2005-01-05 13:08:21Z pesce $ |
---|
2 | // Author: Roberto Pesce 2005/01/04 |
---|
3 | |
---|
4 | /***************************************************************************** |
---|
5 | * ESAF: Euso Simulation and Analysis Framework * |
---|
6 | * * |
---|
7 | * Id: RecoTrackDirection * |
---|
8 | * Package: <packagename> * |
---|
9 | * Coordinator: <coordinator> * |
---|
10 | * * |
---|
11 | *****************************************************************************/ |
---|
12 | |
---|
13 | //_____________________________________________________________________________ |
---|
14 | // |
---|
15 | // RecoTrackDirection |
---|
16 | // |
---|
17 | // <extensive class description> |
---|
18 | // |
---|
19 | // Config file parameters |
---|
20 | // ====================== |
---|
21 | // |
---|
22 | // <parameter name>: <parameter description> |
---|
23 | // -Valid options: <available options> |
---|
24 | // |
---|
25 | |
---|
26 | #include "RecoTrackDirection.hh" |
---|
27 | |
---|
28 | ClassImp(RecoTrackDirection) |
---|
29 | |
---|
30 | //_____________________________________________________________________________ |
---|
31 | RecoTrackDirection::RecoTrackDirection() { |
---|
32 | // |
---|
33 | // Constructor |
---|
34 | // |
---|
35 | fQuality = -1; |
---|
36 | fTheta = -1; |
---|
37 | fPhi = -1; |
---|
38 | fErrorTheta = -1; |
---|
39 | fErrorPhi = -1; |
---|
40 | fErrorDirection = -1; |
---|
41 | fGraph = NULL; |
---|
42 | } |
---|
43 | |
---|
44 | //_____________________________________________________________________________ |
---|
45 | RecoTrackDirection::RecoTrackDirection( const RecoTrackDirection& other ) { |
---|
46 | // |
---|
47 | // Copy Constructor |
---|
48 | // |
---|
49 | other.Copy( *this ); |
---|
50 | } |
---|
51 | |
---|
52 | //_____________________________________________________________________________ |
---|
53 | RecoTrackDirection::~RecoTrackDirection() { |
---|
54 | // |
---|
55 | // Destructor |
---|
56 | // |
---|
57 | Clear(); |
---|
58 | } |
---|
59 | |
---|
60 | //_____________________________________________________________________________ |
---|
61 | void RecoTrackDirection::Clear() { |
---|
62 | // |
---|
63 | // Clear method |
---|
64 | // |
---|
65 | fQuality = -1; |
---|
66 | fTheta = -1; |
---|
67 | fPhi = -1; |
---|
68 | fErrorTheta = -1; |
---|
69 | fErrorPhi = -1; |
---|
70 | fErrorDirection = -1; |
---|
71 | SafeDelete(fGraph); |
---|
72 | } |
---|
73 | |
---|
74 | //_____________________________________________________________________________ |
---|
75 | void RecoTrackDirection::Copy( TObject& other ) const { |
---|
76 | // |
---|
77 | // Copy to new object |
---|
78 | // |
---|
79 | TObject::Copy( other ); |
---|
80 | |
---|
81 | ((RecoTrackDirection&)other).fQuality = fQuality; |
---|
82 | ((RecoTrackDirection&)other).fTheta = fTheta; |
---|
83 | ((RecoTrackDirection&)other).fPhi = fPhi; |
---|
84 | ((RecoTrackDirection&)other).fErrorTheta = fErrorTheta; |
---|
85 | ((RecoTrackDirection&)other).fErrorPhi = fErrorPhi; |
---|
86 | ((RecoTrackDirection&)other).fErrorDirection = fErrorDirection; |
---|
87 | ((RecoTrackDirection&)other).fGraph = fGraph ? (TMultiGraph*)fGraph->Clone() : NULL; |
---|
88 | } |
---|
89 | |
---|
90 | //_____________________________________________________________________________ |
---|
91 | void RecoTrackDirection::SetCheckInfo( TMultiGraph *t ) { |
---|
92 | // |
---|
93 | // Set the multigraph for check fitting |
---|
94 | // |
---|
95 | SafeDelete(fGraph); |
---|
96 | fGraph = (TMultiGraph*)t->Clone(); |
---|
97 | } |
---|