Compatibility with ROOT trunk
[u/mrichter/AliRoot.git] / T0 / AliT0RecoParam.cxx
index 82734d8e16503e0e0c59179a5fcbf901af84f4fd..ce1c1ccd68feaf2ed95a6f00fcc43294cd50132e 100644 (file)
@@ -33,6 +33,8 @@
 #include "AliT0RecoParam.h"
 #include "Riostream.h"
 
+using std::cout;
+using std::endl;
 ClassImp(AliT0RecoParam)
 
 
@@ -47,13 +49,22 @@ AliT0RecoParam::AliT0RecoParam():
    fLatencyL1A(0),  
    fLatencyL1C(0),  
    fLatencyHPTDC(0),      
-   fVertexShift(0)   
+  fVertexShift(0),
+  fEqualised(0)
 {
   //
   // constructor
-  //
   SetName("T0");
   SetTitle("T0");
+
+  fSatelliteThresholds[0] =  -15;
+  fSatelliteThresholds[1] =  -1.5;
+  for (Int_t i=0; i<500; i++)  {
+    fLow[i] = 0.;
+    fHigh[i] = 10000.;
+    if( i<24) fBadChannels[i]=-1;
+  }
 }
 
 //_____________________________________________________________________________
@@ -73,11 +84,19 @@ AliT0RecoParam::AliT0RecoParam(const AliT0RecoParam &p):
   fLatencyL1(p.fLatencyL1),  
   fLatencyL1A(p.fLatencyL1A),  
   fLatencyL1C(p.fLatencyL1C),  
- fLatencyHPTDC(p.fLatencyHPTDC),      
-  fVertexShift(p.fVertexShift)   
-{
 fLatencyHPTDC(p.fLatencyHPTDC),      
+  fVertexShift(p.fVertexShift), 
+  fEqualised( p.fEqualised)
+{ 
  //copy constructor
+  fSatelliteThresholds[0] = (p.fSatelliteThresholds[0]);
+  fSatelliteThresholds[1] = (p.fSatelliteThresholds[1]);
+  for (Int_t i=0; i<500; i++)  {
+    fLow[i] = p.fLow[i];
+    fHigh[i] = p.fHigh[i];
+    if( i<24) fBadChannels[i] = p.fBadChannels[i];
+  }
 
 }
 //_____________________________________________________________________________
@@ -100,7 +119,17 @@ AliT0RecoParam& AliT0RecoParam:: operator=(const AliT0RecoParam &p)
 
   fLatencyHPTDC = p.fLatencyHPTDC;
   fVertexShift = p.fVertexShift;
-  return *this;
+
+  fSatelliteThresholds[0] = (p.fSatelliteThresholds[0]);
+  fSatelliteThresholds[1] = (p.fSatelliteThresholds[1]);
+  fEqualised = p.fEqualised;
+  for (Int_t i=0; i<500; i++)  {
+    fLow[i] = p.fLow[i];
+    fHigh[i] = p.fHigh[i];
+    if( i<24) fBadChannels[i] = p.fBadChannels[i];
+  }
+ return *this;
 
 }
 //_____________________________________________________________________________
@@ -125,6 +154,8 @@ AliT0RecoParam *AliT0RecoParam::GetLowFluxParam()
     }
   param->SetName("Low Flux");
   param->SetTitle("Low Flux");
+  param->SetSatelliteThresholds(-15, -1.5);
+  param->SetEq(0);
   return param;
 }
 
@@ -150,7 +181,10 @@ AliT0RecoParam *AliT0RecoParam::GetHighFluxParam()
       param-> fHigh[i]=20000.;
     }
   //
-  param->SetName("High Flux");
+  param->SetSatelliteThresholds(-15, -1.5);
+  param->SetEq(0);
+
+   param->SetName("High Flux");
   param->SetTitle("High Flux");
   return param;
 }
@@ -171,7 +205,9 @@ AliT0RecoParam *AliT0RecoParam::GetLaserTestParam()
   param->fLatencyL1C =  7782.19;
   param->fLatencyHPTDC = 22000;
   param->fVertexShift = 0;
-
+  param->SetSatelliteThresholds(-15, -1.5);
+  param->SetEq(0);
+  
   for (Int_t i=0; i<500; i++)
     {
      param-> fLow[i]=0.;
@@ -190,9 +226,7 @@ void AliT0RecoParam::PrintParameters() const
   // Printing of the used T0 reconstruction parameters
   //
   AliInfo(Form(" Reference amplitude for walk corerection : %f", fRefAmp));
-  AliInfo(Form(" Reference point in channel  : %i", fRefPoint));
-  AliInfo(Form(" Current latency  : %f ns", fLatencyL1));
-  AliInfo(Form(" HPTDC latency  : %f ns", fLatencyHPTDC));
-  //  cout<<" AliT0RecoParam::PrintParameters() "<<endl;
-  //  for (Int_t i=0; i<500; i++) cout<<i<<" "<<fLow[i]<<" "<<fHigh[i]<<endl; 
+  AliInfo(Form(" Bad channel in channel  : %i", fRefPoint));
+  cout<<" AliT0RecoParam::PrintParameters() "<<endl;
+  for (Int_t i=0; i<105; i++) cout<<i<<" "<<fLow[i]<<" "<<fHigh[i]<<endl; 
 }