Import Geant4 10.7.0.beta source tree
This commit is contained in:
@@ -23,34 +23,29 @@
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
// G4MultiTrackingAction
|
||||
//
|
||||
// Class description:
|
||||
//
|
||||
//---------------------------------------------------------------
|
||||
// This class extends G4UserTrackingAction and allows multiple user-defined
|
||||
// tracking actions to be used in the same job.
|
||||
// The class is a vector of user-defined tracking actions; it owns and manages
|
||||
// the dependent user-actions.
|
||||
//
|
||||
// G4MultiTrackingAction.hh
|
||||
//
|
||||
// Created on: Jan 17, 2016
|
||||
// Author: adotti
|
||||
//
|
||||
//
|
||||
// class description:
|
||||
// This class extends G4UserTrackingAction and allows multiple
|
||||
// user-defined tracking actions to be used in the same job.
|
||||
// The class is a vector of user-defined tracking actions.
|
||||
// This class owns and manages the dependent user-actions.
|
||||
// Usage:
|
||||
// There is no need to explicitly use this class as long as the
|
||||
// user actions are set via G4UserActionInitialization::SetUserAction
|
||||
// that can be called several times. Explicitly this is what is happening:
|
||||
// In user-defined action initialization:
|
||||
// G4MultiTrackingAction* action = new G4MultiTrackingAction;
|
||||
// action->push_back( G4UserTrackingActionUPtr( new MyUserTrackingAction );
|
||||
// [... add as many as needed ...]
|
||||
// SetUserAction( action );
|
||||
// ---------------------------------------------------------------
|
||||
// There is no need to explicitly use this class as long as the user actions
|
||||
// are set via G4UserActionInitialization::SetUserAction(), that can be
|
||||
// called several times. Explicitly this is what happens:
|
||||
// In user-defined action initialization:
|
||||
// G4MultiTrackingAction* action = new G4MultiTrackingAction;
|
||||
// action->push_back( G4UserTrackingActionUPtr( new MyUserTrackingAction );
|
||||
// [... add as many as needed ...]
|
||||
// SetUserAction( action );
|
||||
|
||||
#ifndef G4MULTITRACKINGACTION_HH_
|
||||
#define G4MULTITRACKINGACTION_HH_
|
||||
// Author: Andrea Dotti, SLAC - 17 January 2016
|
||||
// --------------------------------------------------------------------
|
||||
#ifndef G4MULTITRACKINGACTION_HH
|
||||
#define G4MULTITRACKINGACTION_HH
|
||||
|
||||
#include "G4UserTrackingAction.hh"
|
||||
#include <vector>
|
||||
@@ -59,14 +54,16 @@
|
||||
using G4UserTrackingActionUPtr=std::unique_ptr<G4UserTrackingAction>;
|
||||
using G4UserTrackingActionVector=std::vector<G4UserTrackingActionUPtr>;
|
||||
|
||||
class G4MultiTrackingAction : public G4UserTrackingAction , public G4UserTrackingActionVector
|
||||
class G4MultiTrackingAction : public G4UserTrackingAction,
|
||||
public G4UserTrackingActionVector
|
||||
{
|
||||
public:
|
||||
G4MultiTrackingAction() = default;
|
||||
virtual ~G4MultiTrackingAction() override = default;
|
||||
virtual void SetTrackingManagerPointer(G4TrackingManager* pValue) override;
|
||||
virtual void PreUserTrackingAction(const G4Track*) override;
|
||||
virtual void PostUserTrackingAction(const G4Track*) override;
|
||||
public:
|
||||
|
||||
G4MultiTrackingAction() = default;
|
||||
virtual ~G4MultiTrackingAction() override = default;
|
||||
virtual void SetTrackingManagerPointer(G4TrackingManager* pVal) override;
|
||||
virtual void PreUserTrackingAction(const G4Track*) override;
|
||||
virtual void PostUserTrackingAction(const G4Track*) override;
|
||||
};
|
||||
|
||||
#endif /* G4MULTITRACKINGACTION_HH_ */
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user