1 /**************************************************************************
2 * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * Author: The ALICE Off-line Project. *
5 * Contributors are mentioned in the code where appropriate. *
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 **************************************************************************/
19 29.05.2001 Yuri Kharlov:
20 Everywhere reading the treese TTree->GetEvent(i)
21 is replaced by reading the branches TBranch->GetEntry(0)
24 //_________________________________________________________________________
25 // A singleton. This class should be used in the analysis stage to get
26 // reconstructed objects: Digits, RecPoints, TrackSegments and RecParticles,
27 // instead of directly reading them from galice.root file. This container
28 // ensures, that one reads Digits, made of these particular digits, RecPoints,
29 // made of these particular RecPoints, TrackSegments and RecParticles.
30 // This becomes non trivial if there are several identical branches, produced with
31 // different set of parameters.
33 // An example of how to use (see also class AliPHOSAnalyser):
34 // for(Int_t irecp = 0; irecp < gime->NRecParticles() ; irecp++)
35 // AliPHOSRecParticle * part = gime->RecParticle(1) ;
37 // please->GetEvent(event) ; // reads new event from galice.root
39 //*-- Author: Yves Schutz (SUBATECH) & Dmitri Peressounko (RRC KI & SUBATECH)
40 //*-- Completely redesigned by Dmitri Peressounko March 2001
42 //*-- YS June 2001 : renamed the original AliPHOSIndexToObject and make
43 //*-- systematic usage of TFolders without changing the interface
44 //////////////////////////////////////////////////////////////////////////////
47 // --- ROOT system ---
52 #include "TObjString.h"
54 #include "TParticle.h"
56 // --- Standard library ---
57 #include <Riostream.h>
59 // --- AliRoot header files ---
62 #include "AliConfig.h"
63 #include "AliDataLoader.h"
64 #include "AliPHOSLoader.h"
66 #include "AliPHOSDigitizer.h"
67 #include "AliPHOSSDigitizer.h"
68 #include "AliPHOSClusterizer.h"
69 #include "AliPHOSClusterizerv1.h"
70 #include "AliPHOSTrackSegmentMaker.h"
71 #include "AliPHOSTrackSegmentMakerv1.h"
72 #include "AliPHOSTrackSegment.h"
73 #include "AliPHOSPID.h"
74 #include "AliPHOSPIDv1.h"
75 #include "AliPHOSGeometry.h"
76 #include "AliPHOSCalibrationDB.h"
78 ClassImp(AliPHOSLoader)
81 const TString AliPHOSLoader::fgkHitsName("HITS");//Name for TClonesArray with hits from one event
82 const TString AliPHOSLoader::fgkSDigitsName("SDIGITS");//Name for TClonesArray
83 const TString AliPHOSLoader::fgkDigitsName("DIGITS");//Name for TClonesArray
84 const TString AliPHOSLoader::fgkEmcRecPointsName("EMCRECPOINTS");//Name for TClonesArray
85 const TString AliPHOSLoader::fgkCpvRecPointsName("CPVRECPOINTS");//Name for TClonesArray
86 const TString AliPHOSLoader::fgkTracksName("TRACKS");//Name for TClonesArray
87 const TString AliPHOSLoader::fgkRecParticlesName("RECPARTICLES");//Name for TClonesArray
89 const TString AliPHOSLoader::fgkEmcRecPointsBranchName("PHOSEmcRP");//Name for branch with EMC Reconstructed Points
90 const TString AliPHOSLoader::fgkCpvRecPointsBranchName("PHOSCpvRP");//Name for branch with CPV Reconstructed Points
91 const TString AliPHOSLoader::fgkTrackSegmentsBranchName("PHOSTS");//Name for branch with TrackSegments
92 const TString AliPHOSLoader::fgkRecParticlesBranchName("PHOSRP");//Name for branch with Reconstructed Particles
93 //____________________________________________________________________________
94 AliPHOSLoader::AliPHOSLoader()
98 //____________________________________________________________________________
99 AliPHOSLoader::AliPHOSLoader(const Char_t *detname,const Char_t *eventfoldername):
100 AliLoader(detname,eventfoldername)
104 //____________________________________________________________________________
106 AliPHOSLoader::~AliPHOSLoader()
108 //remove and delete arrays
110 Clean(fgkSDigitsName);
111 Clean(fgkDigitsName);
112 Clean(fgkEmcRecPointsName);
113 Clean(fgkCpvRecPointsName);
114 Clean(fgkTracksName);
115 Clean(fgkRecParticlesName);
117 //____________________________________________________________________________
119 void AliPHOSLoader::CleanFolders()
122 AliLoader::CleanFolders();
124 //____________________________________________________________________________
126 Int_t AliPHOSLoader::SetEvent()
128 //Cleans loaded stuff and and sets Files and Directories
129 // do not post any data to folder/tasks
132 Int_t retval = AliLoader::SetEvent();
135 Error("SetEvent","AliLoader::SetEvent returned error");
140 if (Hits()) Hits()->Clear();
141 if (SDigits()) SDigits()->Clear();
142 if (Digits()) Digits()->Clear();
143 if (EmcRecPoints()) EmcRecPoints()->Clear();
144 if (CpvRecPoints()) CpvRecPoints()->Clear();
145 if (TrackSegments()) TrackSegments()->Clear();
146 if (RecParticles()) RecParticles()->Clear();
150 //____________________________________________________________________________
152 Int_t AliPHOSLoader::GetEvent()
154 //Overloads GetEvent method called by AliRunLoader::GetEvent(Int_t) method
155 //to add Rec Particles specific for PHOS
157 //First call the original method to get whatever from std. setup is needed
160 retval = AliLoader::GetEvent();
163 Error("GetEvent","AliLoader::GetEvent returned error");
167 if (GetHitsDataLoader()->GetBaseDataLoader()->IsLoaded()) ReadHits();
168 if (GetSDigitsDataLoader()->GetBaseDataLoader()->IsLoaded()) ReadSDigits();
169 if (GetDigitsDataLoader()->GetBaseDataLoader()->IsLoaded()) ReadDigits();
170 if (GetRecPointsDataLoader()->GetBaseDataLoader()->IsLoaded()) ReadRecPoints();
171 if (GetTracksDataLoader()->GetBaseDataLoader()->IsLoaded()) ReadTracks();
172 if (GetRecParticlesDataLoader()->GetBaseDataLoader()->IsLoaded()) ReadRecParticles();
175 //Now, check if RecPart were loaded
178 //____________________________________________________________________________
181 //____________________________________________________________________________
182 const AliPHOS * AliPHOSLoader::PHOS()
184 // returns the PHOS object
185 AliPHOS * phos = dynamic_cast<AliPHOS*>(GetModulesFolder()->FindObject(fDetectorName));
188 cout << "WARNING: AliPHOSLoader::PHOS -> PHOS module not found in Folders" << endl ;
192 //____________________________________________________________________________
193 const AliPHOSGeometry * AliPHOSLoader::PHOSGeometry()
195 AliPHOSGeometry * rv = 0 ;
197 rv = PHOS()->GetGeometry();
202 //____________________________________________________________________________
203 Int_t AliPHOSLoader::LoadHits(Option_t* opt)
205 //------- Hits ----------------------
206 //Overload (extends) LoadHits implemented in AliLoader
210 //First call the AliLoader's method to send the TreeH to folder
211 res = AliLoader::LoadHits(opt);
215 Error("LoadHits","AliLoader::LoadHits returned error");
219 //read the data from tree in folder and send it to folder
225 //____________________________________________________________________________
226 Int_t AliPHOSLoader::LoadSDigits(Option_t* opt)
227 { //---------- SDigits -------------------------
229 //First call the AliLoader's method to send the TreeS to folder
230 res = AliLoader::LoadSDigits(opt);
233 Error("PostSDigits","AliLoader::LoadSDigits returned error");
236 return ReadSDigits();
239 //____________________________________________________________________________
240 Int_t AliPHOSLoader::LoadDigits(Option_t* opt)
243 //First call the AliLoader's method to send the TreeS to folder
244 res = AliLoader::LoadDigits(opt);
247 Error("LoadDigits","AliLoader::LoadDigits returned error");
252 //____________________________________________________________________________
253 Int_t AliPHOSLoader::LoadRecPoints(Option_t* opt)
254 { // -------------- RecPoints -------------------------------------------
256 //First call the AliLoader's method to send the TreeR to folder
257 res = AliLoader::LoadRecPoints(opt);
260 Error("LoadRecPoints","AliLoader::LoadRecPoints returned error");
264 TFolder * phosFolder = GetDetectorDataFolder();
265 if ( phosFolder == 0x0 )
267 Error("PostDigits","Can not get detector data folder");
270 return ReadRecPoints();
272 //____________________________________________________________________________
274 Int_t AliPHOSLoader::LoadTracks(Option_t* opt)
276 //Loads Tracks: Open File, Reads Tree and posts, Read Data and Posts
277 if (GetDebug()) Info("LoadTracks","opt = %s",opt);
279 res = AliLoader::LoadTracks(opt);
282 Error("LoadTracks","AliLoader::LoadTracks returned error");
288 //____________________________________________________________________________
289 Int_t AliPHOSLoader::LoadRecParticles(Option_t* opt)
290 { // -------------- RecPoints -------------------------------------------
292 //First call the AliLoader's method to send the TreeT to folder
293 res = AliLoader::LoadRecParticles(opt);
296 Error("LoadRecParticles","AliLoader::LoadRecParticles returned error");
299 return ReadRecParticles();
302 //____________________________________________________________________________
304 Int_t AliPHOSLoader::PostHits()
306 Int_t reval = AliLoader::PostHits();
309 Error("PostHits","AliLoader:: returned error");
314 //____________________________________________________________________________
316 Int_t AliPHOSLoader::PostSDigits()
318 Int_t reval = AliLoader::PostSDigits();
321 Error("PostSDigits","AliLoader::PostSDigits returned error");
324 return ReadSDigits();
326 //____________________________________________________________________________
328 Int_t AliPHOSLoader::PostDigits()
330 Int_t reval = AliLoader::PostDigits();
333 Error("PostDigits","AliLoader::PostDigits returned error");
338 //____________________________________________________________________________
340 Int_t AliPHOSLoader::PostRecPoints()
342 Int_t reval = AliLoader::PostRecPoints();
345 Error("PostRecPoints","AliLoader::PostRecPoints returned error");
348 return ReadRecPoints();
351 //____________________________________________________________________________
353 Int_t AliPHOSLoader::PostRecParticles()
355 Int_t reval = AliLoader::PostRecParticles();
358 Error("PostRecParticles","AliLoader::PostRecParticles returned error");
361 return ReadRecParticles();
363 //____________________________________________________________________________
365 Int_t AliPHOSLoader::PostTracks()
367 Int_t reval = AliLoader::PostTracks();
370 Error("PostTracks","AliLoader::PostTracks returned error");
375 //____________________________________________________________________________
379 //____________________________________________________________________________
380 Int_t AliPHOSLoader::ReadHits()
382 // If there is no Clones Array in folder creates it and sends to folder
383 // then tries to read
384 // Reads the first entry of PHOS branch in hit tree TreeH()
385 // Reads data from TreeH and stores it in TClonesArray that sits in DetectorDataFolder
387 TObject** hitref = HitsRef();
394 TClonesArray* hits = dynamic_cast<TClonesArray*>(*hitref);
396 TTree* treeh = TreeH();
400 Error("ReadHits"," Cannot read TreeH from folder");
404 TBranch * hitsbranch = treeh->GetBranch(fDetectorName);
407 Error("ReadHits"," Cannot find branch PHOS");
411 if (GetDebug()) Info("ReadHits","Reading Hits");
413 if (hitsbranch->GetEntries() > 1)
415 TClonesArray * tempo = new TClonesArray("AliPHOSHit",1000);
417 hitsbranch->SetAddress(&tempo);
420 for (i = 0 ; i < hitsbranch->GetEntries(); i++)
422 hitsbranch->GetEntry(i) ;
424 for ( j = 0 ; j < tempo->GetEntries() ; j++)
426 AliPHOSHit* hit = (AliPHOSHit*)tempo->At(j);
427 new((*hits)[index]) AliPHOSHit( *hit ) ;
435 hitsbranch->SetAddress(hitref);
436 hitsbranch->GetEntry(0) ;
441 //____________________________________________________________________________
442 Int_t AliPHOSLoader::ReadSDigits()
444 // Read the summable digits tree TreeS():
445 // Check if TClones is in folder
446 // if not create and add to folder
447 // connect to tree if available
450 TObject** sdref = SDigitsRef();
454 sdref = SDigitsRef();
457 TTree * treeS = TreeS();
460 //May happen if file is truncated or new in LoadSDigits
461 //Error("ReadSDigits","There is no SDigit Tree");
465 TBranch * branch = treeS->GetBranch(fDetectorName);
467 {//easy, maybe just a new tree
468 //Error("ReadSDigits"," Cannot find branch PHOS");
472 branch->SetAddress(SDigitsRef());
477 //____________________________________________________________________________
478 Int_t AliPHOSLoader::ReadDigits()
480 // Read the summable digits tree TreeS():
481 // Check if TClones is in folder
482 // if not create and add to folder
483 // connect to tree if available
486 TObject** dref = DigitsRef();
488 {//if there is not array in folder, create it and put it there
493 TTree * treeD = TreeD();
496 //May happen if file is truncated or new in LoadSDigits
497 //Error("ReadDigits","There is no Digit Tree");
501 TBranch * branch = treeD->GetBranch(fDetectorName);
503 {//easy, maybe just a new tree
504 //Error("ReadDigits"," Cannot find branch ",fDetectorName.Data());
508 branch->SetAddress(dref);//connect branch to buffer sitting in folder
509 branch->GetEntry(0);//get first event
514 //____________________________________________________________________________
516 void AliPHOSLoader::Track(Int_t itrack)
518 // Read the first entry of PHOS branch in hit tree gAlice->TreeH()
523 Error("Track","Can not load hits.");
528 TBranch * hitsbranch = dynamic_cast<TBranch*>(TreeH()->GetListOfBranches()->FindObject("PHOS")) ;
531 cout << "WARNING: AliPHOSLoader::ReadTreeH -> Cannot find branch PHOS" << endl ;
534 if(!Hits()) PostHits();
536 hitsbranch->SetAddress(HitsRef());
537 hitsbranch->GetEntry(itrack);
540 //____________________________________________________________________________
541 void AliPHOSLoader::ReadTreeQA()
543 // Read the digit tree gAlice->TreeQA()
544 // so far only PHOS knows about this Tree
546 if(PHOS()->TreeQA()== 0){
547 cerr << "ERROR: AliPHOSLoader::ReadTreeQA: can not read TreeQA " << endl ;
551 TBranch * qabranch = PHOS()->TreeQA()->GetBranch("PHOS");
554 cout << "WARNING: AliPHOSLoader::ReadTreeQA -> Cannot find QA Alarms for PHOS" << endl ;
558 // if(!Alarms()) PostQA();
560 qabranch->SetAddress(AlarmsRef()) ;
562 qabranch->GetEntry(0) ;
567 //____________________________________________________________________________
568 Int_t AliPHOSLoader::ReadRecPoints()
570 //Creates and posts to folder an array container,
571 //connects branch in tree (if exists), and reads data to array
573 MakeRecPointsArray();
575 TObjArray * cpva = 0x0 ;
576 TObjArray * emca = 0x0 ;
578 TTree * treeR = TreeR();
582 //May happen if file is truncated or new in LoadSDigits
587 TBranch * emcbranch = treeR->GetBranch(fgkEmcRecPointsBranchName);
589 if (emcbranch == 0x0)
591 Error("ReadRecPoints","Can not get branch with EMC Rec. Points named %s",fgkEmcRecPointsBranchName.Data());
596 emcbranch->SetAddress(&emca) ;
597 emcbranch->GetEntry(0) ;
599 TBranch * cpvbranch = treeR->GetBranch(fgkCpvRecPointsBranchName);
600 if (cpvbranch == 0x0)
602 Error("ReadRecPoints","Can not get branch with CPV Rec. Points named %s",fgkCpvRecPointsBranchName.Data());
607 cpvbranch->SetAddress(&cpva);
608 cpvbranch->GetEntry(0) ;
612 Int_t maxemc = emca->GetEntries() ;
613 for ( ii= 0 ; ii < maxemc ; ii++ )
614 EmcRecPoints()->Add(emca->At(ii)) ;
616 Int_t maxcpv = cpva->GetEntries() ;
617 for ( ii= 0 ; ii < maxcpv ; ii++ )
618 CpvRecPoints()->Add(cpva->At(ii)) ;
623 //____________________________________________________________________________
624 Int_t AliPHOSLoader::ReadTracks()
626 //Creates and posts to folder an array container,
627 //connects branch in tree (if exists), and reads data to arry
629 TObject** trkref = TracksRef();
631 {//Create and post array
632 MakeTrackSegmentsArray();
633 trkref = TracksRef();
636 TTree * treeT = TreeT();
639 //May happen if file is truncated or new in LoadSDigits, or the file is in update mode,
640 //but tracking was not performed yet for a current event
641 //Error("ReadTracks","There is no Tree with Tracks");
645 TBranch * branch = treeT->GetBranch(fgkTrackSegmentsBranchName);
647 {//easy, maybe just a new tree
648 Error("ReadTracks"," Cannot find branch named %s",fgkTrackSegmentsBranchName.Data());
652 branch->SetAddress(trkref);//connect branch to buffer sitting in folder
653 branch->GetEntry(0);//get first event
657 //____________________________________________________________________________
659 Int_t AliPHOSLoader::ReadRecParticles()
661 //Reads Reconstructed Particles from file
662 //Creates and posts to folder an array container,
663 //connects branch in tree (if exists), and reads data to arry
665 TObject** recpartref = RecParticlesRef();
667 if ( recpartref == 0x0 )
668 {//Create and post array
669 MakeRecParticlesArray();
670 recpartref = RecParticlesRef();
673 TTree * treeP = TreeP();
676 //May happen if file is truncated or new in LoadSDigits,
677 //or the file is in update mode,
678 //but tracking was not performed yet for a current event
679 // Error("ReadRecParticles","There is no Tree with Tracks and Reconstructed Particles");
683 TBranch * branch = treeP->GetBranch(fgkRecParticlesBranchName);
685 {//easy, maybe just a new tree
686 Error("ReadRecParticles"," Cannot find branch %s",fgkRecParticlesBranchName.Data());
690 branch->SetAddress(recpartref);//connect branch to buffer sitting in folder
691 branch->GetEntry(0);//get first event
697 AliPHOSGeometry* AliPHOSLoader::GetPHOSGeometry()
699 //returns PHOS geometry from gAlice
700 //static Method used by some classes where it is not convienient to pass eventfoldername
703 AliPHOS* phos=dynamic_cast<AliPHOS*>(gAlice->GetDetector("PHOS"));
706 return phos->GetGeometry();
708 /***************************************************************************************/
710 AliPHOSLoader* AliPHOSLoader::GetPHOSLoader(const char* eventfoldername)
712 AliRunLoader* rn = AliRunLoader::GetRunLoader(eventfoldername);
715 cerr<<"Error: <AliPHOSLoader::GetPHOSLoader>: "
716 << "Can not find Run Loader in folder "<<eventfoldername<<endl;
719 return dynamic_cast<AliPHOSLoader*>(rn->GetLoader("PHOSLoader"));
721 /***************************************************************************************/
723 Bool_t AliPHOSLoader::BranchExists(const TString& recName)
725 if (fBranchTitle.IsNull()) return kFALSE;
726 TString dataname, zername ;
728 if(recName == "SDigits")
731 dataname = GetDetectorName();
732 zername = "AliPHOSSDigitizer" ;
735 if(recName == "Digits"){
737 dataname = GetDetectorName();
738 zername = "AliPHOSDigitizer" ;
741 if(recName == "RecPoints"){
743 dataname = fgkEmcRecPointsBranchName;
744 zername = "AliPHOSClusterizer" ;
747 if(recName == "TrackSegments"){
749 dataname = fgkTrackSegmentsBranchName;
750 zername = "AliPHOSTrackSegmentMaker";
753 if(recName == "RecParticles"){
755 dataname = fgkRecParticlesBranchName;
756 zername = "AliPHOSPID";
765 TObjArray * lob = static_cast<TObjArray*>(tree->GetListOfBranches()) ;
767 TBranch * branch = 0 ;
768 TString titleName(fBranchTitle);
771 while ((branch = (static_cast<TBranch*>(next())))) {
772 TString branchName(branch->GetName() ) ;
773 TString branchTitle(branch->GetTitle() ) ;
774 if ( branchName.BeginsWith(dataname) && branchTitle.BeginsWith(fBranchTitle) ){
775 Warning("BranchExists","branch %s with title %s ",dataname.Data(),fBranchTitle.Data());
778 if ( branchName.BeginsWith(zername) && branchTitle.BeginsWith(titleName) ){
779 Warning("BranchExists","branch AliPHOS... with title %s ",branch->GetTitle());
787 void AliPHOSLoader::SetBranchTitle(const TString& btitle)
789 if (btitle.CompareTo(fBranchTitle) == 0) return;
790 fBranchTitle = btitle;
793 //____________________________________________________________________________
795 void AliPHOSLoader::CleanHits()
797 AliLoader::CleanHits();
799 TClonesArray* hits = Hits();
800 if (hits) hits->Clear();
802 //____________________________________________________________________________
804 void AliPHOSLoader::CleanSDigits()
806 AliLoader::CleanSDigits();
807 TClonesArray* sdigits = SDigits();
808 if (sdigits) sdigits->Clear();
811 //____________________________________________________________________________
813 void AliPHOSLoader::CleanDigits()
815 AliLoader::CleanDigits();
816 TClonesArray* digits = Digits();
817 if (digits) digits->Clear();
819 //____________________________________________________________________________
821 void AliPHOSLoader::CleanRecPoints()
823 AliLoader::CleanRecPoints();
824 TObjArray* recpoints = EmcRecPoints();
825 if (recpoints) recpoints->Clear();
826 recpoints = CpvRecPoints();
827 if (recpoints) recpoints->Clear();
829 //____________________________________________________________________________
831 void AliPHOSLoader::CleanTracks()
833 //Cleans Tracks stuff
835 AliLoader::CleanTracks();//tree
837 //and clear the array
838 TClonesArray* tracks = TrackSegments();
839 if (tracks) tracks->Clear();
842 //____________________________________________________________________________
844 void AliPHOSLoader::CleanRecParticles()
847 TClonesArray *recpar = RecParticles();
848 if (recpar) recpar->Clear();
852 //____________________________________________________________________________
854 void AliPHOSLoader::ReadCalibrationDB(const char * database,const char * filename)
857 if(fcdb && (strcmp(database,fcdb->GetTitle())==0))
860 TFile * file = gROOT->GetFile(filename) ;
862 file = TFile::Open(filename);
864 Error ("ReadCalibrationDB", "Cannot open file %s", filename) ;
869 fcdb = dynamic_cast<AliPHOSCalibrationDB *>(file->Get("AliPHOSCalibrationDB")) ;
871 Error ("ReadCalibrationDB", "No database %s in file %s", database, filename) ;
873 //____________________________________________________________________________
875 // AliPHOSSDigitizer* AliPHOSLoader::PHOSSDigitizer()
877 // //return PHOS SDigitizer
878 // return dynamic_cast<AliPHOSSDigitizer*>(SDigitizer()) ;
881 //____________________________________________________________________________
882 void AliPHOSLoader::MakeHitsArray()
885 TClonesArray* hits = new TClonesArray("AliPHOSHit",1000);
886 hits->SetName(fgkHitsName);
887 GetDetectorDataFolder()->Add(hits);
890 //____________________________________________________________________________
891 void AliPHOSLoader::MakeSDigitsArray()
893 if ( SDigits()) return;
894 TClonesArray* sdigits = new TClonesArray("AliPHOSDigit",1);
895 sdigits->SetName(fgkSDigitsName);
896 GetDetectorDataFolder()->Add(sdigits);
899 //____________________________________________________________________________
900 void AliPHOSLoader::MakeDigitsArray()
902 if ( Digits()) return;
903 TClonesArray* digits = new TClonesArray("AliPHOSDigit",1);
904 digits->SetName(fgkDigitsName);
905 GetDetectorDataFolder()->Add(digits);
909 //____________________________________________________________________________
910 void AliPHOSLoader::MakeRecPointsArray()
912 if ( EmcRecPoints() == 0x0)
914 if (GetDebug()>9) Info("MakeRecPointsArray","Making array for EMC");
915 TObjArray* emc = new TObjArray(100) ;
916 emc->SetName(fgkEmcRecPointsName) ;
917 GetDetectorDataFolder()->Add(emc);
920 if ( CpvRecPoints() == 0x0)
922 if (GetDebug()>9) Info("MakeRecPointsArray","Making array for CPV");
923 TObjArray* cpv = new TObjArray(100) ;
924 cpv->SetName(fgkCpvRecPointsName);
925 GetDetectorDataFolder()->Add(cpv);
929 //____________________________________________________________________________
930 void AliPHOSLoader::MakeTrackSegmentsArray()
932 if ( TrackSegments()) return;
933 TClonesArray * ts = new TClonesArray("AliPHOSTrackSegment",100) ;
934 ts->SetName(fgkTracksName);
935 GetDetectorDataFolder()->Add(ts);
939 //____________________________________________________________________________
940 void AliPHOSLoader::MakeRecParticlesArray()
942 if ( RecParticles()) return;
943 TClonesArray * rp = new TClonesArray("AliPHOSRecParticle",100) ;
944 rp->SetName(fgkRecParticlesName);
945 GetDetectorDataFolder()->Add(rp);