]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - PHOS/AliPHOSReconstructor.h
effc++ warnings
[u/mrichter/AliRoot.git] / PHOS / AliPHOSReconstructor.h
index 51775fc7a567b5330d7a66c5719bb77579547822..28cec7dd9452ce78cb62b41352d89cb6faa6244e 100644 (file)
@@ -8,6 +8,12 @@
 /* History of cvs commits:
  *
  * $Log$
+ * Revision 1.15  2007/10/01 20:24:08  kharlov
+ * Memory leaks fixed
+ *
+ * Revision 1.14  2007/09/26 14:22:18  cvetan
+ * Important changes to the reconstructor classes. Complete elimination of the run-loaders, which are now steered only from AliReconstruction. Removal of the corresponding Reconstruct() and FillESD() methods.
+ *
  * Revision 1.13  2007/08/30 10:40:27  cvetan
  * Minor
  *
 
 //_________________________________________________________________________
 //  Wrapping class for reconstruction
-//*--
-//*-- Author: Yves Schutz (SUBATECH) 
+//--
+//-- Author: Yves Schutz (SUBATECH) 
 // Reconstruction class. Redesigned from the old AliReconstructionner class and 
 // derived from STEER/AliReconstructor. 
 //_________________________________________________________________________
 
 // --- ROOT system ---
 
+#include <Riostream.h>
 #include "AliReconstructor.h" 
+#include "AliPHOSRecoParamEmc.h"
+#include "AliPHOSRecoParamCpv.h"
 class AliPHOSDigitizer ;
 class AliPHOSClusterizer ;
 class AliPHOSTrackSegmentMaker ;
@@ -67,7 +76,8 @@ public:
     // requested by the Coding Convention
     Fatal("cpy ctor", "not implemented") ;
   }
-  ~AliPHOSReconstructor() ; //dtor            
+  virtual ~AliPHOSReconstructor() ; //dtor            
+
   static void                SetDebug()   { fgDebug = kTRUE ; }
   static void                ResetDebug() { fgDebug = kFALSE ; }
   static Bool_t              Debug() { return fgDebug ; }
@@ -90,15 +100,27 @@ public:
   void SetRecoParamEmc(AliPHOSRecoParam * param){ fgkRecoParamEmc = param;}
   void SetRecoParamCpv(AliPHOSRecoParam * param){ fgkRecoParamCpv = param;}
 
-  static const AliPHOSRecoParam* GetRecoParamEmc(){ return fgkRecoParamEmc;}
-  static const AliPHOSRecoParam* GetRecoParamCpv(){ return fgkRecoParamCpv;}
+  static const AliPHOSRecoParam* GetRecoParamEmc(){ 
+    if (!fgkRecoParamEmc) {
+      cerr<<"The Reconstruction parameters for EMC nonitialized - Used default one"<<endl;
+      fgkRecoParamEmc = AliPHOSRecoParamEmc::GetEmcDefaultParameters();
+    }
+    return fgkRecoParamEmc;
+  }
+  static const AliPHOSRecoParam* GetRecoParamCpv(){
+    if (!fgkRecoParamCpv) {
+      cerr<<"The Reconstruction parameters for CPV nonitialized - Used default one"<<endl;
+      fgkRecoParamCpv = AliPHOSRecoParamCpv::GetCpvDefaultParameters();
+    }
+    return fgkRecoParamCpv;
+  }
 
 private:
   
   static Bool_t fgDebug ; //! verbosity controller
-  static AliPHOSRecoParam*   fgkRecoParamEmc; // reconstruction parameters for EMC
-  static AliPHOSRecoParam*   fgkRecoParamCpv; // reconstruction parameters for EMC
-  AliPHOSGeometry*           fGeom;           // pointer to the PHOS geometry
+  static AliPHOSRecoParam *fgkRecoParamEmc; // reconstruction parameters for EMC
+  static AliPHOSRecoParam *fgkRecoParamCpv; // reconstruction parameters for EMC
+  AliPHOSGeometry         *fGeom;           // pointer to the PHOS geometry
 
   ClassDef(AliPHOSReconstructor,4)  // PHOS Reconstruction class