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

#include <G4MCCIndexConversionTable.hh>

Public Member Functions

 G4MCCIndexConversionTable ()
 
virtual ~G4MCCIndexConversionTable ()
 
void Reset (size_t size)
 
G4bool IsUsed (size_t index) const
 
void SetNewIndex (size_t index, size_t new_value)
 
G4int GetIndex (size_t index) const
 
size_t size () const
 

Protected Types

typedef std::vector< G4intG4IntVector
 

Protected Attributes

G4IntVector vecNewIndex
 

Detailed Description

Definition at line 54 of file G4MCCIndexConversionTable.hh.

Member Typedef Documentation

◆ G4IntVector

typedef std::vector<G4int> G4MCCIndexConversionTable::G4IntVector
protected

Definition at line 82 of file G4MCCIndexConversionTable.hh.

Constructor & Destructor Documentation

◆ G4MCCIndexConversionTable()

G4MCCIndexConversionTable::G4MCCIndexConversionTable ( )

Definition at line 41 of file G4MCCIndexConversionTable.cc.

42{
43
44}

◆ ~G4MCCIndexConversionTable()

G4MCCIndexConversionTable::~G4MCCIndexConversionTable ( )
virtual

Definition at line 46 of file G4MCCIndexConversionTable.cc.

47{
48 vecNewIndex.clear();
49}

Member Function Documentation

◆ GetIndex()

G4int G4MCCIndexConversionTable::GetIndex ( size_t  index) const
inline

Definition at line 106 of file G4MCCIndexConversionTable.hh.

107{
108 if (index >= vecNewIndex.size()) return -1;
109 // get the index in the current production cut table
110 // for the indicated MCC in the file
111 return (vecNewIndex[index]);
112}

Referenced by G4ProductionCutsTable::RetrieveCutsInfo(), and G4PhysicsTableHelper::RetrievePhysicsTable().

◆ IsUsed()

G4bool G4MCCIndexConversionTable::IsUsed ( size_t  index) const
inline

Definition at line 87 of file G4MCCIndexConversionTable.hh.

88{
89 if (index >= vecNewIndex.size()) return false;
90
91 // returns 'true' if the indicated MCC in the file
92 // is used in the current production cut table
93 return (vecNewIndex[index] >= 0);
94}

Referenced by G4ProductionCutsTable::RetrieveCutsInfo(), and G4PhysicsTableHelper::RetrievePhysicsTable().

◆ Reset()

void G4MCCIndexConversionTable::Reset ( size_t  size)

Definition at line 51 of file G4MCCIndexConversionTable.cc.

52{
53 // reset conversion table
54 vecNewIndex.clear();
55 vecNewIndex.resize(siz, -1);
56}

Referenced by G4ProductionCutsTable::CheckMaterialCutsCoupleInfo().

◆ SetNewIndex()

void G4MCCIndexConversionTable::SetNewIndex ( size_t  index,
size_t  new_value 
)
inline

Definition at line 97 of file G4MCCIndexConversionTable.hh.

98{
99 if (index >= vecNewIndex.size()) return;
100 // set the index in the current production cut table
101 // for the indicated MCC in the file
102 vecNewIndex[index]=new_value;
103}

Referenced by G4ProductionCutsTable::CheckMaterialCutsCoupleInfo().

◆ size()

size_t G4MCCIndexConversionTable::size ( ) const
inline

Member Data Documentation

◆ vecNewIndex

G4IntVector G4MCCIndexConversionTable::vecNewIndex
protected

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