Bayeux  3.4.1
Core Foundation library for SuperNEMO
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | List of all members
mctools::g4::manager Class Reference

The Geant4 simulation manager. More...

#include <bayeux/mctools/g4/manager.h>

Inheritance diagram for mctools::g4::manager:
mctools::g4::loggable_support

Public Types

typedef datatools::computing_time CT_type
 
typedef std::map< std::string, CT_typeCT_map
 

Public Member Functions

 manager ()
 Default constructor: More...
 
virtual ~manager ()
 Destructor. More...
 
void initialize (const datatools::multi_properties &mp_)
 Initialize the Geant4 manager. More...
 
void reset ()
 Reset the Geant4 manager. More...
 
void run_simulation ()
 Run the simulation session. More...
 
bool is_initialized () const
 Return true if the simulation is fully initialized. More...
 
bool is_automatic () const
 Return true if simulation will run in batch mode sans macro file. More...
 
bool has_service_manager () const
 Check is an external service manager plugged. More...
 
datatools::service_managergrab_service_manager ()
 Return a mutable service manager reference. More...
 
const datatools::service_managerget_service_manager () const
 Return a non-mutable service manager reference. More...
 
void set_service_manager (datatools::service_manager &sm)
 Plug an external service manager. More...
 
bool has_external_geom_manager () const
 Check if an external service manager is plugged. More...
 
void set_external_geom_manager (const geomtools::manager &gm)
 Plug an external geometry manager. More...
 
const geomtools::managerget_geom_manager () const
 Get a non-mutable reference to the geometry manager. More...
 
void set_event_generator_name (const std::string &)
 Set the name of the active event generator. More...
 
void set_event_generator_seed (int)
 Set the seed for the event generator's PRNG. More...
 
const genbb::managerget_eg_manager () const
 Get a non-mutable reference to the embedded event generator. More...
 
genbb::managergrab_eg_manager ()
 Get a mutable reference to the embedded event generator. More...
 
bool has_event_generator () const
 Check if an event generator is available. More...
 
const genbb::i_genbbget_event_generator () const
 Return a non-mutable reference to a embedded event generator. More...
 
void set_vertex_generator_name (const std::string &)
 Set the name of the active vertex generator. More...
 
void set_vertex_generator_seed (int)
 Set the seed for the vertex generator's PRNG. More...
 
const genvtx::managerget_vg_manager () const
 Get a non-mutable reference to the vertex generator manager. More...
 
genvtx::managergrab_vg_manager ()
 Get a mutable reference to the vertex generator manager. More...
 
bool has_vertex_generator () const
 Check if a vertex generator is available. More...
 
const genvtx::i_vertex_generatorget_vertex_generator () const
 Return a non-mutable reference to a embedded vertex generator. More...
 
event_action & grab_user_event_action ()
 Return a mutable event_action reference. More...
 
uint32_t get_number_of_events () const
 Return the number of events to be generated. More...
 
void set_number_of_events (uint32_t)
 Set the number of events to be generated. More...
 
bool has_number_of_events_modulo () const
 Check if a modulo on number of events is defined. More...
 
int get_number_of_events_modulo () const
 Return the number of events modulo. More...
 
void set_number_of_events_modulo (int)
 Set the number of events modulo. More...
 
void set_use_run_header_footer (bool a_use_run_header_footer)
 
bool using_run_header_footer () const
 
bool is_batch () const
 Return true if the simulation will run in batch mode. More...
 
bool is_interactive () const
 Return true if the simulation is interactive via a CLI/GUI. More...
 
void set_interactive (bool)
 Set the simulation to be interactive. More...
 
void set_g4_visualization (bool)
 Set the Geant4 visualization flag. More...
 
bool has_g4_visualization () const
 Check the Geant4 visualization flag. More...
 
bool has_g4_macro () const
 Check if the manager has a Geant4 macro. More...
 
const std::string & get_g4_macro () const
 Return the filename of the Geant4 macro. More...
 
void set_g4_macro (const std::string &macroFile)
 Set the Geant4 macro. More...
 
void set_use_track_history (const bool)
 (De)Activate the track history object More...
 
bool has_track_history () const
 Check if a track history object is available. More...
 
const track_historyget_track_history () const
 Get a non-mutable reference to the track history object. More...
 
track_historygrab_track_history ()
 Get a mutable reference to the track history object. More...
 
