CGEM BOSS 6.6.5.f
BESIII Offline Software System
Loading...
Searching...
No Matches
CgemG4Geo Class Reference

#include <CgemG4Geo.h>

+ Inheritance diagram for CgemG4Geo:

Public Member Functions

 CgemG4Geo ()
 Constructor.
 
 ~CgemG4Geo ()
 Destructor.
 
void InitFromGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of G4Geo.
 
void SetDefaultVis ()
 Set default visual attributes;.
 
 CgemG4Geo ()
 Constructor.
 
 ~CgemG4Geo ()
 Destructor.
 
void InitFromGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of G4Geo.
 
void SetDefaultVis ()
 Set default visual attributes;.
 
- Public Member Functions inherited from SubDetectorG4Geo
 SubDetectorG4Geo ()
 Constructor.
 
virtual ~SubDetectorG4Geo ()
 Destructor.
 
void ReadGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of G4Geo.
 
int IsInitialized ()
 If the G4 geometry of this subdetctor is initialized;.
 
G4LogicalVolume * GetLogicalVolume (const std::string &vn)
 Get a logical volume by name;.
 
G4LogicalVolume * GetTopVolume ()
 Get the top(world) volume;.
 
 SubDetectorG4Geo ()
 Constructor.
 
virtual ~SubDetectorG4Geo ()
 Destructor.
 
void ReadGdml (const char *gdmlFile, const char *setupName)
 Initialize the instance of G4Geo.
 
int IsInitialized ()
 If the G4 geometry of this subdetctor is initialized;.
 
G4LogicalVolume * GetLogicalVolume (const std::string &vn)
 Get a logical volume by name;.
 
G4LogicalVolume * GetTopVolume ()
 Get the top(world) volume;.
 

Additional Inherited Members

- Protected Attributes inherited from SubDetectorG4Geo
int m_G4GeoInit
 
G4LogicalVolume * m_TopVolume
 

Detailed Description

Class MdcGeo contains all of the objects necessary to describe the Mdc geometry by GDML.

Definition at line 19 of file DetectorDescription/G4Geo/G4Geo-00-00-13/G4Geo/CgemG4Geo.h.

Constructor & Destructor Documentation

◆ CgemG4Geo() [1/2]

CgemG4Geo::CgemG4Geo ( )

Constructor.

Definition at line 20 of file CgemG4Geo.cxx.

21{
22 string GdmlManagementPath = getenv("GDMLMANAGEMENTROOT");
23 if (GdmlManagementPath == "") cout << "CgemG4Geo::GdmlManagementPath not set" << endl;
24 string GdmlFile = GdmlManagementPath + string("/dat/Cgem.gdml");
25 cout << "Construct Cgem from GdmlFile " << GdmlFile << endl;
26 InitFromGdml( GdmlFile.c_str(), "Cgem" );
27}
void InitFromGdml(const char *gdmlFile, const char *setupName)
Initialize the instance of G4Geo.
Definition: CgemG4Geo.cxx:33

◆ ~CgemG4Geo() [1/2]

CgemG4Geo::~CgemG4Geo ( )

Destructor.

Definition at line 29 of file CgemG4Geo.cxx.

30{ }

◆ CgemG4Geo() [2/2]

CgemG4Geo::CgemG4Geo ( )

Constructor.

◆ ~CgemG4Geo() [2/2]

CgemG4Geo::~CgemG4Geo ( )

Destructor.

Member Function Documentation

◆ InitFromGdml() [1/2]

void CgemG4Geo::InitFromGdml ( const char *  gdmlFile,
const char *  setupName 
)

Initialize the instance of G4Geo.

Definition at line 33 of file CgemG4Geo.cxx.

34{
35 ReadGdml(gdmlFile, setupName);
36 m_TopVolume = GetLogicalVolume("Cgem_logic");
37 if (!m_TopVolume) cout << "CgemG4Geo::InitFromGdml, m_TopVolume not found" << endl;
38 else cout << "Cgem TopVolume name " << m_TopVolume->GetName() << endl;
40
41 m_G4GeoInit = 1;
42}
void SetDefaultVis()
Set default visual attributes;.
Definition: CgemG4Geo.cxx:45
void ReadGdml(const char *gdmlFile, const char *setupName)
Initialize the instance of G4Geo.
G4LogicalVolume * GetLogicalVolume(const std::string &vn)
Get a logical volume by name;.

Referenced by CgemG4Geo().

◆ InitFromGdml() [2/2]

void CgemG4Geo::InitFromGdml ( const char *  gdmlFile,
const char *  setupName 
)

Initialize the instance of G4Geo.

◆ SetDefaultVis() [1/2]

void CgemG4Geo::SetDefaultVis ( )

Set default visual attributes;.

Definition at line 45 of file CgemG4Geo.cxx.

46{
47}

Referenced by InitFromGdml().

◆ SetDefaultVis() [2/2]

void CgemG4Geo::SetDefaultVis ( )

Set default visual attributes;.


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