Adding the getters for the T0 spread and the TOF resolution (A. De Caro)
authorbelikov <belikov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 2 Nov 2010 10:51:01 +0000 (10:51 +0000)
committerbelikov <belikov@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 2 Nov 2010 10:51:01 +0000 (10:51 +0000)
STEER/AliESDEvent.h
STEER/AliESDpid.cxx

index 167cff6..808a523 100644 (file)
@@ -253,7 +253,8 @@ public:
 
   void SetTOFHeader(const AliTOFHeader * tofEventTime);
   const AliTOFHeader *GetTOFHeader() const {return fTOFHeader;}
-
+  const Float_t GetEventTimeSpread() const {if (fTOFHeader) return fTOFHeader->GetT0spread(); else return 0.;}
+  const Float_t GetTOFTimeResolution() const {if (fTOFHeader) return fTOFHeader->GetTOFResolution(); else return 0.;}
 
 
   void SetMultiplicity(const AliMultiplicity *mul);
index 28a6b2b..f8ebca8 100644 (file)
@@ -374,6 +374,9 @@ void AliESDpid::SetTOFResponse(AliESDEvent *event,EStartTimeType_t option){
     AliTOFHeader *tofHeader =(AliTOFHeader*)event->GetTOFHeader();
 
     if(tofHeader){
+      fTOFResponse.SetTimeResolution(tofHeader->GetTOFResolution());
+      t0spread = tofHeader->GetT0spread();
+      if(t0spread < 10) t0spread = 80;
 
       flagT0TOF=kTRUE;
       for(Int_t i=0;i<fTOFResponse.GetNmomBins();i++){