bool forbids_private_hits () const
 
void set_forbid_private_hits (bool a_forbid)
 
void set_dont_save_no_sensitive_hit_events (bool a_dont_save)
 
bool dont_save_no_sensitive_hit_events () const
 
bool has_simulation_ctrl () const
 Check if an external thread simulation control is plugged. More...
 
void set_simulation_ctrl (simulation_ctrl &a_simulation_ctrl)
 Plug an external thread simulation control. More...
 
void reset_simulation_ctrl ()
 Unplug an external thread simulation control. More...
 
const simulation_ctrl & get_simulation_ctrl () const
 Return a non-mutable thread simulation control reference. More...
 
simulation_ctrl & grab_simulation_ctrl ()
 Return a mutable thread simulation control reference. More...
 
mygsl::rnggrab_vg_prng ()
 Return a mutable reference to the vertex generator's PRNG. More...
 
mygsl::rnggrab_eg_prng ()
 Return a mutable reference to the event generator's PRNG. More...
 
mygsl::rnggrab_shpf_prng ()
 Return a mutable reference to the Step Hit Processor Factory's PRNG. More...
 
const mygsl::rngget_mgr_prng () const
 Return a non mutable reference to the Geant4 engine's PRNG. More...
 
mygsl::rnggrab_mgr_prng ()
 Return a mutable reference to the Geant4 engine's PRNG. More...
 
const g4_prngget_g4_prng () const
 Return a non mutable reference to the Geant4 engine's PRNG. More...
 
g4_prnggrab_g4_prng ()
 Return a mutable reference to the Geant4 engine's PRNG. More...
 
const mygsl::seed_managerget_seed_manager () const
 Return a non mutable reference to the manager of PRNG's seeds. More...
 
mygsl::seed_managergrab_seed_manager ()
 Return a mutable reference to the manager of PRNG's seeds. More...
 
const mygsl::prng_state_managerget_state_manager () const
 Return a non mutable reference to the manager of PRNG's states. More...
 
mygsl::prng_state_managergrab_state_manager ()
 Return a mutable reference to the manager of PRNG's states. More...
 
void record_current_prng_states ()
 Record the current states of all PRNGs. More...
 
void set_prng_state_save_modulo (int a_modulo)
 
int get_prng_state_save_modulo () const
 
bool has_prng_state_save_modulo () const
 
bool has_input_prng_seeds_file () const
 
void reset_input_prng_seeds_file ()
 
void set_input_prng_seeds_file (const std::string &)
 
const std::string & get_input_prng_seeds_file () const
 
bool has_output_prng_seeds_file () const
 
void reset_output_prng_seeds_file ()
 
void set_output_prng_seeds_file (const std::string &)
 
const std::string & get_output_prng_seeds_file () const
 
void reset_output_prng_states_file ()
 
bool has_output_prng_states_file () const
 
void set_output_prng_states_file (const std::string &)
 
const std::string & get_output_prng_states_file () const
 
void reset_input_prng_states_file ()
 
bool has_input_prng_states_file () const
 
void set_input_prng_states_file (const std::string &)
 
const std::string & get_input_prng_states_file () const
 
bool has_mgr_prng_seed () const
 Check the seed of the G4 simulation engine. More...
 
int get_mgr_prng_seed () const
 Get the seed of the G4 simulation engine. More...
 
void set_mgr_prng_seed (int seed)
 Set the seed of the G4 simulation engine. More...
 
void set_shpf_prng_seed (int)
 Set the seed for the Step Hit Processor Factory's PRNG. More...
 
bool has_init_seed_method () const
 Check if the method for seed initialization is set. More...
 
void set_init_seed_method (const std::string &)
 Set the method used to set the initialization seed for the generation of seeds. More...
 
const std::string & get_init_seed_method () const
 Return the method for seed initialization. More...
 
void set_output_data_format_by_label (const std::string &)
 Set the output data file format. More...
 
void reset_output_data_format ()
 Reset the output data file format. More...
 
void set_output_data_format (io_utils::data_format_type)
 Set the output data file format. More...
 
void set_output_data_bank_label (const std::string &)
 Set the output data bank label(for "bank" output format only) More...
 
io_utils::data_format_type get_output_data_format () const
 Return the output data file format. More...
 
void set_output_data_file (const std::string &)
 Set the output data file name. More...
 
