LCOV - code coverage report
Current view: top level - MUON/MUONrec - AliMUONVQADataMakerRec.cxx (source / functions) Hit Total Coverage
Test: coverage.info Lines: 5 32 15.6 %
Date: 2016-06-14 17:26:59 Functions: 2 14 14.3 %

          Line data    Source code
       1             : /**************************************************************************
       2             : * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
       3             : *                                                                        *
       4             : * Author: The ALICE Off-line Project.                                    *
       5             : * Contributors are mentioned in the code where appropriate.              *
       6             : *                                                                        *
       7             : * Permission to use, copy, modify and distribute this software and its   *
       8             : * documentation strictly for non-commercial purposes is hereby granted   *
       9             : * without fee, provided that the above copyright notice appears in all   *
      10             : * copies and that both the copyright notice and this permission notice   *
      11             : * appear in the supporting documentation. The authors make no claims     *
      12             : * about the suitability of this software for any purpose. It is          *
      13             : * provided "as is" without express or implied warranty.                  *
      14             : **************************************************************************/
      15             : 
      16             : // $Id$
      17             : 
      18             : #include "AliMUONVQADataMakerRec.h"
      19             : 
      20             : ///
      21             : /// \class AliMUONVQADataMakerRec
      22             : /// 
      23             : /// Interface for a MUON QADataMakerRec, common to MCH and MTR
      24             : /// 
      25             : /// \author Laurent Aphecetche
      26             : 
      27             : /// \cond CLASSIMP
      28          18 : ClassImp(AliMUONVQADataMakerRec)
      29             : /// \endcond
      30             : 
      31             : #include "AliMUONRecoParam.h"
      32             : #include "AliCDBManager.h"
      33             : #include "TH1.h"
      34             : 
      35             : //_____________________________________________________________________________
      36           4 : AliMUONVQADataMakerRec::AliMUONVQADataMakerRec(AliQADataMakerRec* master)
      37           4 : : fMaster(master)
      38          12 : {
      39             :   /// ctor
      40           4 : }
      41             : 
      42             : //_____________________________________________________________________________
      43             : AliMUONVQADataMakerRec::~AliMUONVQADataMakerRec()
      44           0 : {
      45             :   /// dtor
      46           0 : }
      47             : 
      48             : //_____________________________________________________________________________
      49             : Int_t 
      50             : AliMUONVQADataMakerRec::Add2DigitsList(TH1 * hist, const Int_t index, const Bool_t expert , const Bool_t image )
      51             : {
      52             :   /// fwd
      53           0 :   return fMaster ? fMaster->Add2DigitsList(hist,index,expert,image) : -1;
      54             : }
      55             : 
      56             : //_____________________________________________________________________________
      57             : Int_t 
      58             : AliMUONVQADataMakerRec::Add2ESDsList(TH1 * hist, const Int_t index, const Bool_t expert , const Bool_t image )
      59             : {
      60             :   /// fwd
      61           0 :   return fMaster ? fMaster->Add2ESDsList(hist,index,expert,image) : -1;
      62             : }
      63             : 
      64             : //_____________________________________________________________________________
      65             : Int_t 
      66             : AliMUONVQADataMakerRec::Add2RecPointsList(TH1 * hist, const Int_t index, const Bool_t expert , const Bool_t image )
      67             : {
      68             :   /// fwd
      69           0 :   return fMaster ? fMaster->Add2RecPointsList(hist,index,expert,image) : -1;
      70             : }
      71             : 
      72             : //_____________________________________________________________________________
      73             : Int_t 
      74             : AliMUONVQADataMakerRec::Add2RawsList(TH1 * hist, const Int_t index, const Bool_t expert , const Bool_t image , const Bool_t saveForCorr )
      75             : {
      76             :   /// fwd
      77           0 :   return fMaster ? fMaster->Add2RawsList(hist,index,expert,image,saveForCorr) : -1;
      78             : }
      79             : 
      80             : //_____________________________________________________________________________
      81             : void AliMUONVQADataMakerRec::ClonePerTrigClass(AliQAv1::TASKINDEX_t task)
      82             : {
      83             :   // RS: alias to QADataMaker per-trigger-class histo clonning
      84           0 :   if (!fMaster) return;
      85           0 :   fMaster->ClonePerTrigClass(task);
      86           0 : }
      87             : 
      88             : 
      89             : //_____________________________________________________________________________
      90             : AliRecoParam::EventSpecie_t 
      91             : AliMUONVQADataMakerRec::CurrentEventSpecie() const
      92             : {
      93             :   /// fwd
      94           0 :   return fMaster ? fMaster->GetEventSpecie() : AliRecoParam::kDefault;
      95             : }
      96             : 
      97             : //_____________________________________________________________________________
      98             : const AliMUONRecoParam* 
      99             : AliMUONVQADataMakerRec::GetRecoParam() const
     100             : {
     101             :   /// fwd
     102           0 :   return fMaster ? dynamic_cast<const AliMUONRecoParam*>(fMaster->GetRecoParam()) : 0x0;
     103             : }
     104             : 
     105             : //_____________________________________________________________________________
     106             : void 
     107             : AliMUONVQADataMakerRec::ResetDetector(const TObjArray* list)
     108             : {
     109             :   /// Reset all histograms found in list, that match either trigger or tracker
     110             :   
     111           0 :   TString cn(ClassName());
     112           0 :   TString pattern;
     113             :   
     114           0 :   if ( cn.Contains("Trigger") ) pattern = "Trigger";
     115           0 :   if ( cn.Contains("Tracker") ) pattern = "Tracker";
     116             :   
     117           0 :   TIter next(list); 
     118             :   TObject* o;
     119           0 :   while ( (o = next()) ) 
     120             :   {
     121             :     // RS: Check if this is a histo or array of histos
     122           0 :     TString hcn(o->GetName());
     123           0 :     if ( !hcn.Contains(pattern) ) continue;
     124           0 :     if ( !o->TestBit(AliQAv1::GetClonedBit()) ) { // not cloned, this is orig. histo
     125           0 :       ((TH1*)o)->Reset();
     126           0 :       continue;
     127             :     }
     128             :     // histo was cloned, so we are dealing with TObjArray
     129           0 :     TIter nextCl( (TObjArray*)o );
     130             :     TH1* hclone = 0;
     131           0 :     while ( (hclone = (TH1*) nextCl()) ) hclone->Reset();
     132           0 :   }
     133           0 : }
     134             : 
     135             : //_____________________________________________________________________________
     136             : Int_t 
     137             : AliMUONVQADataMakerRec::RunNumber() const
     138             : {
     139             :   /// fwd
     140           0 :   return fMaster ? fMaster->GetRun() : -1;
     141             : }

Generated by: LCOV version 1.11