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

#include <G4tgbDetectorBuilder.hh>

Public Member Functions

 G4tgbDetectorBuilder ()
 
virtual ~G4tgbDetectorBuilder ()
 
virtual const G4tgrVolumeReadDetector ()
 
virtual G4VPhysicalVolumeConstructDetector (const G4tgrVolume *tgrVoltop)
 

Detailed Description

Definition at line 57 of file G4tgbDetectorBuilder.hh.

Constructor & Destructor Documentation

◆ G4tgbDetectorBuilder()

G4tgbDetectorBuilder::G4tgbDetectorBuilder ( )

Definition at line 53 of file G4tgbDetectorBuilder.cc.

54{
55}

◆ ~G4tgbDetectorBuilder()

G4tgbDetectorBuilder::~G4tgbDetectorBuilder ( )
virtual

Definition at line 58 of file G4tgbDetectorBuilder.cc.

59{
60}

Member Function Documentation

◆ ConstructDetector()

G4VPhysicalVolume * G4tgbDetectorBuilder::ConstructDetector ( const G4tgrVolume tgrVoltop)
virtual

Definition at line 76 of file G4tgbDetectorBuilder.cc.

77{
78 //---------- copy list of G4tgrVolume's to list of G4tgbVolume's
79 // (just a trick to make all GEANT4 volume building in this class)
81 tgbVolmgr->CopyVolumes();
82 //---------- find corresponding volume in list of G4tgbVolume's
83 G4tgbVolume* tgbVoltop = tgbVolmgr->FindVolume( tgrVoltop->GetName() );
84
85 //---------- ConstructG4Volumes of top G4tgbVolume
86 // (it will recursively build the whole tree)
87 tgbVoltop->ConstructG4Volumes( 0, (const G4LogicalVolume*)0 );
88
89 G4VPhysicalVolume* physvol = tgbVolmgr->GetTopPhysVol();
90
91#ifdef G4VERBOSE
93 {
94 G4cout << " G4tgbDetectorConstruction::ConstructDetector() - Volume: "
95 << physvol->GetName() << G4endl;
96 }
97#endif
98
99 return physvol;
100
101}
#define G4endl
Definition: G4ios.hh:52
G4DLLIMPORT std::ostream G4cout
const G4String & GetName() const
G4tgbVolume * FindVolume(const G4String &volname)
static G4tgbVolumeMgr * GetInstance()
G4VPhysicalVolume * GetTopPhysVol()
void ConstructG4Volumes(const G4tgrPlace *place, const G4LogicalVolume *parentLV)
Definition: G4tgbVolume.cc:137
static G4int GetVerboseLevel()
const G4String & GetName() const
Definition: G4tgrVolume.hh:89

Referenced by G4tgbVolumeMgr::ReadAndConstructDetector().

◆ ReadDetector()

const G4tgrVolume * G4tgbDetectorBuilder::ReadDetector ( )
virtual

Definition at line 63 of file G4tgbDetectorBuilder.cc.

64{
65 //------------------- construct g4 geometry
66 //---------- find top G4tgrVolume
69 const G4tgrVolume* tgrVoltop = tgrVolmgr->GetTopVolume();
70 return tgrVoltop;
71}
static G4tgrFileReader * GetInstance()
const G4tgrVolume * GetTopVolume()
static G4tgrVolumeMgr * GetInstance()

Referenced by G4tgbVolumeMgr::ReadAndConstructDetector().


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