bool using_time_stat () const
 
void set_using_time_stat (bool)
 
const CT_mapget_CT_map () const
 
CT_mapgrab_CT_map ()
 
bool has_supported_output_profile (const std::string &profile_id_) const
 Check if some output profile is officially supported by the manager. More...
 
void add_supported_output_profile (const std::string &profile_id_, const std::string &description_)
 Add an output profile officially supported by the manager. More...
 
const std::map< std::string, std::string > & get_supported_output_profiles () const
 Return the dictionary of supported output profiles. More...
 
bool has_activated_output_profiles () const
 Check if some output profiles are activated. More...
 
bool has_activated_output_profile (const std::string &profile_id_) const
 Check if a given output profile is activated. More...
 
void activate_output_profile (const std::string &profile_id_)
 Activate a given output profile. More...
 
void deactivate_output_profile (const std::string &profile_id_)
 Deactivate a given output profile. More...
 
void set_output_profiles_activation_rule (const std::string &rule_)
 Set the activation rule for output profiles. More...
 
void apply_output_profiles_activation_rule (const std::string &output_profiles_activation_rule_)
 Apply activation rule for output profile. More...
 
void fetch_activated_output_profile_ids (std::vector< std::string > &activated_output_profile_ids_) const
 Build the list of output profiles' Ids. More...
 
const std::set< std::string > & get_activated_output_profile_ids () const
 Return the set of activated output profiles' Ids. More...
 
void dump (std::ostream &=std::clog) const
 Basic default print. More...
 
void dump_base (std::ostream &out_=std::clog, const std::string &title_="", const std::string &indent_="") const
 Basic print. More...
 
- Public Member Functions inherited from mctools::g4::loggable_support
 loggable_support ()
 Default constructor. More...
 
 loggable_support (datatools::logger::priority)
 Constructor from logging priority level. More...
 
datatools::logger::priority get_logging_priority () const
 
virtual ~loggable_support ()
 Destructor. More...
 
void set_logging_priority (const std::string &priority_label_)
 
void set_logging_priority (datatools::logger::priority)
 
bool is_debug () const
 
void set_debug (bool)
 
bool is_verbose () const
 
void set_verbose (bool)
 

Static Public Member Functions

static const std::string & g4_manager_label ()
 
static const std::string & vertex_generator_label ()
 
static const std::string & event_generator_label ()
 
static const std::string & shpf_label ()
 
static const std::string & default_prng_id ()
 
static const std::string & default_prng_states_file ()
 

Static Public Attributes

static const uint32_t NUMBER_OF_EVENTS_UPPER_LIMIT = 1000000000
 Maximum number of events to be processed. More...
 
static const uint32_t NUMBER_OF_EVENTS_LOWER_LIMIT = 1
 Minimum number of events to be processed. More...
 
static const uint32_t NUMBER_OF_EVENTS_WARNING_LIMIT = 1000000
 Number of events that triggers an alarm. More...
 
static const uint32_t NO_LIMIT = manager::NUMBER_OF_EVENTS_UPPER_LIMIT
 
static const uint32_t DEFAULT_PRNG_STATES_SAVE_MODULO = 100
 

Protected Member Functions

virtual void initialize_impl ()
 Initialization actions. More...
 
virtual void reset_impl ()
 Termination actions. More...
 
virtual void run_simulation_impl ()
 Simulation actions. More...
 
void _init_defaults ()
 Initialize attirbutes' default values. More...
 
virtual void _init_core ()
 Initialize the manager's core functionalities. More...
 
virtual void _init_geometry ()
 Initialize the geometry. More...
 
virtual void _init_vertex_generator ()
 Initialize the vertex generator. More...
 
virtual void _init_event_generator ()
 Initialize the event generator. More...
 
virtual void _init_detector_construction ()
 Initialize the detector construction. More...
 
virtual void _init_physics_list ()
 Initialize the physics list. More...
 
virtual void _init_run_action ()
 Initialize the run action. More...
 
virtual void _init_event_action ()
 Initialize the event action. More...
 
virtual void _init_primary_generator_action ()
 Initialize the primary generator action. More...
 
virtual void _init_tracking_action ()
 Initialize the tracking action. More...
 
virtual void _init_stepping_action ()
 Initialize the stepping action. More...
 
virtual void _init_stacking_action ()
 Initialize the stacking action. More...
 
