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

#include <G4InterpolationIterator.hh>

Public Member Functions

 G4InterpolationIterator (G4InterpolationManager *aManager)
 
 ~G4InterpolationIterator ()
 
G4bool Fetch ()
 
G4InterpolationScheme Current ()
 

Detailed Description

Definition at line 36 of file G4InterpolationIterator.hh.

Constructor & Destructor Documentation

◆ G4InterpolationIterator()

G4InterpolationIterator::G4InterpolationIterator ( G4InterpolationManager aManager)
inline

Definition at line 42 of file G4InterpolationIterator.hh.

43 {
44 started = false;
45 theManager = aManager;
46 }

◆ ~G4InterpolationIterator()

G4InterpolationIterator::~G4InterpolationIterator ( )
inline

Definition at line 48 of file G4InterpolationIterator.hh.

48{}

Member Function Documentation

◆ Current()

G4InterpolationScheme G4InterpolationIterator::Current ( )
inline

Definition at line 67 of file G4InterpolationIterator.hh.

68 {
69 if(!started) throw G4HadronicException(__FILE__, __LINE__, "G4InterpolationIterator not started yet");
70 return aManager->scheme[current];
71 }

◆ Fetch()

G4bool G4InterpolationIterator::Fetch ( )
inline

Definition at line 50 of file G4InterpolationIterator.hh.

51 {
52 if(!started)
53 {
54 started = true;
55 counter=-1;
56 current = 0;
57 }
58 G4bool result = true;
59 if(++counter==nEntries)
60 started = false;
61 result = false;
62 else if(current != nRanges-1&&counter==theManager->start[current+1])
63 current++;
64 return result;
65 }
bool G4bool
Definition: G4Types.hh:67

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