1 /***************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 //-----------------------------------------------------//
17 // Date : August 05 2003 //
19 // Store cluster information //
21 //-----------------------------------------------------//
22 #include "Riostream.h"
24 #include "AliPMDcluster.h"
27 ClassImp(AliPMDcluster)
29 AliPMDcluster::AliPMDcluster():
33 // Default constructor
34 for (Int_t i = 0; i < 6; i++)
38 for (Int_t i = 0; i < 19; i++)
40 fClusCellDataX[i] = 0;
41 fClusCellDataY[i] = 0;
42 fClusCellTrack[i] = -1;
47 // --------------------------------------------------------------------- //
48 AliPMDcluster::AliPMDcluster(Int_t idet, Int_t ismn, Float_t *clusdata,
49 Int_t *celldataX, Int_t *celldataY,
50 Int_t *celltrack, Int_t *cellpid):
55 for (Int_t i = 0; i < 6; i++)
57 fClusData[i] = clusdata[i];
59 for (Int_t i = 0; i < 19; i++)
61 fClusCellDataX[i] = celldataX[i];
62 fClusCellDataY[i] = celldataY[i];
63 fClusCellTrack[i] = celltrack[i];
64 fClusCellPid[i] = cellpid[i];
68 // --------------------------------------------------------------------- //
69 AliPMDcluster::AliPMDcluster(AliPMDcluster *pmdcluster):
75 // --------------------------------------------------------------------- //
77 AliPMDcluster::AliPMDcluster(const AliPMDcluster &pmdcluster):
79 fDet(pmdcluster.fDet),
83 for(Int_t i=0; i<6; i++)
85 this->fClusData[i] = pmdcluster.fClusData[i];
87 for(Int_t i=0; i<19; i++)
89 this->fClusCellDataX[i] = pmdcluster.fClusCellDataX[i];
90 this->fClusCellDataY[i] = pmdcluster.fClusCellDataY[i];
91 this->fClusCellTrack[i] = pmdcluster.fClusCellTrack[i];
92 this->fClusCellPid[i] = pmdcluster.fClusCellPid[i];
95 // --------------------------------------------------------------------- //
97 AliPMDcluster & AliPMDcluster::operator=(const AliPMDcluster &pmdcluster)
99 // Assignment operator
100 if(this != &pmdcluster)
102 this->fDet = pmdcluster.fDet;
103 this->fSMN = pmdcluster.fSMN;
104 for(Int_t i=0; i<6; i++)
106 this->fClusData[i] = pmdcluster.fClusData[i];
108 for(Int_t i=0; i<19; i++)
110 this->fClusCellDataX[i] = pmdcluster.fClusCellDataX[i];
111 this->fClusCellDataY[i] = pmdcluster.fClusCellDataY[i];
112 this->fClusCellTrack[i] = pmdcluster.fClusCellTrack[i];
113 this->fClusCellPid[i] = pmdcluster.fClusCellPid[i];
118 // --------------------------------------------------------------------- //
120 AliPMDcluster::~AliPMDcluster()
124 // --------------------------------------------------------------------- //
126 Int_t AliPMDcluster::GetDetector() const
130 // --------------------------------------------------------------------- //
131 Int_t AliPMDcluster::GetSMN() const
135 // --------------------------------------------------------------------- //
136 Float_t AliPMDcluster::GetClusX() const
140 // --------------------------------------------------------------------- //
141 Float_t AliPMDcluster::GetClusY() const
145 // --------------------------------------------------------------------- //
146 Float_t AliPMDcluster::GetClusADC() const
150 // --------------------------------------------------------------------- //
151 Float_t AliPMDcluster::GetClusCells() const
155 // --------------------------------------------------------------------- //
156 Float_t AliPMDcluster::GetClusSigmaX() const
160 // --------------------------------------------------------------------- //
161 Float_t AliPMDcluster::GetClusSigmaY() const
165 // --------------------------------------------------------------------- //
166 Int_t AliPMDcluster::GetClusCellX(Int_t i) const
168 return fClusCellDataX[i];
170 // --------------------------------------------------------------------- //
171 Int_t AliPMDcluster::GetClusCellY(Int_t i) const
173 return fClusCellDataY[i];
175 // --------------------------------------------------------------------- //
176 Int_t AliPMDcluster::GetClusCellTrack(Int_t i) const
178 return fClusCellTrack[i];
180 // --------------------------------------------------------------------- //
181 Int_t AliPMDcluster::GetClusCellPid(Int_t i) const
183 return fClusCellPid[i];
185 // --------------------------------------------------------------------- //