AliRoot Core  a565103 (a565103)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliMUONCalibParamND.h
Go to the documentation of this file.
1 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
2 * See cxx source for full Copyright notice */
3 
4 // $Id$
5 
10 // Author Laurent Aphecetche
11 
12 #ifndef ALIMUONCALIBPARAMND_H
13 #define ALIMUONCALIBPARAMND_H
14 
15 #ifndef ALIMUONVCALIBPARAM_H
16 # include "AliMUONVCalibParam.h"
17 #endif
18 
20 {
21 public:
23  AliMUONCalibParamND(Int_t dimension, Int_t theSize, Int_t id0, Int_t id1, Double_t fillWithValue=0);
26 
27  virtual ~AliMUONCalibParamND();
28 
30  virtual TObject* Clone(const char* = "") const { return new AliMUONCalibParamND(*this); }
31 
33  virtual Int_t Dimension() const { return fDimension; }
34 
35  virtual void Print(Option_t* opt="") const;
36 
37  virtual void SetValueAsDouble(Int_t i, Int_t j, Double_t value);
38  virtual void SetValueAsDoubleFast(Int_t i, Int_t j, Double_t value);
39  virtual void SetValueAsFloat(Int_t i, Int_t j, Float_t value);
40  virtual void SetValueAsFloatFast(Int_t i, Int_t j, Float_t value);
41  virtual void SetValueAsInt(Int_t i, Int_t j, Int_t value);
42  virtual void SetValueAsIntFast(Int_t i, Int_t j, Int_t value);
43 
45  virtual Int_t Size() const { return fSize; }
46 
47  virtual Float_t ValueAsFloat(Int_t i, Int_t j=0) const;
48  virtual Float_t ValueAsFloatFast(Int_t i, Int_t j=0) const;
49  virtual Double_t ValueAsDouble(Int_t i, Int_t j=0) const;
50  virtual Double_t ValueAsDoubleFast(Int_t i, Int_t j=0) const;
51  virtual Int_t ValueAsInt(Int_t i, Int_t j=0) const;
52  virtual Int_t ValueAsIntFast(Int_t i, Int_t j=0) const;
53 
55  virtual Bool_t IsDoublePrecision() const { return kTRUE; }
56 
57 private:
58  void CopyTo(AliMUONCalibParamND& destination) const;
59  Int_t Index(Int_t i, Int_t j) const;
60  Int_t IndexFast(Int_t i, Int_t j) const;
61 
62 private:
63  Int_t fDimension;
64  Int_t fSize;
65  Int_t fN;
66 
68  Double_t* fValues; //[fN] The values array
69 
70  ClassDef(AliMUONCalibParamND,1) // Container for calibration parameters
71 };
72 
73 #endif
virtual Int_t Size() const
Return size - the number of double tuples we hold.
void CopyTo(AliMUONCalibParamND &destination) const
virtual TObject * Clone(const char *="") const
Own clone methods (as the default TObject::Clone turned out to be pretty slow !)
virtual void SetValueAsInt(Int_t i, Int_t j, Int_t value)
Set one value, for channel i, dimension j. Consider value is an integer.
virtual void SetValueAsIntFast(Int_t i, Int_t j, Int_t value)
Same as above but w/o bound checkings.
Int_t fSize
The number of double tuples we hold.
virtual Bool_t IsDoublePrecision() const
Advertise that we can store double precision values.
Int_t IndexFast(Int_t i, Int_t j) const
Int_t fN
The total number of floats we hold (fDimension*fSize)
virtual Double_t ValueAsDoubleFast(Int_t i, Int_t j=0) const
virtual void SetValueAsDouble(Int_t i, Int_t j, Double_t value)
Int_t fDimension
dimension of this object
Container of calibration values for a given number of channels.
virtual void SetValueAsDoubleFast(Int_t i, Int_t j, Double_t value)
Same as above but w/o bound checking.
virtual Float_t ValueAsFloatFast(Int_t i, Int_t j=0) const
Same as above but without bound checking.
virtual Double_t ValueAsDouble(Int_t i, Int_t j=0) const
Implementation of AliMUONVCalibParam for tuples of double.
virtual void SetValueAsFloatFast(Int_t i, Int_t j, Float_t value)
virtual Int_t ValueAsIntFast(Int_t i, Int_t j=0) const
Same as above but w/o bound checking.
virtual void SetValueAsFloat(Int_t i, Int_t j, Float_t value)
Set one value, for channel i, dimension j. Consider value is a float.
Int_t Index(Int_t i, Int_t j) const
virtual Int_t Dimension() const
Return dimension.
Double_t * fValues
The values array.
virtual void Print(Option_t *opt="") const
virtual Int_t ValueAsInt(Int_t i, Int_t j=0) const
AliMUONCalibParamND & operator=(const AliMUONCalibParamND &other)
virtual Float_t ValueAsFloat(Int_t i, Int_t j=0) const