#include "TArrayS.h"
class TDirectory;
class AliFMDRawReader;
+class TH2;
class AliFMDBaseDA: public TNamed
{
* @param save If true, will output diagnostics file
*/
void SetSaveDiagnostics(Bool_t save) {fSaveHistograms = save;}
+ /**
+ * Set whether to make summary histograms to be published to AMORE
+ *
+ * @param save If true, will generate summary QA histograms
+ */
+ void SetMakeSummaries(Bool_t save) {fMakeSummaries = save;}
/**
* Set the number of requried events
*
* @return number of required events
*/
Int_t GetRequiredEvents() const {return fRequiredEvents ;}
+ /**
+ * Get list of summary histograms
+ *
+ * @return Array of summary histograms or null if not defined
+ */
+ const TObjArray& GetSummaries() const { return fSummaries; }
+ /**
+ * Check if we saw data for detector
+ *
+ * @param det Detector number to check
+ * @return true if the code has seen data from the detector
+ */
+ bool HasSeenDetector(UShort_t d) { return (d == 0 || d > 3) ? false : fSeenDetectors[d-1]; }
protected:
/**
* Initialize
* Analyse a single strip result
*
*/
- virtual void Analyse(UShort_t, Char_t, UShort_t, UShort_t ) {};
+ virtual void Analyse(UShort_t, Char_t, UShort_t, UShort_t) {};
/**
* Write header to output file
*
std::ofstream fOutputFile; // output file
std::ofstream fConditionsFile; // conditions file
Bool_t fSaveHistograms; // save hists or not
+ Bool_t fMakeSummaries; // save hists or not
TObjArray fDetectorArray; // array indiced by detector
/**
* Ge the half-ring index
Int_t fCurrentEvent; // the current event
protected:
UInt_t fRunno; // Current run number
-
+ /**
+ * Utility function for defining summary histograms
+ *
+ * @param det Detector
+ * @param ring Ring identifier
+ * @param prefix Histogram prefix
+ * @param title Histogram title
+ */
+ TH2* MakeSummaryHistogram(const char* prefix, const char* title,
+ UShort_t det, Char_t ring);
+ virtual void MakeSummary(UShort_t, Char_t) { }
+ TObjArray fSummaries;
ClassDef(AliFMDBaseDA,0) // Base Detector algorithm for all run types