void _init_seeds ()
 Initialize the seeds for embedded PRNGs. More...
 
void _init_prngs_states ()
 Initialize the internal states of embedded PRNGs. More...
 
virtual void _init_prngs ()
 Initialize the embedded PRNGs. More...
 
virtual void _init_time_stat ()
 Initialize the time statistics. More...
 
- Protected Member Functions inherited from mctools::g4::loggable_support
void _initialize_logging_support (const datatools::properties &)
 
datatools::logger::priority _logprio () const
 

Additional Inherited Members

- Protected Attributes inherited from mctools::g4::loggable_support
datatools::logger::priority _logging_priority
 Logging priority threshold. More...
 

Detailed Description

The Geant4 simulation manager.

Member Typedef Documentation

◆ CT_map

typedef std::map<std::string, CT_type> mctools::g4::manager::CT_map

◆ CT_type

Constructor & Destructor Documentation

◆ manager()

mctools::g4::manager::manager ( )

Default constructor:

◆ ~manager()

virtual mctools::g4::manager::~manager ( )
virtual

Destructor.

Member Function Documentation

◆ _init_core()

virtual void mctools::g4::manager::_init_core ( )
protectedvirtual

Initialize the manager's core functionalities.

◆ _init_defaults()

void mctools::g4::manager::_init_defaults ( )
protected

Initialize attirbutes' default values.

◆ _init_detector_construction()

virtual void mctools::g4::manager::_init_detector_construction ( )
protectedvirtual

Initialize the detector construction.

◆ _init_event_action()

virtual void mctools::g4::manager::_init_event_action ( )
protectedvirtual

Initialize the event action.

◆ _init_event_generator()

virtual void mctools::g4::manager::_init_event_generator ( )
protectedvirtual

Initialize the event generator.

◆ _init_geometry()

virtual void mctools::g4::manager::_init_geometry ( )
protectedvirtual

Initialize the geometry.

◆ _init_physics_list()

virtual void mctools::g4::manager::_init_physics_list ( )
protectedvirtual

Initialize the physics list.

◆ _init_primary_generator_action()

virtual void mctools::g4::manager::_init_primary_generator_action ( )
protectedvirtual

Initialize the primary generator action.

◆ _init_prngs()

virtual void mctools::g4::manager::_init_prngs ( )
protectedvirtual

Initialize the embedded PRNGs.

◆ _init_prngs_states()

void mctools::g4::manager::_init_prngs_states ( )
protected

Initialize the internal states of embedded PRNGs.

◆ _init_run_action()

virtual void mctools::g4::manager::_init_run_action ( )
protectedvirtual

Initialize the run action.

◆ _init_seeds()

void mctools::g4::manager::_init_seeds ( )
protected

Initialize the seeds for embedded PRNGs.

◆ _init_stacking_action()

virtual void mctools::g4::manager::_init_stacking_action ( )
protectedvirtual

Initialize the stacking action.

◆ _init_stepping_action()

virtual void mctools::g4::manager::_init_stepping_action ( )
protectedvirtual

Initialize the stepping action.

◆ _init_time_stat()

virtual void mctools::g4::manager::_init_time_stat ( )
protectedvirtual

Initialize the time statistics.

◆ _init_tracking_action()

virtual void mctools::g4::manager::_init_tracking_action ( )
protectedvirtual

Initialize the tracking action.

◆ _init_vertex_generator()

virtual void mctools::g4::manager::_init_vertex_generator ( )
protectedvirtual

Initialize the vertex generator.

◆ activate_output_profile()

void mctools::g4::manager::activate_output_profile ( const std::string &  profile_id_)

Activate a given output profile.

◆ add_supported_output_profile()

void mctools::g4::manager::add_supported_output_profile ( const std::string &  profile_id_,
const std::string &  description_ 
)

Add an output profile officially supported by the manager.

◆ apply_output_profiles_activation_rule()

void mctools::g4::manager::apply_output_profiles_activation_rule ( const std::string &  output_profiles_activation_rule_)

Apply activation rule for output profile.

◆ deactivate_output_profile()

void mctools::g4::manager::deactivate_output_profile ( const std::string &  profile_id_)

Deactivate a given output profile.

◆ default_prng_id()

static const std::string& mctools::g4::manager::default_prng_id ( )
static

◆ default_prng_states_file()

