]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Fixing bug in the constructor, which apeared in new root
authormarian <marian@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 9 Sep 2010 14:42:36 +0000 (14:42 +0000)
committermarian <marian@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 9 Sep 2010 14:42:36 +0000 (14:42 +0000)
5-27-03

TPC/AliTPCROCVoltError3D.cxx
TPC/AliTPCROCVoltError3D.h

index 0734616adda78ab571ab630fbae144a6a6fe3844..fc1204ba314e4b87d97eade812c5d40f00595d80 100644 (file)
@@ -50,7 +50,7 @@ AliTPCROCVoltError3D::AliTPCROCVoltError3D()
     fC0(0.),fC1(0.),
     fROCdisplacement(kTRUE),
     fInitLookUp(kFALSE),
-    fROCDataFileName((char*)"$(ALICE_ROOT)/TPC/Calib/maps/TPCROCdzSurvey.root"),  
+    fROCDataFileName(""),  
     fdzDataLinFit(0)
 {
   //
@@ -65,8 +65,8 @@ AliTPCROCVoltError3D::AliTPCROCVoltError3D()
     fLookUpEphiOverEz[k] =  new TMatrixD(kNR,kNZ);
     fLookUpDeltaEz[k]    =  new TMatrixD(kNR,kNZ);   
   }
-
-  SetROCDataFileName(fROCDataFileName); // initialization of fdzDataLinFit is included
+  fROCDataFileName="$ALICE_ROOT/TPC/Calib/maps/TPCROCdzSurvey.root";
+  SetROCDataFileName(fROCDataFileName.Data()); // initialization of fdzDataLinFit is included
 
 }
 
@@ -84,7 +84,7 @@ AliTPCROCVoltError3D::~AliTPCROCVoltError3D() {
   delete fdzDataLinFit;
 }
 
-void AliTPCROCVoltError3D::SetDZMap(TMatrixD * matrix){
+void AliTPCROCVoltError3D::SetROCData(TMatrixD * matrix){
   //
   // Set a z alignment map of the chambers not via a file, but
   // directly via a TMatrix(72,3), where dz = p0 + p1*lx + p2*ly
@@ -130,14 +130,14 @@ void AliTPCROCVoltError3D::Update(const TTimeStamp &/*timeStamp*/) {
 
 }
 
-void  AliTPCROCVoltError3D::SetROCDataFileName(char *const fname) {
+void  AliTPCROCVoltError3D::SetROCDataFileName(const char * fname) {
   //
   // Set / load the ROC data (linear fit of ROC misalignments)
   //
 
   fROCDataFileName = fname;
   
-  TFile f(fROCDataFileName,"READ");
+  TFile f(fROCDataFileName.Data(),"READ");
   TMatrixD *m = (TMatrixD*) f.Get("dzSurveyLinFitData");
   TMatrixD &mf = *m;
 
@@ -441,7 +441,7 @@ void AliTPCROCVoltError3D::Print(const Option_t* option) const {
   TString opt = option; opt.ToLower();
   printf("%s\n",GetTitle());
   printf(" - Voltage settings on the TPC Read-Out chambers - linearly interpolated\n");
-  printf("   info: Check the following data-file for more details: %s \n",fROCDataFileName);
+  printf("   info: Check the following data-file for more details: %s \n",fROCDataFileName.Data());
 
   if (opt.Contains("a")) { // Print all details
     printf(" - T1: %1.4f, T2: %1.4f \n",fT1,fT2);
index 42c91c3116c55f1ae5d0b1a5ee00a82b96084b3d..350466b6106f2b1178b584f171d0e4ebebc6041e 100644 (file)
@@ -33,10 +33,10 @@ public:
   void SetC0C1(Float_t c0,Float_t c1) {fC0=c0;fC1=c1;} // CAUTION: USE WITH CARE
   Float_t GetC0() const {return fC0;}
   Float_t GetC1() const {return fC1;}
-  void SetDZMap(TMatrixD * matrix);
+  void SetROCData(TMatrixD * matrix);
   // setters and getters 
-  void SetROCDataFileName(char *const fname);
-  char* GetROCDataFileName() const {return fROCDataFileName;}
+  void SetROCDataFileName(const char * fname);
+  const Char_t* GetROCDataFileName() const {return fROCDataFileName.Data();}
 
   // flag to wheter or not include the z aligment in the dz calculation 
   // if FALSE, the dz offset is purely due to the electric field change
@@ -70,7 +70,7 @@ private:
   TMatrixD *fLookUpEphiOverEz[kNPhi]; // Array to store electric field integral (int Er/Ez)
   TMatrixD *fLookUpDeltaEz[kNPhi];    // Array to store electric field integral (int Er/Ez)
 
-  char *fROCDataFileName;         // filename of the survey data containing the lin Fit values
+  TString  fROCDataFileName;         // filename of the survey data containing the lin Fit values
   TMatrixD *fdzDataLinFit;  // Linear fits of dz survey points (each sector=72) (z0,slopeX,slopeY)         
 
   // basic numbers for the poisson relaxation //can be set individually in each class