]> git.uio.no Git - u/mrichter/AliRoot.git/blob - TOF/AliTOFcluster.cxx
Coding convention violations (RC17): suppression
[u/mrichter/AliRoot.git] / TOF / AliTOFcluster.cxx
1 /**************************************************************************
2  * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3  *                                                                        *
4  * Author: The ALICE Off-line Project.                                    *
5  * Contributors are mentioned in the code where appropriate.              *
6  *                                                                        *
7  * Permission to use, copy, modify and distribute this software and its   *
8  * documentation strictly for non-commercial purposes is hereby granted   *
9  * without fee, provided that the above copyright notice appears in all   *
10  * copies and that both the copyright notice and this permission notice   *
11  * appear in the supporting documentation. The authors make no claims     *
12  * about the suitability of this software for any purpose. It is          *
13  * provided "as is" without express or implied warranty.                  *
14  **************************************************************************/
15 /*
16 Revision 0.02 2005/07/27 A. De Caro
17          Implement new ctor AliTOFcluster(Double_t *, Int_t *)
18          for cluster construction from raw data
19
20 Revision 0.01 2005/07/25 A. De Caro
21          Implement new class statring from
22          class definition inside AliTOFtracker class
23          (originally implemented by S. Arcelli and C. Zampolli)
24 */
25
26 ////////////////////////////////////////////////////////
27 //                                                    //
28 //    AliTOFcluster Class                             //
29 //    Description: class for TOF cluster definition   //
30 //                                                    //
31 ////////////////////////////////////////////////////////
32
33 #include "AliTOFcluster.h"
34 //#include "AliLog.h"
35 //#include "AliGeomManager.h"
36 //#include "TGeoMatrix.h"
37
38 ClassImp(AliTOFcluster)
39
40 AliTOFcluster::AliTOFcluster():
41   AliCluster3D(),
42   fIdx(-1),
43   fQuality(-100), 
44   fR(0),
45   fPhi(0),
46   fTDC(0),
47   fToT(0),
48   fADC(0),
49   fTdcND(0),
50   fTdcRAW(0),
51   fStatus(kTRUE) 
52  {
53   //
54   // default ctor
55   //
56
57   Int_t ii;
58   for (ii=0; ii<5; ii++) fdetIndex[ii] = -1;
59 }
60 //-------------------------------------------------------------------------
61
62 AliTOFcluster::AliTOFcluster(UShort_t volId, 
63    Float_t x,   Float_t y,   Float_t z,
64    Float_t sx2, Float_t sxy, Float_t sxz,
65                 Float_t sy2, Float_t syz,
66                              Float_t sz2,
67                              Int_t *lab, Int_t * const ind,
68                              Int_t *par, Bool_t status, Int_t idx):
69   AliCluster3D(volId,x,y,z,sx2,sxy,sxz,sy2,syz,sz2,lab),
70   fIdx(idx),
71   fQuality(-100), 
72   fR(0),
73   fPhi(0),
74   fTDC(par[0]),
75   fToT(par[1]),
76   fADC(par[2]),
77   fTdcND(par[3]),
78   fTdcRAW(par[4]),
79   fStatus(status) 
80  {
81   //
82   // constructor
83   //
84    Int_t ii;
85    for (ii=0; ii<5; ii++) fdetIndex[ii] = ind[ii];
86    
87    Float_t xyz[3];
88    GetGlobalXYZ(xyz);
89    fR   = TMath::Sqrt(xyz[0]*xyz[0] + xyz[1]*xyz[1]);   
90    fPhi = TMath::ATan2(xyz[1], xyz[0]);
91
92 }
93 //-------------------------------------------------------------------------
94
95 AliTOFcluster::AliTOFcluster(const AliTOFcluster & cluster):
96   AliCluster3D(cluster),
97   fIdx(cluster.fIdx),
98   fQuality(cluster.fQuality), 
99   fR(cluster.fR),
100   fPhi(cluster.fPhi),
101   fTDC(cluster.fTDC),
102   fToT(cluster.fToT),
103   fADC(cluster.fADC),
104   fTdcND(cluster.fTdcND),
105   fTdcRAW(cluster.fTdcRAW),
106   fStatus(cluster.fStatus) 
107  {
108   //
109   // copy ctor for AliTOFcluster object
110   //
111
112   Int_t ii;
113   for (ii=0; ii<5; ii++) fdetIndex[ii] = cluster.fdetIndex[ii];
114 }
115 //-------------------------------------------------------------------------
116
117 AliTOFcluster::~AliTOFcluster() {
118
119   //
120   // dtor
121   //
122
123 }
124
125