]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
One more correction to allow "/" in the file name
authorschutz <schutz@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sat, 23 Feb 2002 00:45:19 +0000 (00:45 +0000)
committerschutz <schutz@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sat, 23 Feb 2002 00:45:19 +0000 (00:45 +0000)
EMCAL/AliEMCALDigitizer.cxx
EMCAL/AliEMCALGetter.cxx
PHOS/AliPHOSDigitizer.cxx
PHOS/AliPHOSGetter.cxx

index 5a6ab74be26c8d3a0723d77fb40b6b5c7e5a92b1..db08245c5de8b98cb748d2e989e3273a0d9c43e8 100644 (file)
@@ -130,11 +130,11 @@ Bool_t AliEMCALDigitizer::Init()
  
 
 
-if(fManager)
+  if(fManager)
     SetTitle("aliroot") ;
   else if (strcmp(GetTitle(),"")==0) 
-   SetTitle("galice.root") ;
-
+    SetTitle("galice.root") ;
+  
   if( strcmp(GetName(), "") == 0 )
     SetName("Default") ;
   
@@ -167,7 +167,7 @@ if(fManager)
 //____________________________________________________________________________ 
 AliEMCALDigitizer::AliEMCALDigitizer(const char *headerFile,const char *name)
 {
-   SetName(name) ;
+  SetName(name) ;
   SetTitle(headerFile) ;
   fManager = 0 ;                     // We work in the standalong mode
   Init() ;
@@ -230,7 +230,6 @@ void AliEMCALDigitizer::Digitize(const Int_t event) {
     cerr << "ERROR: AliEMCALDigitizer::Digitize -> SDigitizer with name " << GetName() << " not found " << endl ; 
     abort() ; 
   }
-
 // loop through the sdigits posted to the White Board and add them to the noise
   TCollection * folderslist = gime->SDigitsFolder()->GetListOfFolders() ; 
   TIter next(folderslist) ; 
@@ -240,8 +239,10 @@ void AliEMCALDigitizer::Digitize(const Int_t event) {
   TObjArray * sdigArray = new TObjArray(2) ;
   while ( (folder = (TFolder*)next()) ) 
     if ( (sdigits = (TClonesArray*)folder->FindObject(GetName()) ) ) {
+      TString fileName(folder->GetName()) ;
+      fileName.ReplaceAll("_","/") ;
       cout << "INFO: AliEMCALDigitizer::Digitize -> Adding SDigits " 
-          << GetName() << " from " << folder->GetName() << endl ; 
+          << GetName() << " from " << fileName << endl ; 
       sdigArray->AddAt(sdigits, input) ;
       input++ ;
     }
@@ -469,8 +470,8 @@ if(strcmp(GetName(), "") == 0 )
        gime->ReadTreeS(treeS,input) ;
       }
     }
-    else
-      gime->Event(ievent,"S") ;
+    else 
+      gime->Event(ievent,"S") ; 
     
     Digitize(ievent) ; //Add prepared SDigits to digits and add the noise
     
index 50b82807f5460d6c232051016ee7372ec6c6c3d4..65d8cdb21a3c5a38ec316baaa832ac5e8023cbe9 100644 (file)
@@ -83,6 +83,8 @@ AliEMCALGetter::AliEMCALGetter(const char* headerFile, const char* branchTitle,
 {
   //Initialize  all lists
 
+  fDebug = 0 ; 
+
   fHeaderFile         = headerFile ; 
   fBranchTitle        = branchTitle ;
   fSDigitsTitle       = branchTitle ; 
@@ -402,6 +404,7 @@ Bool_t AliEMCALGetter::PostSDigitizer(const char * name, const char * file) cons
   TString sdname(name) ;
   sdname.Append(":") ;
   sdname.Append(file);
+  sdname.ReplaceAll("/","_") ; 
   AliEMCALSDigitizer * emcalsd  = dynamic_cast<AliEMCALSDigitizer *>(emcal->GetListOfTasks()->FindObject( sdname )); 
   if (!emcalsd) {
     emcalsd = new AliEMCALSDigitizer() ;  
@@ -1464,7 +1467,7 @@ void AliEMCALGetter::ReadTreeS(Int_t event)
   if ( (subdir != "aliroot") && ( !folderslist->Contains(subdir) ) ){
     emcalF->AddFolder(subdir, ""); 
   }
-    
+
   TIter next(folderslist) ; 
   TFolder * folder = 0 ; 
   TFile * file; 
@@ -1487,7 +1490,7 @@ void AliEMCALGetter::ReadTreeS(Int_t event)
       cerr << "ERROR: AliEMCALGetter::ReadTreeS There is no SDigit Tree" << endl;
       return ;
     }
-    
+   
     //set address of the SDigits and SDigitizer
     TBranch   * sdigitsBranch    = 0;
     TBranch   * sdigitizerBranch = 0;
@@ -1854,8 +1857,8 @@ const TTask * AliEMCALGetter::ReturnT(TString what, TString name) const
   TTask * task = 0 ; 
   while((task = static_cast<TTask *>(it.Next()) )){
     TString taskname(task->GetName()) ;
-    if(taskname.BeginsWith(name))
-      return task ;
+    if(taskname.BeginsWith(name)){
+    return task ;}
   }
   
   if(fDebug)
index 5df861ab932ff4d51e4a37ae3dd2c485d63871ab..275297ec008c4b2650758633e9628682305ff388 100644 (file)
@@ -178,8 +178,10 @@ void AliPHOSDigitizer::Digitize(const Int_t event)
   TObjArray * sdigArray = new TObjArray(2) ;
   while ( (folder = (TFolder*)next()) ) 
     if ( (sdigits = (TClonesArray*)folder->FindObject(GetName()) ) ) {
+      TString fileName(folder->GetName()) ;
+      fileName.ReplaceAll("_","/") ;
       cout << "INFO: AliPHOSDigitizer::Digitize -> Adding SDigits " 
-          << GetName() << " from " << folder->GetName() << endl ; 
+          << GetName() << " from " << fileName << endl ; 
       sdigArray->AddAt(sdigits, input) ;
       input++ ;
     }
index 094d0a30b944df655dae5d318e410b2c26e35174..0ac294deedde29696b4d66738d8f7aac6c0937cd 100644 (file)
@@ -83,6 +83,8 @@ AliPHOSGetter::AliPHOSGetter(const char* headerFile, const char* branchTitle )
 {
   //Initialize  all lists
 
+  fDebug = 0 ; 
+  
   fHeaderFile         = headerFile ; 
   fBranchTitle        = branchTitle ;
   fSDigitsTitle       = branchTitle ; 
@@ -450,6 +452,7 @@ Bool_t AliPHOSGetter::PostSDigitizer(const char * name, const char * file) const
   TString sdname(name) ;
   sdname.Append(":") ;
   sdname.Append(file);
+  sdname.ReplaceAll("/","_") ; 
   AliPHOSSDigitizer * phossd  = dynamic_cast<AliPHOSSDigitizer *>(phos->GetListOfTasks()->FindObject( sdname )); 
   if (!phossd) {
     phossd = new AliPHOSSDigitizer() ;