ATLAS Offline Software
Loading...
Searching...
No Matches
G4GeometryNotifierSvc.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef G4ATLASSERVICES_G4GEOMETRYNOTIFIERSVC_H
6#define G4ATLASSERVICES_G4GEOMETRYNOTIFIERSVC_H
7
8// Base classes
11
12class G4VNotifier;
13
14class G4GeometryNotifierSvc : public extends<AthService, IG4GeometryNotifierSvc> {
15public:
16 // Standard constructor and destructor
17 G4GeometryNotifierSvc( const std::string& name, ISvcLocator* pSvcLocator );
18 virtual ~G4GeometryNotifierSvc();
19
20 // Gaudi methods
21 StatusCode initialize() override final;
22 StatusCode finalize() override final;
23
24 //FIXME This is a bit nasty as it is not thread-safe, but we assume
25 //that the geometry building will be done in a single thread.
26 void SetCurrentDetectorName(const std::string& s) override final {m_currentDetectorName=s;}
27 const std::string GetCurrentDetectorName() const override final {return m_currentDetectorName;}
28
29private:
30 std::string m_currentDetectorName{""};
31
32 Gaudi::Property<bool> m_activateLVNotifier{this, "ActivateLVNotifier", true, "Toggle on/off the G4 LV notifier"};
33 Gaudi::Property<bool> m_activatePVNotifier{this, "ActivatePVNotifier", false, "Toggle on/off the G4 PV notifier"};
34 G4VNotifier* lvNotifier{};
35 G4VNotifier* pvNotifier{};
36};
37
38#endif //G4ATLASSERVICES_G4GEOMETRYNOTIFIERSVC_H
G4GeometryNotifierSvc(const std::string &name, ISvcLocator *pSvcLocator)
const std::string GetCurrentDetectorName() const override final
void SetCurrentDetectorName(const std::string &s) override final
StatusCode initialize() override final
Gaudi::Property< bool > m_activatePVNotifier
StatusCode finalize() override final
Gaudi::Property< bool > m_activateLVNotifier