Geant4 11.3.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4MoleculeShoot Class Referenceabstract

#include <G4MoleculeGun.hh>

+ Inheritance diagram for G4MoleculeShoot:

Public Member Functions

 G4MoleculeShoot ()
 
virtual ~G4MoleculeShoot ()
 
virtual void Shoot (G4MoleculeGun *)=0
 
template<typename TYPE>
G4shared_ptr< G4MoleculeShootChangeType ()
 

Static Public Member Functions

static void RandomPosInBox (const G4ThreeVector &boxSize, G4ThreeVector &output)
 

Public Attributes

G4String fMoleculeName
 
G4ThreeVector fPosition
 
G4double fTime
 
G4int fNumber
 
G4ThreeVectorfBoxSize
 

Detailed Description

Definition at line 72 of file G4MoleculeGun.hh.

Constructor & Destructor Documentation

◆ G4MoleculeShoot()

G4MoleculeShoot::G4MoleculeShoot ( )

Definition at line 197 of file G4MoleculeGun.cc.

198{
199 fMoleculeName = "";
200 fTime = 0;
201 fNumber = 1;
202 fBoxSize = nullptr;
203}
G4ThreeVector * fBoxSize
G4String fMoleculeName

Referenced by TG4MoleculeShoot< TYPE >::TG4MoleculeShoot().

◆ ~G4MoleculeShoot()

G4MoleculeShoot::~G4MoleculeShoot ( )
virtual

Definition at line 207 of file G4MoleculeGun.cc.

208{
209 delete fBoxSize;
210}

Member Function Documentation

◆ ChangeType()

template<typename TYPE>
G4shared_ptr< G4MoleculeShoot > G4MoleculeShoot::ChangeType ( )

Definition at line 123 of file G4MoleculeGun.hh.

124{
125 G4shared_ptr<G4MoleculeShoot> output(new TG4MoleculeShoot<TYPE>);
126 output->fMoleculeName = fMoleculeName;
127 output->fPosition = fPosition;
128 output->fTime = fTime;
129 output->fNumber = fNumber;
130 output->fBoxSize = fBoxSize;
131 return output;
132}
#define G4shared_ptr
Definition G4memory.hh:32
G4ThreeVector fPosition

◆ RandomPosInBox()

void G4MoleculeShoot::RandomPosInBox ( const G4ThreeVector & boxSize,
G4ThreeVector & output )
static

Definition at line 187 of file G4MoleculeGun.cc.

189{
190 output[0] = boxSize.x() * G4UniformRand() - boxSize.x()/2;
191 output[1] = boxSize.y() * G4UniformRand() - boxSize.y()/2;
192 output[2] = boxSize.z() * G4UniformRand() - boxSize.z()/2;
193}
#define G4UniformRand()
Definition Randomize.hh:52
double z() const
double x() const
double y() const

Referenced by TG4MoleculeShoot< TYPE >::ShootAtRandomPosition().

◆ Shoot()

virtual void G4MoleculeShoot::Shoot ( G4MoleculeGun * )
pure virtual

Member Data Documentation

◆ fBoxSize

◆ fMoleculeName

◆ fNumber

◆ fPosition

◆ fTime


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