From: hristov Date: Wed, 3 Oct 2007 13:11:07 +0000 (+0000) Subject: Modification for the new ESD event structure X-Git-Url: http://git.uio.no/git/?p=u%2Fmrichter%2FAliRoot.git;a=commitdiff_plain;h=2cb8424d81494137b7487db8101ba7eb3bee77ad Modification for the new ESD event structure --- diff --git a/test/gun/test.C b/test/gun/test.C index e8f1ee7b592..5f5088c8e7e 100644 --- a/test/gun/test.C +++ b/test/gun/test.C @@ -15,7 +15,7 @@ #include // AliRoot include files -#include "AliESD.h" +#include "AliESDEvent.h" #include "AliRunLoader.h" #include "AliRun.h" #include "AliStack.h" @@ -29,15 +29,14 @@ void test(const char * sdir =".") { TString name; - // Signal file, tree, and branch + // Signal file and tree name = sdir; name += "/AliESDs.root"; TFile * fSig = TFile::Open(name.Data()); TTree * tSig = (TTree*)fSig->Get("esdTree"); - TBranch * bSig = tSig->GetBranch("ESD"); - AliESD * esdSig = 0; // The signal ESD object is put here - bSig->SetAddress(&esdSig); + AliESDEvent * esdSig = new AliESDEvent();// The signal ESD object is put here + esdSig->ReadFromTree(tSig); // Run loader (signal events) name = sdir; @@ -64,7 +63,7 @@ void test(const char * sdir =".") { cout << "---------- Signal event ----------" << iev << endl; // Get signal ESD - bSig->GetEntry(iev); + tSig->GetEntry(iev); // Particle stack rlSig->GetEvent(iev);