static const std::string& mctools::g4::manager::default_prng_states_file ( )
static

◆ dont_save_no_sensitive_hit_events()

bool mctools::g4::manager::dont_save_no_sensitive_hit_events ( ) const

◆ dump()

void mctools::g4::manager::dump ( std::ostream &  = std::clog) const

Basic default print.

◆ dump_base()

void mctools::g4::manager::dump_base ( std::ostream &  out_ = std::clog,
const std::string &  title_ = "",
const std::string &  indent_ = "" 
) const

Basic print.

◆ event_generator_label()

static const std::string& mctools::g4::manager::event_generator_label ( )
static

◆ fetch_activated_output_profile_ids()

void mctools::g4::manager::fetch_activated_output_profile_ids ( std::vector< std::string > &  activated_output_profile_ids_) const

Build the list of output profiles' Ids.

◆ forbids_private_hits()

bool mctools::g4::manager::forbids_private_hits ( ) const

◆ g4_manager_label()

static const std::string& mctools::g4::manager::g4_manager_label ( )
static

◆ get_activated_output_profile_ids()

const std::set<std::string>& mctools::g4::manager::get_activated_output_profile_ids ( ) const

Return the set of activated output profiles' Ids.

◆ get_CT_map()

const CT_map& mctools::g4::manager::get_CT_map ( ) const

◆ get_eg_manager()

const genbb::manager& mctools::g4::manager::get_eg_manager ( ) const

Get a non-mutable reference to the embedded event generator.

◆ get_event_generator()

const genbb::i_genbb& mctools::g4::manager::get_event_generator ( ) const

Return a non-mutable reference to a embedded event generator.

◆ get_g4_macro()

const std::string& mctools::g4::manager::get_g4_macro ( ) const

Return the filename of the Geant4 macro.

◆ get_g4_prng()

const g4_prng& mctools::g4::manager::get_g4_prng ( ) const

Return a non mutable reference to the Geant4 engine's PRNG.

◆ get_geom_manager()

const geomtools::manager& mctools::g4::manager::get_geom_manager ( ) const

Get a non-mutable reference to the geometry manager.

◆ get_init_seed_method()

const std::string& mctools::g4::manager::get_init_seed_method ( ) const

Return the method for seed initialization.

◆ get_input_prng_seeds_file()

const std::string& mctools::g4::manager::get_input_prng_seeds_file ( ) const

◆ get_input_prng_states_file()

const std::string& mctools::g4::manager::get_input_prng_states_file ( ) const

◆ get_mgr_prng()

const mygsl::rng& mctools::g4::manager::get_mgr_prng ( ) const

Return a non mutable reference to the Geant4 engine's PRNG.

◆ get_mgr_prng_seed()

int mctools::g4::manager::get_mgr_prng_seed ( ) const

Get the seed of the G4 simulation engine.

◆ get_number_of_events()

uint32_t mctools::g4::manager::get_number_of_events ( ) const

Return the number of events to be generated.

◆ get_number_of_events_modulo()

int mctools::g4::manager::get_number_of_events_modulo ( ) const

Return the number of events modulo.

◆ get_output_data_format()

io_utils::data_format_type mctools::g4::manager::get_output_data_format ( ) const

Return the output data file format.

◆ get_output_prng_seeds_file()

const std::string& mctools::g4::manager::get_output_prng_seeds_file ( ) const

◆ get_output_prng_states_file()

const std::string& mctools::g4::manager::get_output_prng_states_file ( ) const

◆ get_prng_state_save_modulo()

int mctools::g4::manager::get_prng_state_save_modulo ( ) const

◆ get_seed_manager()

const mygsl::seed_manager& mctools::g4::manager::get_seed_manager ( ) const

Return a non mutable reference to the manager of PRNG's seeds.

◆ get_service_manager()

const datatools::service_manager& mctools::g4::manager::get_service_manager ( ) const

Return a non-mutable service manager reference.

◆ get_simulation_ctrl()

const simulation_ctrl& mctools::g4::manager::get_simulation_ctrl ( ) const

Return a non-mutable thread simulation control reference.

◆ get_state_manager()

const mygsl::prng_state_manager& mctools::g4::manager::get_state_manager ( ) const

Return a non mutable reference to the manager of PRNG's states.

◆ get_supported_output_profiles()

const std::map<std::string, std::string>& mctools::g4::manager::get_supported_output_profiles ( ) const

