Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-09-11 08:27:31

0001 // Copyright 2022, David Lawrence
0002 // Subject to the terms in the LICENSE file found in the top-level directory.
0003 //
0004 //
0005 
0006 #include <JANA/JApplicationFwd.h>
0007 #include <JANA/JEventSourceGeneratorT.h>
0008 #include <JANA/Services/JParameterManager.h>
0009 #include <string>
0010 
0011 #include "JEventProcessorManagedPODIO.h"
0012 #include "JEventProcessorPODIO.h"
0013 #include "JEventSourceManagedPODIO.h"
0014 #include "JEventSourcePODIO.h"
0015 
0016 // Make this a JANA plugin
0017 extern "C" {
0018 void InitPlugin(JApplication* app) {
0019   InitJANAPlugin(app);
0020 
0021   // Check if managed mode is requested
0022   if (app->GetJParameterManager()->Exists("podio:managed_socket_path")) {
0023     app->Add(new JEventSourceManagedPODIO("", app));
0024     app->Add(new JEventProcessorManagedPODIO());
0025   } else {
0026     app->Add(new JEventSourceGeneratorT<JEventSourcePODIO>());
0027     app->Add(new JEventProcessorPODIO());
0028   }
0029 }
0030 }