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

G4NavigationLevel is a utility class for use by G4NavigationHistory. It maintains one level of the geometrical hierarchy. More...

#include <G4NavigationLevel.hh>

Public Member Functions

 G4NavigationLevel (G4VPhysicalVolume *newPtrPhysVol, const G4AffineTransform &newT, EVolume newVolTp, G4int newRepNo=-1)
 G4NavigationLevel (G4VPhysicalVolume *newPtrPhysVol, const G4AffineTransform &levelAbove, const G4AffineTransform &relativeCurrent, EVolume newVolTp, G4int newRepNo=-1)
 G4NavigationLevel ()
 ~G4NavigationLevel ()
 G4NavigationLevel (const G4NavigationLevel &)
G4NavigationLeveloperator= (const G4NavigationLevel &)
G4VPhysicalVolumeGetPhysicalVolume () const
const G4AffineTransformGetTransformPtr () const
const G4AffineTransformGetTransform () const
const G4AffineTransformGetPtrTransform () const
EVolume GetVolumeType () const
G4int GetReplicaNo () const
void * operator new (size_t)
void operator delete (void *aLevel)
void * operator new (size_t, void *)
void operator delete (void *ptr, void *)

Detailed Description

G4NavigationLevel is a utility class for use by G4NavigationHistory. It maintains one level of the geometrical hierarchy.

Definition at line 54 of file G4NavigationLevel.hh.

Constructor & Destructor Documentation

◆ G4NavigationLevel() [1/4]

G4NavigationLevel::G4NavigationLevel ( G4VPhysicalVolume * newPtrPhysVol,
const G4AffineTransform & newT,
EVolume newVolTp,
G4int newRepNo = -1 )

Constructor for G4NavigationLevel.

Parameters
[in]newPtrPhysVolPointer to the new physical volume.
[in]newTThe associated affine transformation.
[in]newVolTpThe volume type.
[in]newRepNoThe replica number.

Definition at line 39 of file G4NavigationLevel.cc.

43{
44 fLevelRep = new G4NavigationLevelRep( pPhysVol, afTransform, volTp, repNo );
45}

Referenced by G4NavigationLevel(), and operator=().

◆ G4NavigationLevel() [2/4]

G4NavigationLevel::G4NavigationLevel ( G4VPhysicalVolume * newPtrPhysVol,
const G4AffineTransform & levelAbove,
const G4AffineTransform & relativeCurrent,
EVolume newVolTp,
G4int newRepNo = -1 )

Alternative Constructor for G4NavigationLevel, as the previous constructor, but instead of giving the new transformation, give the affine transformation to the level above and the current level's transformation relative to that.

Parameters
[in]newPtrPhysVolPointer to the new physical volume.
[in]levelAboveThe affine transformation to the level above.
[in]relativeCurrentThe affine transformation at current level.
[in]newVolTpThe volume type.
[in]newRepNoThe replica number.

Definition at line 47 of file G4NavigationLevel.cc.

52{
53 fLevelRep = new G4NavigationLevelRep( pPhysVol,
54 levelAbove,
55 relativeCurrent,
56 volTp,
57 repNo );
58}

◆ G4NavigationLevel() [3/4]

G4NavigationLevel::G4NavigationLevel ( )

Default Constructor & Destructor.

Definition at line 60 of file G4NavigationLevel.cc.

61{
62 fLevelRep = new G4NavigationLevelRep();
63}

◆ ~G4NavigationLevel()

G4NavigationLevel::~G4NavigationLevel ( )

Definition at line 71 of file G4NavigationLevel.cc.

72{
73 if( fLevelRep->RemoveAReference() ) { delete fLevelRep; }
74}

◆ G4NavigationLevel() [4/4]

G4NavigationLevel::G4NavigationLevel ( const G4NavigationLevel & right)

Copy constructor and assignment operator.

Definition at line 65 of file G4NavigationLevel.cc.

66 : fLevelRep( right.fLevelRep )
67{
68 fLevelRep->AddAReference();
69}

Member Function Documentation

◆ GetPhysicalVolume()

G4VPhysicalVolume * G4NavigationLevel::GetPhysicalVolume ( ) const
inline

Returns a pointer to the physical volume at the current level.

◆ GetPtrTransform()

const G4AffineTransform * G4NavigationLevel::GetPtrTransform ( ) const
inline

◆ GetReplicaNo()

G4int G4NavigationLevel::GetReplicaNo ( ) const
inline

Returns the replica number.

◆ GetTransform()

const G4AffineTransform & G4NavigationLevel::GetTransform ( ) const
inline

◆ GetTransformPtr()

const G4AffineTransform * G4NavigationLevel::GetTransformPtr ( ) const
inline

Methods to return the associated affine transformation.

◆ GetVolumeType()

EVolume G4NavigationLevel::GetVolumeType ( ) const
inline

Returns the volume type.

◆ operator delete() [1/2]

void G4NavigationLevel::operator delete ( void * aLevel)
inline

◆ operator delete() [2/2]

void G4NavigationLevel::operator delete ( void * ptr,
void *  )
inline

◆ operator new() [1/2]

void * G4NavigationLevel::operator new ( size_t )
inline

New/delete operator overrides for use by "G4Allocator".

◆ operator new() [2/2]

void * G4NavigationLevel::operator new ( size_t ,
void *  )
inline

New/delete operator overrides for use with STL.

◆ operator=()

G4NavigationLevel & G4NavigationLevel::operator= ( const G4NavigationLevel & right)

Definition at line 76 of file G4NavigationLevel.cc.

77{
78 if ( &right != this )
79 {
80 right.fLevelRep->AddAReference();
81 if( fLevelRep->RemoveAReference() ) { delete fLevelRep; }
82 fLevelRep = right.fLevelRep;
83 }
84 return *this;
85}

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