Geant4.10
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Protected Types | Protected Attributes
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

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

Definition at line 82 of file G4MCCIndexConversionTable.hh.

Constructor & Destructor Documentation

G4MCCIndexConversionTable::G4MCCIndexConversionTable ( )

Definition at line 41 of file G4MCCIndexConversionTable.cc.

42 {
43 
44 }
G4MCCIndexConversionTable::~G4MCCIndexConversionTable ( )
virtual

Definition at line 46 of file G4MCCIndexConversionTable.cc.

References vecNewIndex.

47 {
48  vecNewIndex.clear();
49 }

Member Function Documentation

G4int G4MCCIndexConversionTable::GetIndex ( size_t  index) const
inline

Definition at line 106 of file G4MCCIndexConversionTable.hh.

References vecNewIndex.

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

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 }
G4bool G4MCCIndexConversionTable::IsUsed ( size_t  index) const
inline

Definition at line 87 of file G4MCCIndexConversionTable.hh.

References vecNewIndex.

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

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 }
void G4MCCIndexConversionTable::Reset ( size_t  size)

Definition at line 51 of file G4MCCIndexConversionTable.cc.

References vecNewIndex.

Referenced by G4ProductionCutsTable::CheckMaterialCutsCoupleInfo().

52 {
53  // reset conversion table
54  vecNewIndex.clear();
55  vecNewIndex.resize(siz, -1);
56 }
void G4MCCIndexConversionTable::SetNewIndex ( size_t  index,
size_t  new_value 
)
inline

Definition at line 97 of file G4MCCIndexConversionTable.hh.

References vecNewIndex.

Referenced by G4ProductionCutsTable::CheckMaterialCutsCoupleInfo().

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 }
size_t G4MCCIndexConversionTable::size ( ) const
inline

Definition at line 115 of file G4MCCIndexConversionTable.hh.

References vecNewIndex.

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

116 {
117  return vecNewIndex.size();
118 }

Field Documentation

G4IntVector G4MCCIndexConversionTable::vecNewIndex
protected

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