]> git.uio.no Git - u/mrichter/AliRoot.git/blame - PWGLF/FORWARD/analysis2/AliCentraldNdetaTask.cxx
remove buggy histos
[u/mrichter/AliRoot.git] / PWGLF / FORWARD / analysis2 / AliCentraldNdetaTask.cxx
CommitLineData
ec82df5b 1//====================================================================
2#include "AliCentraldNdetaTask.h"
3#include <TMath.h>
4#include <TH2D.h>
5#include <TH1D.h>
6#include <THStack.h>
7#include <TList.h>
8#include <AliAnalysisManager.h>
9#include <AliAODEvent.h>
10#include <AliAODHandler.h>
11#include <AliAODInputHandler.h>
12#include "AliForwardUtil.h"
13#include "AliAODForwardMult.h"
3e478dba 14#include "AliAODCentralMult.h"
ec82df5b 15
52cc64b7 16ClassImp(AliCentraldNdetaTask)
ffca499d 17#ifdef DOXY_INPUT
18;
19#endif
20
21//____________________________________________________________________
22AliCentraldNdetaTask::AliCentraldNdetaTask(const char*)
23 : AliBasedNdetaTask("Central")
24{
f53fb4f6 25 DGUARD(fDebug,0,"Named construction of AliCentraldNdetaTask");
ffca499d 26 fSymmetrice = false;
27 fCorrEmpty = false;
4bcdcbc1 28 SetTitle("Central");
ffca499d 29}
ec82df5b 30
31//____________________________________________________________________
32TH2D*
fb3430ac 33AliCentraldNdetaTask::GetHistogram(const AliAODEvent* aod, Bool_t mc)
ec82df5b 34{
ec82df5b 35 // Get objects from the event structure
f53fb4f6 36 DGUARD(fDebug,2,"Get our histogram for AliCentraldNdetaTask");
fe52e455 37 TObject* obj = 0;
38 if (mc) obj = aod->FindListObject("CentralClustersMC");
39 else obj = aod->FindListObject("CentralClusters");
ec82df5b 40
41 // We should have a central object at least
fe52e455 42 if (!obj) {
43 if (!mc) AliWarning("No Central object found AOD");
44 return 0;
ec82df5b 45 }
46
47 // Cast to good types
fe52e455 48 AliAODCentralMult* central = static_cast<AliAODCentralMult*>(obj);
ec82df5b 49
fe52e455 50 return &(central->GetHistogram());
ec82df5b 51}
52
fe52e455 53//
54// EOF
55//