ATLAS Offline Software
IInputConverter.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef ISF_INTERFACES_IINPUTCONVERTER_H
6 #define ISF_INTERFACES_IINPUTCONVERTER_H 1
7 
8 // Gaudi
9 #include "GaudiKernel/IInterface.h"
10 
11 //GeneratorObjects
13 
14 // StoreGate
15 #include "StoreGate/ReadHandle.h"
16 #include "StoreGate/WriteHandle.h"
17 
18 // Simulation includes
20 
21 // forward declarations
22 class McEventCollection;
23 class G4Event;
25 
26 namespace ISF {
27 
28  class ISFParticle;
29 
39  class IInputConverter : virtual public IInterface {
40  public:
41 
43  virtual ~IInputConverter(){}
44 
47 
50  virtual StatusCode convert(McEventCollection& inputGenEvents,
51  ISFParticleContainer& simParticles) const = 0;
52 
55  virtual StatusCode convertHepMCToG4Event(const EventContext& ctx, McEventCollection& inputGenEvents,
56  G4Event*& outputG4Event, McEventCollection& shadowGenEvents) const = 0;
57 
60  virtual StatusCode convertHepMCToG4EventLegacy(const EventContext& ctx, McEventCollection& inputGenEvents,
61  G4Event*& outputG4Event) const = 0;
62 
64  virtual G4Event* ISF_to_G4Event(const EventContext& ctx, const std::vector<ISF::ISFParticle*>& isp, HepMC::GenEvent *genEvent, HepMC::GenEvent *shadowGenEvent=nullptr, bool useHepMC=false) const = 0;
65 
66  };
67 
68 } // end of ISF namespace
69 
70 #endif // ISF_INTERFACES_IINPUTCONVERTER_H
ISF::ISFParticleContainer
std::list< ISF::ISFParticle * > ISFParticleContainer
generic ISFParticle container (not necessarily a std::list!)
Definition: ISFParticleContainer.h:23
ISF::IInputConverter::ISF_to_G4Event
virtual G4Event * ISF_to_G4Event(const EventContext &ctx, const std::vector< ISF::ISFParticle * > &isp, HepMC::GenEvent *genEvent, HepMC::GenEvent *shadowGenEvent=nullptr, bool useHepMC=false) const =0
Converts vector of ISF::ISFParticles to G4Event.
ISF::IInputConverter
Definition: IInputConverter.h:39
ISF::IInputConverter::convert
virtual StatusCode convert(McEventCollection &inputGenEvents, ISFParticleContainer &simParticles) const =0
Convert selected particles from the given McEventCollection into ISFParticles and push them into the ...
ISF::IInputConverter::convertHepMCToG4EventLegacy
virtual StatusCode convertHepMCToG4EventLegacy(const EventContext &ctx, McEventCollection &inputGenEvents, G4Event *&outputG4Event) const =0
Convert selected particles from the given McEventCollection into G4PrimaryParticles and push them int...
ISFParticleContainer.h
WriteHandle.h
Handle class for recording to StoreGate.
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
GenEvent_fwd.h
McEventCollection
This defines the McEventCollection, which is really just an ObjectVector of McEvent objects.
Definition: McEventCollection.h:33
ISF
ISFParticleOrderedQueue.
Definition: PrimaryParticleInformation.h:13
ISF::IInputConverter::~IInputConverter
virtual ~IInputConverter()
Virtual destructor.
Definition: IInputConverter.h:43
ISF::IInputConverter::convertHepMCToG4Event
virtual StatusCode convertHepMCToG4Event(const EventContext &ctx, McEventCollection &inputGenEvents, G4Event *&outputG4Event, McEventCollection &shadowGenEvents) const =0
Convert selected particles from the given McEventCollection into G4PrimaryParticles and push them int...
ReadHandle.h
Handle class for reading from StoreGate.
ISF::IInputConverter::DeclareInterfaceID
DeclareInterfaceID(ISF::IInputConverter, 1, 0)
Tell Gaudi which InterfaceID we have.