From 8c1f0eac840bc6c8b8bbae405bf9a4b4a5d2b19c Mon Sep 17 00:00:00 2001 From: Markus Frank <markus.frank@cern.ch> Date: Tue, 19 Nov 2013 20:44:16 +0000 Subject: [PATCH] Improved doxygen information --- DDG4/include/DDG4/Geant4EventAction.h | 13 +++++++++++-- DDG4/include/DDG4/Geant4GeneratorAction.h | 16 +++++++++++++++- DDG4/include/DDG4/Geant4RunAction.h | 15 ++++++++++++--- DDG4/include/DDG4/Geant4StackingAction.h | 4 ++++ DDG4/include/DDG4/Geant4SteppingAction.h | 4 ++++ DDG4/include/DDG4/Geant4TrackingAction.h | 20 ++++++++++++-------- DDG4/src/Geant4Kernel.cpp | 4 ++-- 7 files changed, 60 insertions(+), 16 deletions(-) diff --git a/DDG4/include/DDG4/Geant4EventAction.h b/DDG4/include/DDG4/Geant4EventAction.h index 848bc44a0..c379c62b6 100644 --- a/DDG4/include/DDG4/Geant4EventAction.h +++ b/DDG4/include/DDG4/Geant4EventAction.h @@ -27,6 +27,12 @@ namespace DD4hep { /** @class Geant4EventAction Geant4Action.h DDG4/Geant4Action.h * * Concrete basic implementation of the Geant4 event action + * + * The EventAction is called for every event. + * During the callback all particles are created which form the + * microscopic kinematic action of the particle collision. + * This input may either origin directly from an event generator + * program or come from file. * * @author M.Frank * @version 1.0 @@ -37,7 +43,7 @@ namespace DD4hep { Geant4EventAction(Geant4Context* context, const std::string& nam); /// Default destructor virtual ~Geant4EventAction(); - /// begin-of-event callback + /// Begin-of-event callback virtual void begin(const G4Event* event); /// End-of-event callback virtual void end(const G4Event* event); @@ -46,6 +52,9 @@ namespace DD4hep { /** @class Geant4EventActionSequence Geant4Action.h DDG4/Geant4Action.h * * Concrete implementation of the Geant4 event action sequence + * The sequence dispatches the callbacks at the beginning and the and + * of an event to all registered Geant4EventAction members and all + * registered callbacks. * * @author M.Frank * @version 1.0 @@ -75,7 +84,7 @@ namespace DD4hep { } /// Add an actor responding to all callbacks. Sequence takes ownership. void adopt(Geant4EventAction* action); - /// begin-of-event callback + /// Begin-of-event callback virtual void begin(const G4Event* event); /// End-of-event callback virtual void end(const G4Event* event); diff --git a/DDG4/include/DDG4/Geant4GeneratorAction.h b/DDG4/include/DDG4/Geant4GeneratorAction.h index b4ac38287..44b66aac9 100644 --- a/DDG4/include/DDG4/Geant4GeneratorAction.h +++ b/DDG4/include/DDG4/Geant4GeneratorAction.h @@ -28,6 +28,14 @@ namespace DD4hep { * * Concrete implementation of the Geant4 generator action base class * + * The Geant4GeneratorAction is called for every event. + * During the callback all particles are created which form the + * microscopic kinematic action of the particle collision. + * This input may either origin directly from an event generator program + * or come from file. + * + * The callback signature is: void operator()(G4Event* event) + * * @author M.Frank * @version 1.0 */ @@ -48,6 +56,12 @@ namespace DD4hep { * * Concrete implementation of the Geant4 generator action sequence * + * The sequence dispatches the callbacks at the beginning + * of an event to all registered Geant4GeneratorAction members and all + * registered callbacks. + * + * The callback signature is: void operator()(G4Event* event) + * * @author M.Frank * @version 1.0 */ @@ -62,7 +76,7 @@ namespace DD4hep { Geant4GeneratorActionSequence(Geant4Context* context, const std::string& name); /// Default destructor virtual ~Geant4GeneratorActionSequence(); - /// Register begin-of-run callback. Types Q and T must be polymorph! + /// Register primary particle generation callback. Types Q and T must be polymorph! template <typename Q, typename T> void call(Q* p, void (T::*f)(G4Event*)) { m_calls.add(p, f); diff --git a/DDG4/include/DDG4/Geant4RunAction.h b/DDG4/include/DDG4/Geant4RunAction.h index 42b4f0b50..dbf68a355 100644 --- a/DDG4/include/DDG4/Geant4RunAction.h +++ b/DDG4/include/DDG4/Geant4RunAction.h @@ -11,6 +11,7 @@ // Framework include files #include "DDG4/Geant4Action.h" + // Forward declaration class G4Run; @@ -27,6 +28,11 @@ namespace DD4hep { * * Concrete basic implementation of the Geant4 run action * + * The Run Action is called once per start and end of a run. + * i.e. a series of generated events. These two callbacks + * allow clients to define run-dependent actions such as statistics + * summaries etc. + * * @author M.Frank * @version 1.0 */ @@ -36,7 +42,7 @@ namespace DD4hep { Geant4RunAction(Geant4Context* context, const std::string& nam); /// Default destructor virtual ~Geant4RunAction(); - /// begin-of-run callback + /// Begin-of-run callback virtual void begin(const G4Run* run); /// End-of-run callback virtual void end(const G4Run* run); @@ -44,7 +50,10 @@ namespace DD4hep { /** @class Geant4RunActionSequence Geant4RunAction.h DDG4/Geant4RunAction.h * - * Concrete implementation of the Geant4 run action sequence + * Concrete implementation of the Geant4 run action sequence. + * The sequence dispatches the callbacks at the beginning and the and + * of a run to all registered Geant4RunAction members and all + * registered callbacks. * * @author M.Frank * @version 1.0 @@ -74,7 +83,7 @@ namespace DD4hep { } /// Add an actor responding to all callbacks. Sequence takes ownership. void adopt(Geant4RunAction* action); - /// begin-of-run callback + /// Begin-of-run callback virtual void begin(const G4Run* run); /// End-of-run callback virtual void end(const G4Run* run); diff --git a/DDG4/include/DDG4/Geant4StackingAction.h b/DDG4/include/DDG4/Geant4StackingAction.h index 99fb35838..9ee3a1888 100644 --- a/DDG4/include/DDG4/Geant4StackingAction.h +++ b/DDG4/include/DDG4/Geant4StackingAction.h @@ -47,6 +47,10 @@ namespace DD4hep { * * Concrete implementation of the Geant4 stacking action sequence * + * The sequence dispatches the callbacks for each stepping action + * to all registered Geant4StackingAction members and all + * registered callbacks. + * * @author M.Frank * @version 1.0 */ diff --git a/DDG4/include/DDG4/Geant4SteppingAction.h b/DDG4/include/DDG4/Geant4SteppingAction.h index db470c049..2603773be 100644 --- a/DDG4/include/DDG4/Geant4SteppingAction.h +++ b/DDG4/include/DDG4/Geant4SteppingAction.h @@ -47,6 +47,10 @@ namespace DD4hep { * * Concrete implementation of the Geant4 stepping action sequence * + * The sequence dispatches the callbacks for each stepping action + * to all registered Geant4SteppingAction members and all + * registered callbacks. + * * @author M.Frank * @version 1.0 */ diff --git a/DDG4/include/DDG4/Geant4TrackingAction.h b/DDG4/include/DDG4/Geant4TrackingAction.h index 95ccfeb0e..a896a1e63 100644 --- a/DDG4/include/DDG4/Geant4TrackingAction.h +++ b/DDG4/include/DDG4/Geant4TrackingAction.h @@ -53,24 +53,28 @@ namespace DD4hep { /// Mark a single child of the track to be stored bool storeChild(Geant4TrackInformation* info) const; /// Pre-track action callback - virtual void begin(const G4Track* trk); + virtual void begin(const G4Track* track); /// Post-track action callback - virtual void end(const G4Track* trk); + virtual void end(const G4Track* track); }; /** @class Geant4EventActionSequence Geant4Action.h DDG4/Geant4Action.h * * Concrete implementation of the Geant4 tracking action sequence * + * The sequence dispatches the callbacks for each tracking action + * to all registered Geant4SteppingAction members and all + * registered callbacks. + * * @author M.Frank * @version 1.0 */ class Geant4TrackingActionSequence: public Geant4Action { protected: /// Callback sequence for pre tracking action - CallbackSequence m_begin; + CallbackSequence m_begin; /// Callback sequence for post tracking action - CallbackSequence m_end; + CallbackSequence m_end; /// The list of action objects to be called Actors<Geant4TrackingAction> m_actors; public: @@ -88,10 +92,10 @@ namespace DD4hep { } /// Add an actor responding to all callbacks. Sequence takes ownership. void adopt(Geant4TrackingAction* action); - /// Pre-track action callback - virtual void begin(const G4Track* trk); - /// Post-track action callback - virtual void end(const G4Track* trk); + /// Pre-tracking action callback + virtual void begin(const G4Track* track); + /// Post-tracking action callback + virtual void end(const G4Track* track); }; } // End namespace Simulation diff --git a/DDG4/src/Geant4Kernel.cpp b/DDG4/src/Geant4Kernel.cpp index 35fd0fffa..7c9607cd6 100644 --- a/DDG4/src/Geant4Kernel.cpp +++ b/DDG4/src/Geant4Kernel.cpp @@ -72,9 +72,9 @@ Geant4Kernel::Geant4Kernel(LCDD& lcdd) m_context = new Geant4Context(this); m_lcdd.addExtension < Geant4Kernel > (this); - m_controlName = "/properties/"; + m_controlName = "/ddg4/"; m_control = new G4UIdirectory(m_controlName.c_str()); - m_control->SetGuidance("Property control for all Geant4 named actions"); + m_control->SetGuidance("Control for all named Geant4 actions"); InstanceCount::increment(this); } -- GitLab