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

G4VPVDivisionFactory is an abstract factory that defines the interfaces for creating volume divisions. More...

#include <G4VPVDivisionFactory.hh>

Inheritance diagram for G4VPVDivisionFactory:

Public Member Functions

virtual ~G4VPVDivisionFactory ()=default
virtual G4VPhysicalVolumeCreatePVDivision (const G4String &pName, G4LogicalVolume *pLogical, G4LogicalVolume *pMother, const EAxis pAxis, const G4int nReplicas, const G4double width, const G4double offset)=0
virtual G4VPhysicalVolumeCreatePVDivision (const G4String &pName, G4LogicalVolume *pLogical, G4LogicalVolume *pMother, const EAxis pAxis, const G4int nReplicas, const G4double offset)=0
virtual G4VPhysicalVolumeCreatePVDivision (const G4String &pName, G4LogicalVolume *pLogical, G4LogicalVolume *pMother, const EAxis pAxis, const G4double width, const G4double offset)=0
virtual G4VPhysicalVolumeCreatePVDivision (const G4String &pName, G4LogicalVolume *pLogical, G4LogicalVolume *pMother, const G4VPVParameterisation *param)=0
virtual G4bool IsPVDivision (const G4VPhysicalVolume *pv) const =0

Static Public Member Functions

static G4VPVDivisionFactoryInstance ()

Protected Member Functions

 G4VPVDivisionFactory ()=default

Static Protected Attributes

static G4ThreadLocal G4VPVDivisionFactoryfgInstance = nullptr

Detailed Description

G4VPVDivisionFactory is an abstract factory that defines the interfaces for creating volume divisions.

Definition at line 48 of file G4VPVDivisionFactory.hh.

Constructor & Destructor Documentation

◆ ~G4VPVDivisionFactory()

virtual G4VPVDivisionFactory::~G4VPVDivisionFactory ( )
virtualdefault

Default Destructor.

◆ G4VPVDivisionFactory()

G4VPVDivisionFactory::G4VPVDivisionFactory ( )
protecteddefault

Protected default Constructor.

Referenced by Instance(), and ~G4VPVDivisionFactory().

Member Function Documentation

◆ CreatePVDivision() [1/4]

virtual G4VPhysicalVolume * G4VPVDivisionFactory::CreatePVDivision ( const G4String & pName,
G4LogicalVolume * pLogical,
G4LogicalVolume * pMother,
const EAxis pAxis,
const G4double width,
const G4double offset )
pure virtual

Creates a division, using the width of the division slice.

Parameters
[in]pNameThe volume name.
[in]pLogicalPointer to the logical volume of the division.
[in]pMotherPointer to the logical volume of the mother.
[in]pAxisThe axis along which do the division.
[in]widthThe witdh of the divided slice along the axis.
[in]offsetThe optional offset distance from mother's border.
Returns
The pointer to physical divided volume.

Implemented in G4PVDivisionFactory.

◆ CreatePVDivision() [2/4]

virtual G4VPhysicalVolume * G4VPVDivisionFactory::CreatePVDivision ( const G4String & pName,
G4LogicalVolume * pLogical,
G4LogicalVolume * pMother,
const EAxis pAxis,
const G4int nReplicas,
const G4double offset )
pure virtual

Creates a division, using the number of divisions.

Parameters
[in]pNameThe volume name.
[in]pLogicalPointer to the logical volume of the division.
[in]pMotherPointer to the logical volume of the mother.
[in]pAxisThe axis along which do the division.
[in]nReplicasThe number of copies to replicate.
[in]offsetThe optional offset distance from mother's border.
Returns
The pointer to physical divided volume.

Implemented in G4PVDivisionFactory.

◆ CreatePVDivision() [3/4]

virtual G4VPhysicalVolume * G4VPVDivisionFactory::CreatePVDivision ( const G4String & pName,
G4LogicalVolume * pLogical,
G4LogicalVolume * pMother,
const EAxis pAxis,
const G4int nReplicas,
const G4double width,
const G4double offset )
pure virtual

Creates a division, using number of divisions and width.

Parameters
[in]pNameThe volume name.
[in]pLogicalPointer to the logical volume of the division.
[in]pMotherPointer to the logical volume of the mother.
[in]pAxisThe axis along which do the division.
[in]nReplicasThe number of copies to replicate.
[in]widthThe witdh of the divided slice along the axis.
[in]offsetThe optional offset distance from mother's border.
Returns
The pointer to physical divided volume.

Implemented in G4PVDivisionFactory.

Referenced by G4ReflectionFactory::Divide(), G4ReflectionFactory::Divide(), and G4ReflectionFactory::Divide().

◆ CreatePVDivision() [4/4]

virtual G4VPhysicalVolume * G4VPVDivisionFactory::CreatePVDivision ( const G4String & pName,
G4LogicalVolume * pLogical,
G4LogicalVolume * pMother,
const G4VPVParameterisation * param )
pure virtual

Creates a division, using a parameterisation algorithm.

Parameters
[in]pNameThe volume name.
[in]pLogicalPointer to the logical volume of the division.
[in]pMotherPointer to the logical volume of the mother.
[in]paramThe pointer to the parameterisation algorithm.
Returns
The pointer to physical divided volume.

Implemented in G4PVDivisionFactory.

◆ Instance()

G4VPVDivisionFactory * G4VPVDivisionFactory::Instance ( )
static

Returns a pointer to the unique instance of the factory.

Definition at line 37 of file G4VPVDivisionFactory.cc.

38{
39 // Static singleton access method.
40 // ---
41 return fgInstance;
42}
static G4ThreadLocal G4VPVDivisionFactory * fgInstance

◆ IsPVDivision()

virtual G4bool G4VPVDivisionFactory::IsPVDivision ( const G4VPhysicalVolume * pv) const
pure virtual

Returns true if 'pv' is a pointer to a division.

Implemented in G4PVDivisionFactory.

Member Data Documentation

◆ fgInstance

G4ThreadLocal G4VPVDivisionFactory * G4VPVDivisionFactory::fgInstance = nullptr
staticprotected

The static pointer of the singleton instance.

Definition at line 147 of file G4VPVDivisionFactory.hh.

Referenced by G4PVDivisionFactory::GetInstance(), and Instance().


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