thepeg is hosted by Hepforge, IPPP Durham
ThePEG 2.3.0
ThePEG::Main Class Reference

This is a base class for classes implementing a main steering routine for running an EventGenerator, in case the standard 'go()' function in the EventGenerator is not enough. More...

#include <Main.h>

Inheritance diagram for ThePEG::Main:

Static Public Member Functions

static void eventGenerator (tEGPtr eg)
 Set the global event generator.
 
static tEGPtr eventGenerator ()
 Get the global event generator.
 
static void N (long n)
 Set the number of events requested.
 
static long N ()
 Get the number of events requested.
 
static void arguments (const vector< string > &args)
 Set the command-line arguments.
 
static const vector< string > & arguments ()
 Get the command-line arguments.
 
static void Init ()
 Standard Init function used to initialize the interfaces.
 
- Static Public Member Functions inherited from ThePEG::Base
static void Init ()
 The standard Init function used to initialize the interfaces.
 

Private Member Functions

Mainoperator= (const Main &)=delete
 Private and non-existent assignment operator.
 

Static Private Attributes

static EGPtr theEventGenerator
 The global event generator.
 
static long theN
 The number of events requested.
 
static vector< string > theArguments
 The command-line arguments.
 
static AbstractNoPIOClassDescription< MaininitMain
 Describe an abstract base class without persistent data.
 

Additional Inherited Members

- Public Types inherited from ThePEG::Pointer::ReferenceCounted
typedef unsigned int CounterType
 The integer type used for counting.
 
- Public Member Functions inherited from ThePEG::Base
virtual ~Base ()
 The virtual destructor.
 
void debug () const
 Print out debugging information for this object on std::cerr.
 
virtual void debugme () const
 Print out debugging information for this object on std::cerr.
 
- Public Member Functions inherited from ThePEG::Pointer::ReferenceCounted
CounterType referenceCount () const
 Return the reference count.
 
- Public Attributes inherited from ThePEG::Pointer::ReferenceCounted
const unsigned long uniqueId
 The unique ID.
 
- Protected Member Functions inherited from ThePEG::Pointer::ReferenceCounted
 ReferenceCounted ()
 Default constructor.
 
 ReferenceCounted (const ReferenceCounted &)
 Copy-constructor.
 
ReferenceCountedoperator= (const ReferenceCounted &)
 Assignment.
 

Detailed Description

This is a base class for classes implementing a main steering routine for running an EventGenerator, in case the standard 'go()' function in the EventGenerator is not enough.

An example is a EventGenerator where the class deriving from Main specifies an initial set of partons which should be cascaded and hadronized etc.

The derived class will be dynamically loaded by the standard runThePEG program and the static Init() function will be run. The loaded EventGenerator will then be available in the static eventGenerator() function. In addition the number of events requested from the command line will be available from the N() function. All other command-line arguments will be available from the arguments() function.

See also
EventGenerator

Definition at line 35 of file Main.h.

Member Function Documentation

◆ arguments() [1/2]

static const vector< string > & ThePEG::Main::arguments ( )
inlinestatic

Get the command-line arguments.

Definition at line 71 of file Main.h.

References theArguments.

◆ arguments() [2/2]

static void ThePEG::Main::arguments ( const vector< string > &  args)
inlinestatic

Set the command-line arguments.

Definition at line 63 of file Main.h.

References theArguments.

◆ eventGenerator() [1/2]

static tEGPtr ThePEG::Main::eventGenerator ( )
inlinestatic

Get the global event generator.

Definition at line 47 of file Main.h.

References theEventGenerator.

◆ eventGenerator() [2/2]

static void ThePEG::Main::eventGenerator ( tEGPtr  eg)
inlinestatic

Set the global event generator.

Definition at line 42 of file Main.h.

References theEventGenerator.

◆ Init()

static void ThePEG::Main::Init ( )
inlinestatic

Standard Init function used to initialize the interfaces.

Definition at line 78 of file Main.h.

◆ N() [1/2]

static long ThePEG::Main::N ( )
inlinestatic

Get the number of events requested.

Definition at line 57 of file Main.h.

References theN.

◆ N() [2/2]

static void ThePEG::Main::N ( long  n)
inlinestatic

Set the number of events requested.

Definition at line 52 of file Main.h.

References theN.

Member Data Documentation

◆ initMain

AbstractNoPIOClassDescription<Main> ThePEG::Main::initMain
staticprivate

Describe an abstract base class without persistent data.

Definition at line 102 of file Main.h.

◆ theArguments

vector<string> ThePEG::Main::theArguments
staticprivate

The command-line arguments.

Definition at line 95 of file Main.h.

Referenced by arguments().

◆ theEventGenerator

EGPtr ThePEG::Main::theEventGenerator
staticprivate

The global event generator.

Definition at line 85 of file Main.h.

Referenced by eventGenerator().

◆ theN

long ThePEG::Main::theN
staticprivate

The number of events requested.

Definition at line 90 of file Main.h.

Referenced by N().


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