G4VITManager::allbox_iterator Class Reference

#include <G4ITManager.hh>

Inheritance diagram for G4VITManager::allbox_iterator:

G4VITManager::iterator

Public Member Functions

 allbox_iterator (G4ITType)
 allbox_iterator (G4VITManager *)
virtual ~allbox_iterator ()
allbox_iteratoroperator= (const allbox_iterator &i)
allbox_iteratoroperator++ (G4int)

Protected Attributes

G4VITManagerfInstance

Detailed Description

Definition at line 119 of file G4ITManager.hh.


Constructor & Destructor Documentation

G4VITManager::allbox_iterator::allbox_iterator ( G4ITType   ) 

Definition at line 40 of file G4ITManager_allbox_iterator.cc.

References G4VITManager::iterator::fCurrentBox, fInstance, G4VITManager::iterator::fNextIT, G4VITManager::GetFirstBox(), G4AllITManager::GetInstance(), and G4AllITManager::Instance().

00040                                                           : iterator(0)
00041 {
00042     fInstance = G4AllITManager::Instance()->GetInstance(type);
00043     fCurrentBox = fInstance->GetFirstBox();
00044     fNextIT = 0 ;
00045 }

G4VITManager::allbox_iterator::allbox_iterator ( G4VITManager  ) 

Definition at line 47 of file G4ITManager_allbox_iterator.cc.

References G4VITManager::iterator::fCurrentBox, fInstance, G4VITManager::iterator::fNextIT, and G4VITManager::GetFirstBox().

00047                                                               : iterator(0)
00048 {
00049     fInstance = man;
00050     fCurrentBox = fInstance->GetFirstBox();
00051     fNextIT = 0 ;
00052 }

virtual G4VITManager::allbox_iterator::~allbox_iterator (  )  [inline, virtual]

Definition at line 124 of file G4ITManager.hh.

00124 {;}


Member Function Documentation

G4VITManager::allbox_iterator & G4VITManager::allbox_iterator::operator++ ( G4int   ) 

Reimplemented from G4VITManager::iterator.

Definition at line 56 of file G4ITManager_allbox_iterator.cc.

References G4VITManager::iterator::fCurrentBox, fInstance, G4VITManager::iterator::fNextIT, G4ITBox::GetFirstIT(), G4VITManager::GetLastBox(), and G4ITBox::GetNextBox().

00057 {       
00058     if(fNextIT)
00059     {
00060         fNextIT = fNextIT -> GetNext();
00061         if(fNextIT == 0)
00062         {
00063             while (fCurrentBox && fCurrentBox != fInstance->GetLastBox() && fNextIT == 0)
00064             {
00065                 fCurrentBox = fCurrentBox->GetNextBox();
00066                 if(fCurrentBox)
00067                 {
00068                     fNextIT = fCurrentBox->GetFirstIT();
00069 //                    if(fNextIT)
00070 //                        G4cout << "allbox_iterator::operator++ -- : "
00071 //                               << fNextIT -> GetName()
00072 //                               << " (" << fNextIT->GetTrack()->GetTrackID() << ") "
00073 //                               << G4endl;
00074                 }
00075             }
00076         }
00077 //        else
00078 //        {
00079 //            G4cout << "allbox_iterator::operator++ -- : "
00080 //                   << fNextIT -> GetName()
00081 //                   << " (" << fNextIT->GetTrack()->GetTrackID() << ") "
00082 //                   << G4endl;
00083 //        }
00084     }
00085     return *this;
00086 }

G4VITManager::allbox_iterator & G4VITManager::allbox_iterator::operator= ( const allbox_iterator i  ) 

Definition at line 89 of file G4ITManager_allbox_iterator.cc.

References G4VITManager::iterator::fCurrentBox, and G4VITManager::iterator::fNextIT.

00090 {
00091     if(this != &i)
00092     {
00093         fNextIT = i.fNextIT;
00094         fCurrentBox = i.fCurrentBox;
00095     }
00096     return *this;
00097 }


Field Documentation

G4VITManager* G4VITManager::allbox_iterator::fInstance [protected]

Definition at line 129 of file G4ITManager.hh.

Referenced by allbox_iterator(), and operator++().


The documentation for this class was generated from the following files:
Generated on Mon May 27 17:53:49 2013 for Geant4 by  doxygen 1.4.7