Run number is stored as a file <run#> among the DDL files. AliRawReaderFile looks...
authorcvetan <cvetan@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 30 Jul 2008 09:58:11 +0000 (09:58 +0000)
committercvetan <cvetan@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 30 Jul 2008 09:58:11 +0000 (09:58 +0000)
RAW/AliRawReaderFile.cxx
STEER/AliSimulation.cxx

index 42f72f0..22f29c5 100644 (file)
@@ -166,6 +166,11 @@ Bool_t AliRawReaderFile::CreateFileIndex()
   while (entry = gSystem->GetDirEntry(fDirectory)) {
     const char* filename=entry.Data();
     if (!filename || entry.IsNull()) break;
+    if (entry.BeginsWith("run")) {
+      entry.ReplaceAll("run","");
+      fRunNb = entry.Atoi();
+      continue;
+    }
     if (!entry.EndsWith(".ddl")) continue;
     result=kTRUE;
     entry.Remove(0, entry.Last('_')+1);
index 06e8b8a..5417536 100644 (file)
@@ -1202,6 +1202,9 @@ Bool_t AliSimulation::WriteRawFiles(const char* detectors)
       if (fStopOnError) return kFALSE; else continue;
     }
 
+    ofstream runNbFile(Form("run%u",runLoader->GetHeader()->GetRun()));
+    runNbFile.close();
+
     TString detStr = detectors;
     TObjArray* detArray = runLoader->GetAliRun()->Detectors();
     for (Int_t iDet = 0; iDet < detArray->GetEntriesFast(); iDet++) {