]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - TRD/qaRec/AliTRDrecoTask.cxx
Transfer of the initialisation of the QA Data objects in the framework; clean the...
[u/mrichter/AliRoot.git] / TRD / qaRec / AliTRDrecoTask.cxx
index ffc1920da53400e3be3f2dac1bb88e0cc5a8e4a8..f9144b3b0677f9cf2f158d55fbf8f59387b2de06 100644 (file)
@@ -16,7 +16,7 @@
 #include "AliTRDrecoTask.h"
 
 ClassImp(AliTRDrecoTask)
-
+FILE* AliTRDrecoTask::fgFile = 0x0;
 //_______________________________________________________
 AliTRDrecoTask::AliTRDrecoTask(const char *name, const char *title)
   : AliAnalysisTask(name, title)
@@ -54,6 +54,12 @@ AliTRDrecoTask::~AliTRDrecoTask()
     delete fContainer;
     fContainer = 0x0;
   }
+
+  if(fgFile){
+    fflush(fgFile);
+    fclose(fgFile);
+    fgFile = 0x0;
+  }
 }
 
 //_______________________________________________________
@@ -100,6 +106,16 @@ Bool_t AliTRDrecoTask::GetRefFigure(Int_t /*ifig*/)
   return kFALSE;
 }
 
+//_______________________________________________________
+Bool_t AliTRDrecoTask::PutTrendValue(Char_t *name, Double_t val, Double_t err)
+{
+  if(!fgFile){
+    fgFile = fopen("TRD.Performance.txt", "at");
+  }
+  fprintf(fgFile, "%s_%s %f %f\n", GetName(), name, val, err);
+  return kTRUE;
+}
+
 //_______________________________________________________
 void AliTRDrecoTask::InitFunctorList()
 {