Geant4-11
Public Member Functions | Private Attributes
G4SmartVoxelNode Class Reference

#include <G4SmartVoxelNode.hh>

Public Member Functions

 G4SmartVoxelNode (G4int pSlice=0)
 
std::size_t GetCapacity () const
 
G4int GetMaxEquivalentSliceNo () const
 
G4int GetMinEquivalentSliceNo () const
 
std::size_t GetNoContained () const
 
G4int GetVolume (G4int pVolumeNo) const
 
void Insert (G4int pVolumeNo)
 
void operator delete (void *aNode)
 
void * operator new (std::size_t)
 
G4bool operator== (const G4SmartVoxelNode &v) const
 
void Reserve (G4int noSlices)
 
void SetMaxEquivalentSliceNo (G4int pMax)
 
void SetMinEquivalentSliceNo (G4int pMin)
 
void Shrink ()
 
 ~G4SmartVoxelNode ()=default
 

Private Attributes

G4SliceVector fcontents
 
G4int fmaxEquivalent
 
G4int fminEquivalent
 

Detailed Description

Definition at line 58 of file G4SmartVoxelNode.hh.

Constructor & Destructor Documentation

◆ G4SmartVoxelNode()

G4SmartVoxelNode::G4SmartVoxelNode ( G4int  pSlice = 0)
inline

Definition at line 62 of file G4SmartVoxelNode.hh.

62 : fminEquivalent(pSlice),
63 fmaxEquivalent(pSlice) {}

◆ ~G4SmartVoxelNode()

G4SmartVoxelNode::~G4SmartVoxelNode ( )
default

Member Function Documentation

◆ GetCapacity()

std::size_t G4SmartVoxelNode::GetCapacity ( ) const
inline

◆ GetMaxEquivalentSliceNo()

G4int G4SmartVoxelNode::GetMaxEquivalentSliceNo ( ) const
inline

◆ GetMinEquivalentSliceNo()

G4int G4SmartVoxelNode::GetMinEquivalentSliceNo ( ) const
inline

◆ GetNoContained()

std::size_t G4SmartVoxelNode::GetNoContained ( ) const
inline

◆ GetVolume()

G4int G4SmartVoxelNode::GetVolume ( G4int  pVolumeNo) const
inline

◆ Insert()

void G4SmartVoxelNode::Insert ( G4int  pVolumeNo)
inline

◆ operator delete()

void G4SmartVoxelNode::operator delete ( void *  aNode)
inline

◆ operator new()

void * G4SmartVoxelNode::operator new ( std::size_t  )
inline

◆ operator==()

G4bool G4SmartVoxelNode::operator== ( const G4SmartVoxelNode v) const

Definition at line 48 of file G4SmartVoxelNode.cc.

49{
50 std::size_t maxNode = GetNoContained();
51 if (maxNode == v.GetNoContained())
52 {
53 for (std::size_t node=0; node<maxNode; ++node)
54 {
55 if (GetVolume(node) != v.GetVolume(node))
56 {
57 return false;
58 }
59 }
60 return true;
61 }
62 return false;
63}
G4int GetVolume(G4int pVolumeNo) const
std::size_t GetNoContained() const

References GetNoContained(), and GetVolume().

◆ Reserve()

void G4SmartVoxelNode::Reserve ( G4int  noSlices)
inline

◆ SetMaxEquivalentSliceNo()

void G4SmartVoxelNode::SetMaxEquivalentSliceNo ( G4int  pMax)
inline

◆ SetMinEquivalentSliceNo()

void G4SmartVoxelNode::SetMinEquivalentSliceNo ( G4int  pMin)
inline

◆ Shrink()

void G4SmartVoxelNode::Shrink ( )
inline

Field Documentation

◆ fcontents

G4SliceVector G4SmartVoxelNode::fcontents
private

Definition at line 114 of file G4SmartVoxelNode.hh.

◆ fmaxEquivalent

G4int G4SmartVoxelNode::fmaxEquivalent
private

Definition at line 113 of file G4SmartVoxelNode.hh.

◆ fminEquivalent

G4int G4SmartVoxelNode::fminEquivalent
private

Definition at line 112 of file G4SmartVoxelNode.hh.


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