]> git.uio.no Git - u/mrichter/AliRoot.git/blame - START/AliSTARTdigit.cxx
Warnings fixed
[u/mrichter/AliRoot.git] / START / AliSTARTdigit.cxx
CommitLineData
971579f6 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 **************************************************************************/
ef0750c2 15
88cb7938 16/* $Id$ */
0b73602e 17/////////////////////////////////////////////////////////////////////////
18// Class AliSTARTdigit for START digits
19// fTimeRight - right side TOF signal
20// fTimeLeft - left side TOF signal
21// fTimeBestRight - TOF first particle on the right side
22// TimeBestLeft - TOF first particle on the left side
23// fTimeAverage = (fTimeBestRight + TimeBestLeft ) /2. START signal
24// fTimeDiff = fTimeBestRight - TimeBestLeft
25//
26///////////////////////////////////////////////////////////////////////
971579f6 27
971579f6 28#include "AliSTARTdigit.h"
db173afc 29#include "TArrayI.h"
c345bb4f 30
971579f6 31ClassImp(AliSTARTdigit)
32
db173afc 33//-----------------------------------------------
34 AliSTARTdigit::AliSTARTdigit() :TObject()
e73d68f2 35{
e73d68f2 36
db173afc 37 fTimeAverage = 99999;
38 fTimeDiff = 99999;
39 fBestTimeRight = 99999;
40 fBestTimeLeft = 99999;
41
42 fTime = new TArrayI(24);
43 fADC = new TArrayI(24);
44 fTimeAmp = new TArrayI(24);
45 fADCAmp = new TArrayI(24);
46 fSumMult=new TArrayI(6);
e73d68f2 47}
db173afc 48
e73d68f2 49//-----------------------------------
7a18b6a5 50AliSTARTdigit::~AliSTARTdigit() {
51 // destructor
52 delete fTime;
53 delete fADC;
db173afc 54 delete fTimeAmp;
55 delete fADCAmp;
56 delete fSumMult;
7a18b6a5 57}
58//-----------------------------------
a84dec01 59void AliSTARTdigit::SetTime (TArrayI &o)
e73d68f2 60{
0b73602e 61 ////////////////////////////////////////
db173afc 62 fTime = new TArrayI(24);
e73d68f2 63
64 Int_t i;
db173afc 65 for (i=0; i<24; i++)
e73d68f2 66 {
67 Int_t buf=o.At(i);
a84dec01 68 fTime->AddAt(buf,i);
e73d68f2 69 }
70}
71//--------------------------------------------
a84dec01 72void AliSTARTdigit::GetTime (TArrayI &o)
e73d68f2 73{
0b73602e 74 //
e73d68f2 75 Int_t i;
db173afc 76 for (i=0; i<24; i++)
e73d68f2 77 {
a84dec01 78 o[i]=fTime->At(i);
e73d68f2 79 }
80}
81//--------------------------------------------
a84dec01 82void AliSTARTdigit::GetADC (TArrayI &o)
e73d68f2 83{
0b73602e 84 //
e73d68f2 85 Int_t i;
db173afc 86 for (i=0; i<24; i++)
e73d68f2 87 {
a84dec01 88 o[i]=fADC->At(i);
e73d68f2 89 }
90}
91//--------------------------------------------
a84dec01 92void AliSTARTdigit::SetADC (TArrayI &o)
e73d68f2 93{
0b73602e 94 //
db173afc 95 fADC = new TArrayI(24);
e73d68f2 96 Int_t i;
db173afc 97 for (i=0; i<24; i++)
e73d68f2 98 {
99 Int_t buf=(o.At(i));
a84dec01 100 fADC->AddAt(buf,i);
e73d68f2 101 }
102}
db173afc 103//-----------------------------------
104void AliSTARTdigit::SetTimeAmp (TArrayI &o)
105{
106 ////////////////////////////////////////
107 fTimeAmp = new TArrayI(24);
108
109 Int_t i;
110 for (i=0; i<24; i++)
111 {
112 Int_t buf=o.At(i);
113 fTimeAmp->AddAt(buf,i);
114 }
115}
116//--------------------------------------------
117void AliSTARTdigit::GetTimeAmp (TArrayI &o)
118{
119 //
120 Int_t i;
121 for (i=0; i<24; i++)
122 {
123 o[i]=fTimeAmp->At(i);
124 }
125}
126//--------------------------------------------
127void AliSTARTdigit::GetADCAmp (TArrayI &o)
128{
129 //
130 Int_t i;
131 for (i=0; i<24; i++)
132 {
133 o[i]=fADCAmp->At(i);
134 }
135}
136//--------------------------------------------
137void AliSTARTdigit::SetADCAmp (TArrayI &o)
138{
139 //
140 fADCAmp = new TArrayI(24);
141 Int_t i;
142 for (i=0; i<24; i++)
143 {
144 Int_t buf=(o.At(i));
145 fADCAmp->AddAt(buf,i);
146 }
147}
148//--------------------------------------------
149void AliSTARTdigit::GetSumMult (TArrayI &o)
150{
151 //
152 Int_t i;
153 for (i=0; i<6; i++)
154 {
155 o[i]=fSumMult->At(i);
156 }
157}
158//--------------------------------------------
159void AliSTARTdigit::SetSumMult (TArrayI &o)
160{
161 //
162 fSumMult = new TArrayI(24);
163 Int_t i;
164 for (i=0; i<6; i++)
165 {
166 Int_t buf=(o.At(i));
167 fSumMult->AddAt(buf,i);
168 }
169}