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 **************************************************************************/
16 ///////////////////////////////////////////////////////////////////////////////
18 // class for TOF Online calibration: defining channel delay //
19 // using an array instead of a TObjArray //
21 ///////////////////////////////////////////////////////////////////////////////
23 #include <AliTOFChannelOnlineArray.h>
26 ClassImp(AliTOFChannelOnlineArray)
28 //________________________________________________________________
29 AliTOFChannelOnlineArray::AliTOFChannelOnlineArray():
36 //________________________________________________________________
37 AliTOFChannelOnlineArray::~AliTOFChannelOnlineArray()
42 //________________________________________________________________
43 AliTOFChannelOnlineArray::AliTOFChannelOnlineArray(Int_t size):
46 fArray(new Float_t[size])
49 for (Int_t ich = 0; ich<size; ich ++){
53 //________________________________________________________________
54 AliTOFChannelOnlineArray::AliTOFChannelOnlineArray(const AliTOFChannelOnlineArray & source):
61 //________________________________________________________________
62 AliTOFChannelOnlineArray &AliTOFChannelOnlineArray::operator=(const AliTOFChannelOnlineArray & source)
64 // assignment operator
69 TObject::operator=(source);
71 fArray= source.fArray;
74 //________________________________________________________________
75 void AliTOFChannelOnlineArray::SetDelay(Int_t pos, Float_t parr)
77 // setting status for channel at position = pos
78 AliDebug(2,Form("status = %d",(Float_t)parr));
79 if (pos>-1 && pos < fSize)fArray[pos] = parr;
80 AliDebug(2,Form("fArray[%d] = %d",pos,(Float_t)fArray[pos]));
82 //________________________________________________________________
83 Float_t AliTOFChannelOnlineArray::GetDelay(Int_t pos) const
85 // getting the status for channel at position = pos
87 if (pos>-1 && pos < fSize)parr = fArray[pos];