]>
Commit | Line | Data |
---|---|---|
9369bbee | 1 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * |
2 | * See cxx source for full Copyright notice */ | |
3 | ||
4 | // $Id$ | |
5 | ||
6 | /// \ingroup base | |
7 | /// \class AliMUONCalibParam1I | |
8 | /// \brief Implementation of AliMUONVCalibParam. | |
9 | /// | |
10 | /// Handle the case of 1 integer parameter per channel. | |
11 | /// | |
12 | /// \author Laurent Aphecetche | |
13 | ||
14 | #ifndef ALIMUONCALIBPARAM1I_H | |
15 | #define ALIMUONCALIBPARAM1I_H | |
16 | ||
17 | #ifndef ALIMUONVCALIBPARAM_H | |
18 | # include "AliMUONVCalibParam.h" | |
19 | #endif | |
20 | ||
21 | class AliMUONCalibParam1I : public AliMUONVCalibParam | |
22 | { | |
23 | public: | |
24 | AliMUONCalibParam1I(); | |
25 | AliMUONCalibParam1I(Int_t theSize, Int_t fillWithValue=0); | |
9d5f6a64 | 26 | AliMUONCalibParam1I(const AliMUONCalibParam1I& other); |
27 | AliMUONCalibParam1I& operator=(const AliMUONCalibParam1I& other); | |
9369bbee | 28 | virtual ~AliMUONCalibParam1I(); |
29 | ||
9d5f6a64 | 30 | /// The dimension of this object is 1, i.e. it's a vector. |
9369bbee | 31 | virtual Int_t Dimension() const { return 1; } |
32 | ||
33 | virtual void Print(Option_t* opt="") const; | |
34 | ||
9d5f6a64 | 35 | /** Set the value located at i (j must be zero). |
36 | * Note that the internal structure store ints, so the float is rounded | |
37 | * prior to be stored | |
38 | */ | |
9369bbee | 39 | virtual void SetValueAsFloat(Int_t i, Int_t j, Float_t value); |
9d5f6a64 | 40 | |
41 | /// Set the value located at i (j must be zero), as an int. | |
9369bbee | 42 | virtual void SetValueAsInt(Int_t i, Int_t j, Int_t value); |
43 | ||
9d5f6a64 | 44 | /// The number of values we hold. |
9369bbee | 45 | virtual Int_t Size() const { return fSize; } |
46 | ||
9d5f6a64 | 47 | /// Retrieve the value located at i (j must remain zero), as a float. |
9369bbee | 48 | virtual Float_t ValueAsFloat(Int_t i, Int_t j=0) const; |
9d5f6a64 | 49 | |
50 | /// Retrieve the value located at i (j must remain zero). | |
9369bbee | 51 | virtual Int_t ValueAsInt(Int_t i, Int_t j=0) const; |
52 | ||
9d5f6a64 | 53 | private: |
54 | /// Copy *this to destination (used by copy ctor and operator=). | |
55 | void CopyTo(AliMUONCalibParam1I& destination) const; | |
56 | ||
57 | private: | |
18b6b8c7 | 58 | Int_t fSize; ///< The number of values we hold |
59 | ||
60 | /// The values array | |
61 | Int_t* fValues; //[fSize] The values array | |
9369bbee | 62 | |
63 | ClassDef(AliMUONCalibParam1I,1) // Container for calibration parameters | |
64 | }; | |
65 | ||
66 | #endif |