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

G4SmartVoxelProxy is a class for proxying smart voxels. The class represents either a header (in turn referring to more VoxelProxies) or a node. If created as a node, calls to GetHeader() cause an exception, and likewise GetNode() when a header. More...

#include <G4SmartVoxelProxy.hh>

Public Member Functions

 G4SmartVoxelProxy (G4SmartVoxelHeader *pHeader)
 G4SmartVoxelProxy (G4SmartVoxelNode *pNode)
 ~G4SmartVoxelProxy ()=default
G4bool operator== (const G4SmartVoxelProxy &v) const
G4bool IsHeader () const
G4bool IsNode () const
G4SmartVoxelNodeGetNode () const
G4SmartVoxelHeaderGetHeader () const

Detailed Description

G4SmartVoxelProxy is a class for proxying smart voxels. The class represents either a header (in turn referring to more VoxelProxies) or a node. If created as a node, calls to GetHeader() cause an exception, and likewise GetNode() when a header.

Definition at line 57 of file G4SmartVoxelProxy.hh.

Constructor & Destructor Documentation

◆ G4SmartVoxelProxy() [1/2]

G4SmartVoxelProxy::G4SmartVoxelProxy ( G4SmartVoxelHeader * pHeader)
inline

Constructs a Proxy for the specified header.

Parameters
[in]pHeaderPointer to the voxel header.

Referenced by operator==().

◆ G4SmartVoxelProxy() [2/2]

G4SmartVoxelProxy::G4SmartVoxelProxy ( G4SmartVoxelNode * pNode)
inline

Constructs a Proxy for the specified node.

Parameters
[in]pNodePointer to the voxel node.

◆ ~G4SmartVoxelProxy()

G4SmartVoxelProxy::~G4SmartVoxelProxy ( )
default

Default destructor. Not responsible for proxied objects.

Member Function Documentation

◆ GetHeader()

G4SmartVoxelHeader * G4SmartVoxelProxy::GetHeader ( ) const
inline

Returns the pointer to the proxied header, else throws a G4Exception.

Referenced by G4VoxelNavigation::LocateNextVoxel(), G4SmartVoxelHeader::operator==(), and G4VoxelSafety::SafetyForVoxelHeader().

◆ GetNode()

G4SmartVoxelNode * G4SmartVoxelProxy::GetNode ( ) const
inline

Returns the pointer to the proxied node, else throws a G4Exception.

Referenced by G4VoxelNavigation::LocateNextVoxel(), G4SmartVoxelHeader::operator==(), and G4VoxelSafety::SafetyForVoxelHeader().

◆ IsHeader()

G4bool G4SmartVoxelProxy::IsHeader ( ) const
inline

Returns true if proxying for a header, else false.

Referenced by G4SmartVoxelHeader::operator==().

◆ IsNode()

G4bool G4SmartVoxelProxy::IsNode ( ) const
inline

Returns true if proxying for a node, else false.

Referenced by G4VoxelNavigation::LocateNextVoxel(), G4SmartVoxelHeader::operator==(), and G4VoxelSafety::SafetyForVoxelHeader().

◆ operator==()

G4bool G4SmartVoxelProxy::operator== ( const G4SmartVoxelProxy & v) const
inline

Equality operator. True when objects share the same address.


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