]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/AliMUONCalibParamNI.h
Fix for copy/paste error (coveruty 19966)
[u/mrichter/AliRoot.git] / MUON / AliMUONCalibParamNI.h
CommitLineData
96fea1fd 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 calib
7/// \class AliMUONCalibParamNI
8/// \brief Implementation of AliMUONVCalibParam for tuples of ints
9///
10// Author Laurent Aphecetche
11
12#ifndef ALIMUONCALIBPARAMNI_H
13#define ALIMUONCALIBPARAMNI_H
14
15#ifndef ALIMUONVCALIBPARAM_H
16# include "AliMUONVCalibParam.h"
17#endif
18
19class AliMUONCalibParamNI : public AliMUONVCalibParam
20{
21public:
22 AliMUONCalibParamNI();
a1546c3a 23 AliMUONCalibParamNI(Int_t dimension, Int_t theSize, Int_t id0, Int_t id1, Int_t fillWithValue=0, Int_t packingValue=0);
96fea1fd 24 AliMUONCalibParamNI(const AliMUONCalibParamNI& other);
25 AliMUONCalibParamNI& operator=(const AliMUONCalibParamNI& other);
26
27 virtual ~AliMUONCalibParamNI();
28
4db2bfee 29 /// Own clone methods (as the default TObject::Clone turned out to be pretty slow !)
30 virtual TObject* Clone(const char* = "") const { return new AliMUONCalibParamNI(*this); }
31
96fea1fd 32 /// Return dimension
33 virtual Int_t Dimension() const { return fDimension; }
34
35 virtual void Print(Option_t* opt="") const;
36
37 virtual void SetValueAsFloat(Int_t i, Int_t j, Float_t value);
4db2bfee 38 virtual void SetValueAsFloatFast(Int_t i, Int_t j, Float_t value);
96fea1fd 39 virtual void SetValueAsInt(Int_t i, Int_t j, Int_t value);
4db2bfee 40 virtual void SetValueAsIntFast(Int_t i, Int_t j, Int_t value);
96fea1fd 41
42 /// Return size - the number of float pair we hold
43 virtual Int_t Size() const { return fSize; }
44
45 virtual Float_t ValueAsFloat(Int_t i, Int_t j=0) const;
4db2bfee 46 virtual Float_t ValueAsFloatFast(Int_t i, Int_t j=0) const;
96fea1fd 47 virtual Int_t ValueAsInt(Int_t i, Int_t j=0) const;
4db2bfee 48 virtual Int_t ValueAsIntFast(Int_t i, Int_t j=0) const;
96fea1fd 49
50 virtual Bool_t UnpackValue(Int_t value, Int_t& a, Int_t& b) const;
51
52 virtual Bool_t PackValues(Int_t a, Int_t b, Int_t& packedValue) const;
53
54 virtual Bool_t IsPacked() const;
55
56private:
57 void CopyTo(AliMUONCalibParamNI& destination) const;
58 Int_t Index(Int_t i, Int_t j) const;
4db2bfee 59 Int_t IndexFast(Int_t i, Int_t j) const;
96fea1fd 60
61private:
62 Int_t fDimension; ///< dimension of this object
63 Int_t fSize; ///< The number of float pair we hold
64 Int_t fN; ///< The total number of floats we hold (fDimension*fSize)
65 Int_t fPackingFactor; ///< packing factor, i.e. value = a*fPackingFactor + b
66
67 /// The values array
68 Int_t* fValues; //[fN] The values array
69
a1546c3a 70 ClassDef(AliMUONCalibParamNI,3) // Container for calibration parameters
96fea1fd 71};
72
73#endif