Return the dictionary of supported output profiles.

◆ get_track_history()

const track_history& mctools::g4::manager::get_track_history ( ) const

Get a non-mutable reference to the track history object.

◆ get_vertex_generator()

const genvtx::i_vertex_generator& mctools::g4::manager::get_vertex_generator ( ) const

Return a non-mutable reference to a embedded vertex generator.

◆ get_vg_manager()

const genvtx::manager& mctools::g4::manager::get_vg_manager ( ) const

Get a non-mutable reference to the vertex generator manager.

◆ grab_CT_map()

CT_map& mctools::g4::manager::grab_CT_map ( )

◆ grab_eg_manager()

genbb::manager& mctools::g4::manager::grab_eg_manager ( )

Get a mutable reference to the embedded event generator.

◆ grab_eg_prng()

mygsl::rng& mctools::g4::manager::grab_eg_prng ( )

Return a mutable reference to the event generator's PRNG.

◆ grab_g4_prng()

g4_prng& mctools::g4::manager::grab_g4_prng ( )

Return a mutable reference to the Geant4 engine's PRNG.

◆ grab_mgr_prng()

mygsl::rng& mctools::g4::manager::grab_mgr_prng ( )

Return a mutable reference to the Geant4 engine's PRNG.

◆ grab_seed_manager()

mygsl::seed_manager& mctools::g4::manager::grab_seed_manager ( )

Return a mutable reference to the manager of PRNG's seeds.

◆ grab_service_manager()

datatools::service_manager& mctools::g4::manager::grab_service_manager ( )

Return a mutable service manager reference.

◆ grab_shpf_prng()

mygsl::rng& mctools::g4::manager::grab_shpf_prng ( )

Return a mutable reference to the Step Hit Processor Factory's PRNG.

◆ grab_simulation_ctrl()

simulation_ctrl& mctools::g4::manager::grab_simulation_ctrl ( )

Return a mutable thread simulation control reference.

◆ grab_state_manager()

mygsl::prng_state_manager& mctools::g4::manager::grab_state_manager ( )

Return a mutable reference to the manager of PRNG's states.

◆ grab_track_history()

track_history& mctools::g4::manager::grab_track_history ( )

Get a mutable reference to the track history object.

◆ grab_user_event_action()

event_action& mctools::g4::manager::grab_user_event_action ( )

Return a mutable event_action reference.

◆ grab_vg_manager()

genvtx::manager& mctools::g4::manager::grab_vg_manager ( )

Get a mutable reference to the vertex generator manager.

◆ grab_vg_prng()

mygsl::rng& mctools::g4::manager::grab_vg_prng ( )

Return a mutable reference to the vertex generator's PRNG.

◆ has_activated_output_profile()

bool mctools::g4::manager::has_activated_output_profile ( const std::string &  profile_id_) const

Check if a given output profile is activated.

◆ has_activated_output_profiles()

bool mctools::g4::manager::has_activated_output_profiles ( ) const

Check if some output profiles are activated.

◆ has_event_generator()

bool mctools::g4::manager::has_event_generator ( ) const

Check if an event generator is available.

◆ has_external_geom_manager()

bool mctools::g4::manager::has_external_geom_manager ( ) const

Check if an external service manager is plugged.

◆ has_g4_macro()

bool mctools::g4::manager::has_g4_macro ( ) const

Check if the manager has a Geant4 macro.

◆ has_g4_visualization()

bool mctools::g4::manager::has_g4_visualization ( ) const

Check the Geant4 visualization flag.

◆ has_init_seed_method()

bool mctools::g4::manager::has_init_seed_method ( ) const

Check if the method for seed initialization is set.

◆ has_input_prng_seeds_file()

bool mctools::g4::manager::has_input_prng_seeds_file ( ) const

◆ has_input_prng_states_file()

bool mctools::g4::manager::has_input_prng_states_file ( ) const

◆ has_mgr_prng_seed()

bool mctools::g4::manager::has_mgr_prng_seed ( ) const

Check the seed of the G4 simulation engine.

◆ has_number_of_events_modulo()

bool mctools::g4::manager::has_number_of_events_modulo ( ) const

Check if a modulo on number of events is defined.

◆ has_output_prng_seeds_file()

bool mctools::g4::manager::has_output_prng_seeds_file ( ) const

