{{{ // Declaration of variables ExRootConfReader *confReader; ExRootAnalysis *modularDelphes; ExRootFactory *factory; TObjArray *outputArray; try { // Initialization confReader = new ExRootConfReader; confReader->ReadFile("delphes_card.tcl"); modularDelphes = new ExRootAnalysis("Delphes"); modularDelphes->SetConfReader(confReader); modularDelphes->SetTreeWriter(treeWriter); factory = modularDelphes->GetFactory(); outputArray = modularDelphes->NewArray("candidates"); modularDelphes->InitTask(); // Event loop while(ReadEvent()) { modularDelphes->Clear(); ConvertEvent(); modularDelphes->ProcessTask(); } // Finalisation modularDelphes->FinishTask(); delete modularDelphes; delete confReader; } catch(runtime_error &e) { if(outputFile) delete outputFile; cerr << "** ERROR: " << e.what() << endl; return 1; } }}}