Public Member Functions | Private Attributes | List of all members
EDepSim::FixedPositionFactory Class Reference

#include <EDepSimFixedPositionFactory.hh>

Inheritance diagram for EDepSim::FixedPositionFactory:
EDepSim::VPositionFactory EDepSim::VPrimaryFactory

Public Member Functions

 FixedPositionFactory (EDepSim::UserPrimaryGeneratorMessenger *parent)
 
virtual ~FixedPositionFactory ()
 
EDepSim::VPositionGeneratorGetGenerator ()
 Return the fixed vertex generator. More...
 
G4ThreeVector GetPosition ()
 Return the position for the next generator. More...
 
void SetPosition (const G4ThreeVector &pos)
 Set the position for the next generator. More...
 
void SetNewValue (G4UIcommand *, G4String)
 Handle messages from the UI processor. More...
 
- Public Member Functions inherited from EDepSim::VPositionFactory
 VPositionFactory (G4String name, EDepSim::UserPrimaryGeneratorMessenger *fParent, bool makeDirectory=true)
 
virtual ~VPositionFactory ()
 
- 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

G4ThreeVector fPosition
 
G4UIcmdWith3VectorAndUnit * fPositionCMD
 

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 7 of file EDepSimFixedPositionFactory.hh.

Constructor & Destructor Documentation

EDepSim::FixedPositionFactory::FixedPositionFactory ( EDepSim::UserPrimaryGeneratorMessenger parent)

Definition at line 5 of file EDepSimFixedPositionFactory.cc.

7  : EDepSim::VPositionFactory("fixed",parent),
8  fPosition(0,0,0) {
9 
10  fPositionCMD = new G4UIcmdWith3VectorAndUnit(CommandName("position"),this);
11  fPositionCMD->SetGuidance("Set the position of events to generate.");
12  fPositionCMD->SetParameterName("x","y","z",false);
13  fPositionCMD->SetUnitCategory("Length");
14 
15 }
G4String CommandName(G4String cmd)
Build a command name with the directory prefix.
G4UIcmdWith3VectorAndUnit * fPositionCMD
EDepSim::FixedPositionFactory::~FixedPositionFactory ( )
virtual

Definition at line 17 of file EDepSimFixedPositionFactory.cc.

17 {}

Member Function Documentation

EDepSim::VPositionGenerator * EDepSim::FixedPositionFactory::GetGenerator ( )
virtual

Return the fixed vertex generator.

Implements EDepSim::VPositionFactory.

Definition at line 19 of file EDepSimFixedPositionFactory.cc.

G4ThreeVector EDepSim::FixedPositionFactory::GetPosition ( )
inline

Return the position for the next generator.

Definition at line 16 of file EDepSimFixedPositionFactory.hh.

void EDepSim::FixedPositionFactory::SetNewValue ( G4UIcommand *  ,
G4String   
)
virtual

Handle messages from the UI processor.

Reimplemented from EDepSim::VPrimaryFactory.

Definition at line 25 of file EDepSimFixedPositionFactory.cc.

26  {
27  if (command == fPositionCMD) {
28  SetPosition(fPositionCMD->GetNew3VectorValue(newValue));
29  }
30 }
int command
void SetPosition(const G4ThreeVector &pos)
Set the position for the next generator.
G4UIcmdWith3VectorAndUnit * fPositionCMD
void EDepSim::FixedPositionFactory::SetPosition ( const G4ThreeVector &  pos)
inline

Set the position for the next generator.

Definition at line 19 of file EDepSimFixedPositionFactory.hh.

Member Data Documentation

G4ThreeVector EDepSim::FixedPositionFactory::fPosition
private

Definition at line 24 of file EDepSimFixedPositionFactory.hh.

G4UIcmdWith3VectorAndUnit* EDepSim::FixedPositionFactory::fPositionCMD
private

Definition at line 26 of file EDepSimFixedPositionFactory.hh.


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