◆ has_output_prng_states_file()

bool mctools::g4::manager::has_output_prng_states_file ( ) const

◆ has_prng_state_save_modulo()

bool mctools::g4::manager::has_prng_state_save_modulo ( ) const

◆ has_service_manager()

bool mctools::g4::manager::has_service_manager ( ) const

Check is an external service manager plugged.

◆ has_simulation_ctrl()

bool mctools::g4::manager::has_simulation_ctrl ( ) const

Check if an external thread simulation control is plugged.

◆ has_supported_output_profile()

bool mctools::g4::manager::has_supported_output_profile ( const std::string &  profile_id_) const

Check if some output profile is officially supported by the manager.

◆ has_track_history()

bool mctools::g4::manager::has_track_history ( ) const

Check if a track history object is available.

◆ has_vertex_generator()

bool mctools::g4::manager::has_vertex_generator ( ) const

Check if a vertex generator is available.

◆ initialize()

void mctools::g4::manager::initialize ( const datatools::multi_properties mp_)

Initialize the Geant4 manager.

◆ initialize_impl()

virtual void mctools::g4::manager::initialize_impl ( )
protectedvirtual

Initialization actions.

◆ is_automatic()

bool mctools::g4::manager::is_automatic ( ) const

Return true if simulation will run in batch mode sans macro file.

◆ is_batch()

bool mctools::g4::manager::is_batch ( ) const

Return true if the simulation will run in batch mode.

◆ is_initialized()

bool mctools::g4::manager::is_initialized ( ) const

Return true if the simulation is fully initialized.

◆ is_interactive()

bool mctools::g4::manager::is_interactive ( ) const

Return true if the simulation is interactive via a CLI/GUI.

◆ record_current_prng_states()

void mctools::g4::manager::record_current_prng_states ( )

Record the current states of all PRNGs.

◆ reset()

void mctools::g4::manager::reset ( )

Reset the Geant4 manager.

◆ reset_impl()

virtual void mctools::g4::manager::reset_impl ( )
protectedvirtual

Termination actions.

◆ reset_input_prng_seeds_file()

void mctools::g4::manager::reset_input_prng_seeds_file ( )

◆ reset_input_prng_states_file()

void mctools::g4::manager::reset_input_prng_states_file ( )

◆ reset_output_data_format()

void mctools::g4::manager::reset_output_data_format ( )

Reset the output data file format.

◆ reset_output_prng_seeds_file()

void mctools::g4::manager::reset_output_prng_seeds_file ( )

◆ reset_output_prng_states_file()

void mctools::g4::manager::reset_output_prng_states_file ( )

◆ reset_simulation_ctrl()

void mctools::g4::manager::reset_simulation_ctrl ( )

Unplug an external thread simulation control.

◆ run_simulation()

void mctools::g4::manager::run_simulation ( )

Run the simulation session.

◆ run_simulation_impl()

virtual void mctools::g4::manager::run_simulation_impl ( )
protectedvirtual

Simulation actions.

◆ set_dont_save_no_sensitive_hit_events()

void mctools::g4::manager::set_dont_save_no_sensitive_hit_events ( bool  a_dont_save)

◆ set_event_generator_name()

void mctools::g4::manager::set_event_generator_name ( const std::string &  )

Set the name of the active event generator.

◆ set_event_generator_seed()

void mctools::g4::manager::set_event_generator_seed ( int  )

Set the seed for the event generator's PRNG.

◆ set_external_geom_manager()

void mctools::g4::manager::set_external_geom_manager ( const geomtools::manager gm)

Plug an external geometry manager.

◆ set_forbid_private_hits()

void mctools::g4::manager::set_forbid_private_hits ( bool  a_forbid)

◆ set_g4_macro()

void mctools::g4::manager::set_g4_macro ( const std::string &  macroFile)

Set the Geant4 macro.

◆ set_g4_visualization()

void mctools::g4::manager::set_g4_visualization ( bool  )

Set the Geant4 visualization flag.

◆ set_init_seed_method()

void mctools::g4::manager::set_init_seed_method ( const std::string &  )

Set the method used to set the initialization seed for the generation of seeds.

◆ set_input_prng_seeds_file()

void mctools::g4::manager::set_input_prng_seeds_file ( const std::string &  )

◆ set_input_prng_states_file()

void mctools::g4::manager::set_input_prng_states_file ( const std::string &  )

