]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - HLT/global/physics/AliHLTCaloHistoMatchedTracks.h
-Created new base class for the Calo physics histogram producers.
[u/mrichter/AliRoot.git] / HLT / global / physics / AliHLTCaloHistoMatchedTracks.h
index 54ae4c2feb9777c92316efb651f944388cc9b80b..1321598b3f19e2ae848a937a386c012e94001e8b 100644 (file)
 // or
 // visit http://web.ift.uib.no/~kjeks/doc/alice-hlt
 
-//#include "AliHLTPHOSBase.h"
 
 #include "Rtypes.h"
-// #include "TClonesArray.h"
-
+#include "AliHLTCaloHistoProducer.h"
 
 class TRefArray;
 class TObjArray;
 class TH1F;
-class AliHLTCaloClusterReader;
-class AliESDEvent;
-class TString;
-struct AliHLTCaloClusterHeaderStruct;
 
 
 /** 
@@ -51,25 +45,13 @@ struct AliHLTCaloClusterHeaderStruct;
  * Class produces physics histograms for PHOS. It takes a TClonesArray
  * of AliESDCalocluster as input and fills several histograms
  *
- * Histograms (1D):
- * - Total number of clusters per event
- * - Energy distribution of clusters
- * - Total energy in event
- * - Invariant mass of two clusters
- * - Number of cells in clusters
- * - Fraction of cells with energy deposit
- * 
- * Histograms (2D):
- * - Number of cells in cluster vs cluster energy
- * - Number of clusters vs total energy
- *
  * @ingroup alihlt_phos
  */
 
 
 
 //class AliHLTCaloHistoMatchedTracks : public AliHLTPHOSBase
-class AliHLTCaloHistoMatchedTracks {
+class AliHLTCaloHistoMatchedTracks : public AliHLTCaloHistoProducer {
 
  public:
 
@@ -79,18 +61,13 @@ class AliHLTCaloHistoMatchedTracks {
   /** Destructor */
   virtual ~AliHLTCaloHistoMatchedTracks();
 
-
-  /** Analyse the clusters in the event */
- //   int DoEvent(AliHLTCaloClusterHeaderStruct* cHeader);
-//   int DoEvent(AliESDEvent * event);
-
   /** Loop over cluster data and fill histograms */
-  int FillHistograms(Int_t nc, TRefArray * fClustersArray);
-  
-  /** Get a pointer to the TObjArray of histograms */
-  TObjArray * GetHistograms();
+  Int_t FillHistograms(Int_t nc, TRefArray * clusterArray);
+  Int_t FillHistograms(Int_t nc, vector<AliHLTCaloClusterDataStruct*> &cVec);
 
-  
+  /** Do the actual histogram filling, regardless of clustertype */
+  template <class T>
+  Int_t FillMatchedTracks(T*);
   
  private:
   
@@ -103,23 +80,14 @@ class AliHLTCaloHistoMatchedTracks {
   /** Assignment operator */
   AliHLTCaloHistoMatchedTracks & operator= (const AliHLTCaloHistoMatchedTracks);
 
-  /** Cluster reader class   */
-  AliHLTCaloClusterReader * fClusterReader;
-
-  /** Pointer to the array of histograms */
-  TObjArray *fHistArrayPtr;                 //!transient
-
   /** Histogram of the 2 cluster invariant mass */
   TH1F *fHistMatchDistance;                  //!transient
   
   /** Histograms of the energy distribution of mached and unmatched clusters */
   TH1F *fHistMatchedEnergy;                 //!transient
   TH1F *fHistUnMatchedEnergy;               //!transient
-  
-  
-  
 
-  ClassDef(AliHLTCaloHistoMatchedTracks, 1);
+  ClassDef(AliHLTCaloHistoMatchedTracks, 0);
 
 };