]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TOF/AliTOFcluster.cxx
1.The QA data created on demand according to the event species at filling time. 2...
[u/mrichter/AliRoot.git] / TOF / AliTOFcluster.cxx
CommitLineData
571dda3d 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/*
16Revision 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
20Revision 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
0e46b9ae 26////////////////////////////////////////////////////////
27// //
28// AliTOFcluster Class //
29// Description: class for TOF cluster definition //
30// //
31////////////////////////////////////////////////////////
571dda3d 32
33#include "AliTOFcluster.h"
5c7c93fa 34//#include "AliLog.h"
35//#include "AliGeomManager.h"
36//#include "TGeoMatrix.h"
571dda3d 37
38ClassImp(AliTOFcluster)
39
58d8d9a3 40AliTOFcluster::AliTOFcluster():
638f14f1 41 AliCluster3D(),
58d8d9a3 42 fIdx(-1),
638f14f1 43 fQuality(-100),
58d8d9a3 44 fR(0),
45 fPhi(0),
bf33f8f0 46 fTDC(0),
58d8d9a3 47 fToT(0),
bf33f8f0 48 fADC(0),
58d8d9a3 49 fTdcND(0),
aa5476d8 50 fTdcRAW(0),
58d8d9a3 51 fStatus(kTRUE)
52 {
571dda3d 53 //
54 // default ctor
55 //
56
57 Int_t ii;
571dda3d 58 for (ii=0; ii<5; ii++) fdetIndex[ii] = -1;
571dda3d 59}
60//-------------------------------------------------------------------------
61
638f14f1 62AliTOFcluster::AliTOFcluster(UShort_t volId,
63 Float_t x, Float_t y, Float_t z,
64 Float_t sx2, Float_t sxy, Float_t sxz,
3e2f0097 65 Float_t sy2, Float_t syz,
638f14f1 66 Float_t sz2, Int_t *lab, Int_t *ind, Int_t *par, Bool_t status, Int_t idx):
67 AliCluster3D(volId,x,y,z,sx2,sxy,sxz,sy2,syz,sz2,lab),
a79b519b 68 fIdx(idx),
a79b519b 69 fQuality(-100),
638f14f1 70 fR(0),
71 fPhi(0),
bf33f8f0 72 fTDC(par[0]),
73 fToT(par[1]),
74 fADC(par[2]),
75 fTdcND(par[3]),
76 fTdcRAW(par[4]),
a79b519b 77 fStatus(status)
78 {
79 //
80 // constructor
81 //
638f14f1 82 Int_t ii;
83 for (ii=0; ii<5; ii++) fdetIndex[ii] = ind[ii];
84
85 Float_t xyz[3];
86 GetGlobalXYZ(xyz);
3e2f0097 87 fR = TMath::Sqrt(xyz[0]*xyz[0] + xyz[1]*xyz[1]);
88 fPhi = TMath::ATan2(xyz[1], xyz[0]);
a79b519b 89
571dda3d 90}
91//-------------------------------------------------------------------------
92
58d8d9a3 93AliTOFcluster::AliTOFcluster(const AliTOFcluster & cluster):
638f14f1 94 AliCluster3D(cluster),
95 fIdx(cluster.fIdx),
96 fQuality(cluster.fQuality),
97 fR(cluster.fR),
98 fPhi(cluster.fPhi),
99 fTDC(cluster.fTDC),
100 fToT(cluster.fToT),
101 fADC(cluster.fADC),
102 fTdcND(cluster.fTdcND),
103 fTdcRAW(cluster.fTdcRAW),
104 fStatus(cluster.fStatus)
58d8d9a3 105 {
571dda3d 106 //
107 // copy ctor for AliTOFcluster object
108 //
109
110 Int_t ii;
571dda3d 111 for (ii=0; ii<5; ii++) fdetIndex[ii] = cluster.fdetIndex[ii];
571dda3d 112}
113//-------------------------------------------------------------------------
114
115AliTOFcluster::~AliTOFcluster() {
638f14f1 116
571dda3d 117 //
118 // dtor
119 //
120
571dda3d 121}
638f14f1 122
123