◆ set_interactive()

void mctools::g4::manager::set_interactive ( bool  )

Set the simulation to be interactive.

◆ set_mgr_prng_seed()

void mctools::g4::manager::set_mgr_prng_seed ( int  seed)

Set the seed of the G4 simulation engine.

◆ set_number_of_events()

void mctools::g4::manager::set_number_of_events ( uint32_t  )

Set the number of events to be generated.

◆ set_number_of_events_modulo()

void mctools::g4::manager::set_number_of_events_modulo ( int  )

Set the number of events modulo.

◆ set_output_data_bank_label()

void mctools::g4::manager::set_output_data_bank_label ( const std::string &  )

Set the output data bank label(for "bank" output format only)

◆ set_output_data_file()

void mctools::g4::manager::set_output_data_file ( const std::string &  )

Set the output data file name.

◆ set_output_data_format()

void mctools::g4::manager::set_output_data_format ( io_utils::data_format_type  )

Set the output data file format.

◆ set_output_data_format_by_label()

void mctools::g4::manager::set_output_data_format_by_label ( const std::string &  )

Set the output data file format.

◆ set_output_prng_seeds_file()

void mctools::g4::manager::set_output_prng_seeds_file ( const std::string &  )

◆ set_output_prng_states_file()

void mctools::g4::manager::set_output_prng_states_file ( const std::string &  )

◆ set_output_profiles_activation_rule()

void mctools::g4::manager::set_output_profiles_activation_rule ( const std::string &  rule_)

Set the activation rule for output profiles.

◆ set_prng_state_save_modulo()

void mctools::g4::manager::set_prng_state_save_modulo ( int  a_modulo)

◆ set_service_manager()

void mctools::g4::manager::set_service_manager ( datatools::service_manager sm)

Plug an external service manager.

◆ set_shpf_prng_seed()

void mctools::g4::manager::set_shpf_prng_seed ( int  )

Set the seed for the Step Hit Processor Factory's PRNG.

◆ set_simulation_ctrl()

void mctools::g4::manager::set_simulation_ctrl ( simulation_ctrl &  a_simulation_ctrl)

Plug an external thread simulation control.

◆ set_use_run_header_footer()

void mctools::g4::manager::set_use_run_header_footer ( bool  a_use_run_header_footer)

◆ set_use_track_history()

void mctools::g4::manager::set_use_track_history ( const bool  )

(De)Activate the track history object

◆ set_using_time_stat()

void mctools::g4::manager::set_using_time_stat ( bool  )

◆ set_vertex_generator_name()

void mctools::g4::manager::set_vertex_generator_name ( const std::string &  )

Set the name of the active vertex generator.

◆ set_vertex_generator_seed()

void mctools::g4::manager::set_vertex_generator_seed ( int  )

Set the seed for the vertex generator's PRNG.

◆ shpf_label()

static const std::string& mctools::g4::manager::shpf_label ( )
static

◆ using_run_header_footer()

bool mctools::g4::manager::using_run_header_footer ( ) const

◆ using_time_stat()

bool mctools::g4::manager::using_time_stat ( ) const

◆ vertex_generator_label()

static const std::string& mctools::g4::manager::vertex_generator_label ( )
static

Member Data Documentation

◆ DEFAULT_PRNG_STATES_SAVE_MODULO

const uint32_t mctools::g4::manager::DEFAULT_PRNG_STATES_SAVE_MODULO = 100
static

◆ NO_LIMIT

const uint32_t mctools::g4::manager::NO_LIMIT = manager::NUMBER_OF_EVENTS_UPPER_LIMIT
static

◆ NUMBER_OF_EVENTS_LOWER_LIMIT

const uint32_t mctools::g4::manager::NUMBER_OF_EVENTS_LOWER_LIMIT = 1
static

Minimum number of events to be processed.

◆ NUMBER_OF_EVENTS_UPPER_LIMIT

const uint32_t mctools::g4::manager::NUMBER_OF_EVENTS_UPPER_LIMIT = 1000000000
static

Maximum number of events to be processed.

◆ NUMBER_OF_EVENTS_WARNING_LIMIT

const uint32_t mctools::g4::manager::NUMBER_OF_EVENTS_WARNING_LIMIT = 1000000
static

Number of events that triggers an alarm.


The documentation for this class was generated from the following file: