G4ErrorRunManagerHelper.hh

Go to the documentation of this file.
00001 //
00002 // ********************************************************************
00003 // * License and Disclaimer                                           *
00004 // *                                                                  *
00005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
00006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
00007 // * conditions of the Geant4 Software License,  included in the file *
00008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
00009 // * include a list of copyright holders.                             *
00010 // *                                                                  *
00011 // * Neither the authors of this software system, nor their employing *
00012 // * institutes,nor the agencies providing financial support for this *
00013 // * work  make  any representation or  warranty, express or implied, *
00014 // * regarding  this  software system or assume any liability for its *
00015 // * use.  Please see the license in the file  LICENSE  and URL above *
00016 // * for the full disclaimer and the limitation of liability.         *
00017 // *                                                                  *
00018 // * This  code  implementation is the result of  the  scientific and *
00019 // * technical work of the GEANT4 collaboration.                      *
00020 // * By using,  copying,  modifying or  distributing the software (or *
00021 // * any work based  on the software)  you  agree  to acknowledge its *
00022 // * use  in  resulting  scientific  publications,  and indicate your *
00023 // * acceptance of all terms of the Geant4 Software license.          *
00024 // ********************************************************************
00025 //
00026 //
00027 // $Id: G4ErrorRunManagerHelper.hh 69766 2013-05-14 14:33:55Z gcosmo $
00028 //
00029 //
00030 // Class Description:
00031 //
00032 // This class helps G4ErrorPropagatorManager with the initialization of 
00033 // geometry and physics, definition of actions and run termination
00034 // (things done by G4RunManager in an standard GEANT4 run)
00035 // It holds a pointer to G4RunManagerKernel
00036 
00037 // History:
00038 // - Created:  Pedro Arce, January 2005
00039 // --------------------------------------------------------------------
00040 
00041 #ifndef G4ErrorRunManagerHelper_hh
00042 #define G4ErrorRunManagerHelper_hh
00043 
00044 class G4RunManagerKernel;
00045 class G4VUserDetectorConstruction;
00046 class G4VPhysicalVolume;
00047 class G4VUserPhysicsList;
00048 class G4UserTrackingAction;
00049 class G4UserSteppingAction;
00050 
00051 class G4ErrorRunManagerHelper 
00052 {
00053 
00054  public:  // with description
00055 
00056   G4ErrorRunManagerHelper();
00057   virtual ~G4ErrorRunManagerHelper();
00058 
00059   static G4ErrorRunManagerHelper* GetRunManagerKernel();
00060     // Static method which returns the singleton pointer of
00061     // G4ErrorRunManagerHelper 
00062 
00063   void SetUserInitialization(G4VUserDetectorConstruction* userInit);
00064     // Initialize geometry by passing a G4VUserDetectorConstruction
00065   void SetUserInitialization(G4VPhysicalVolume* userInit);
00066     // Initialize geometry by passing a G4VPhysicalVolume
00067 
00068   void SetUserInitialization(G4VUserPhysicsList* userInit);
00069     // Initializes physics
00070 
00071   void SetUserAction(G4UserTrackingAction* userAction);
00072     // Set the user tracking action
00073   void SetUserAction(G4UserSteppingAction* userAction);
00074     // Set the user stepping action
00075 
00076   void RunInitialization();
00077     // Invokes G4RunManagerKernel RunInitialization();
00078 
00079   void InitializeGeometry();
00080     // Initializes GEANT4 geometry
00081   void InitializePhysics();
00082     // Initializes GEANT4 physics
00083 
00084   void RunTermination();
00085     // Invokes G4RunManagerKernel RunTermination();
00086 
00087   G4VUserPhysicsList* GetUserPhysicsList() const
00088     { return theUserPhysicsList; }
00089 
00090  private:
00091 
00092   static G4ErrorRunManagerHelper* fRunManagerKernel;
00093   
00094   G4VUserPhysicsList* theUserPhysicsList;
00095   G4VPhysicalVolume* theUserWorld;
00096 
00097   G4RunManagerKernel* theG4RunManagerKernel;
00098 };
00099 
00100 #endif

Generated on Mon May 27 17:48:11 2013 for Geant4 by  doxygen 1.4.7