Public Member Functions | Private Attributes | List of all members
EDepSim::VCountFactory Class Referenceabstract

#include <EDepSimVCountFactory.hh>

Inheritance diagram for EDepSim::VCountFactory:
EDepSim::VPrimaryFactory EDepSim::FixedCountFactory EDepSim::MeanCountFactory

Public Member Functions

 VCountFactory (G4String name, EDepSim::UserPrimaryGeneratorMessenger *fParent, bool makeDirectory=true)
 
virtual ~VCountFactory ()
 
virtual EDepSim::VCountGeneratorGetGenerator ()=0
 
void SetIntensity (double v)
 Set the intensity. More...
 
double GetIntensity () const
 
void SetNewValue (G4UIcommand *, G4String)
 Handle messages from the UI processor. More...
 
- Public Member Functions inherited from EDepSim::VPrimaryFactory
 VPrimaryFactory (G4String subdir, G4String name, EDepSim::UserPrimaryGeneratorMessenger *parent, bool makeDirectory)
 
virtual ~VPrimaryFactory ()
 
G4String GetPath () const
 
G4String GetName () const
 
G4String GetSubDir () const
 

Private Attributes

G4UIcmdWithADouble * fIntensityCMD
 
double fIntensity
 

Additional Inherited Members

- Protected Member Functions inherited from EDepSim::VPrimaryFactory
G4String CommandName (G4String cmd)
 Build a command name with the directory prefix. More...
 

Detailed Description

Definition at line 9 of file EDepSimVCountFactory.hh.

Constructor & Destructor Documentation

EDepSim::VCountFactory::VCountFactory ( G4String  name,
EDepSim::UserPrimaryGeneratorMessenger fParent,
bool  makeDirectory = true 
)

Definition at line 3 of file EDepSimVCountFactory.cc.

7  : EDepSim::VPrimaryFactory("count",name,parent,makeDirectory), fIntensity(0.0)
8 {
9  fIntensityCMD = new G4UIcmdWithADouble(CommandName("intensity"),this);
10  fIntensityCMD->SetGuidance("Set the intensity for the events. This is"
11  " only for documentation and is saved in the"
12  " MC header.");
13  fIntensityCMD->SetParameterName("intensity",false);
14 }
static QCString name
Definition: declinfo.cpp:673
G4UIcmdWithADouble * fIntensityCMD
G4String CommandName(G4String cmd)
Build a command name with the directory prefix.
def parent(G, child, parent_type)
Definition: graph.py:67
EDepSim::VCountFactory::~VCountFactory ( )
virtual

Definition at line 16 of file EDepSimVCountFactory.cc.

16  {
17  delete fIntensityCMD;
18 }
G4UIcmdWithADouble * fIntensityCMD

Member Function Documentation

virtual EDepSim::VCountGenerator* EDepSim::VCountFactory::GetGenerator ( )
pure virtual

Return a new generator enclosing the current factory state. The new generator method is pure virtual so it must be implemented by derived classes.

Implemented in EDepSim::FixedCountFactory, and EDepSim::MeanCountFactory.

double EDepSim::VCountFactory::GetIntensity ( ) const
inline

Get the intensity. For a beam spill MC, this will represent the protons per pulse.

Definition at line 26 of file EDepSimVCountFactory.hh.

void EDepSim::VCountFactory::SetIntensity ( double  v)
inline

Set the intensity.

Definition at line 22 of file EDepSimVCountFactory.hh.

void EDepSim::VCountFactory::SetNewValue ( G4UIcommand *  command,
G4String  newValue 
)
virtual

Handle messages from the UI processor.

Reimplemented from EDepSim::VPrimaryFactory.

Definition at line 20 of file EDepSimVCountFactory.cc.

21  {
22  if (command == fIntensityCMD) {
23  SetIntensity(fIntensityCMD->GetNewDoubleValue(newValue));
24  }
25 }
int command
G4UIcmdWithADouble * fIntensityCMD
void SetIntensity(double v)
Set the intensity.

Member Data Documentation

double EDepSim::VCountFactory::fIntensity
private

The intensity for this event. This is only documentation and is saved in the MC header. For a beam spill MC, this will represent the protons per pulse.

Definition at line 37 of file EDepSimVCountFactory.hh.

G4UIcmdWithADouble* EDepSim::VCountFactory::fIntensityCMD
private

Definition at line 32 of file EDepSimVCountFactory.hh.


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