76 G4mstgbisot::const_iterator isotcite;
80 delete (*isotcite).second;
84 G4mstgbelem::const_iterator elemcite;
88 delete (*elemcite).second;
92 G4mstgbmate::const_iterator matcite;
96 delete (*matcite).second;
109 G4mstgrisot::const_iterator cite;
110 for( cite = tgrIsots.begin(); cite != tgrIsots.end(); cite++ )
124 G4mstgrelem::const_iterator cite;
125 for( cite = tgrElems.begin(); cite != tgrElems.end(); cite++ )
139 G4mstgrmate::const_iterator cite;
140 for( cite = tgrMates.begin(); cite != tgrMates.end(); cite++ )
144 if( tgr->
GetType() ==
"MaterialSimple" ) {
146 }
else if( tgr->
GetType() ==
"MaterialMixtureByWeight" ) {
148 }
else if( tgr->
GetType() ==
"MaterialMixtureByNoAtoms" ) {
150 }
else if( tgr->
GetType() ==
"MaterialMixtureByVolume" ) {
178 G4cout <<
" G4tgbMaterialMgr::FindOrBuildG4Isotope() -"
179 <<
" G4Isotope already built: " << g4isot->
GetName() <<
G4endl;
187 G4cout <<
" G4tgbMaterialMgr::FindOrBuildG4Isotope() - Isotope: "
200 G4msg4isot::const_iterator cite =
theG4Isotopes.find( name );
203 g4isot = (*cite).second;
207 G4cout <<
" G4tgbMaterialMgr::FindBuiltG4Isotope() - Isotope: "
208 << name <<
" = " << g4isot <<
G4endl;
230 G4cout <<
" G4tgbMaterialMgr::FindG4tgbIsotope() -"
231 <<
" G4tgbIsotope found: " << ( (*cite).second )->GetName()
235 isot = (*cite).second;
237 if( (isot == 0) && bMustExist )
239 G4String ErrMessage =
"Isotope " + name +
" not found !";
240 G4Exception(
"G4tgbMaterialMgr::FindG4tgbIsotope()",
259 G4cout <<
" G4NistManager::Instance()->FindOrBuildElement( " <<
G4endl;
264 if( tgbelem->
GetType() ==
"ElementSimple" )
268 else if( tgbelem->
GetType() ==
"ElementFromIsotopes" )
275 +
" does not exist !";
287 G4cout <<
" G4tgbMaterialMgr::FindOrBuildG4Element() - Element: "
296 G4String ErrMessage =
"Element " + name +
" not found !";
297 G4Exception(
"G4tgbMaterialMgr::FindOrBuildG4Element()",
303 G4cout <<
" G4tgbMaterialMgr::FindOrBuildG4Element() - Element: "
304 << name <<
" not found " <<
G4endl;
314 G4cout <<
" G4tgbMaterialMgr::GetG4Element() -"
315 <<
" G4Element already built: " << g4elem->
GetName() <<
G4endl;
329 G4msg4elem::const_iterator cite =
theG4Elements.find( name );
332 g4elem = (*cite).second;
336 G4cout <<
" G4tgbMaterialMgr::FindBuiltG4Element() - Element: "
337 << name <<
" = " << g4elem <<
G4endl;
358 G4cout <<
" G4tgbMaterialMgr::FindG4tgbElement() -"
359 <<
" G4tgbElement found: " << ( (*cite).second )->GetName()
363 elem = (*cite).second;
365 if( (elem == 0) && bMustExist )
367 G4String ErrMessage =
"Element " + name +
" not found !";
368 G4Exception(
"G4tgbMaterialMgr::FindG4tgbElement()",
397 GetTgrMate()->GetIonisationMeanExcitationEnergy());
408 G4cout <<
" G4tgbMaterialMgr::FindOrBuildG4Material() - Material: "
417 G4String ErrMessage =
"Material " + name +
" not found !";
418 G4Exception(
"G4tgbMaterialMgr::FindOrBuildG4Material()",
424 G4cout <<
" G4tgbMaterialMgr::FindOrBuildG4Material() - Element: "
425 << name <<
" not found " <<
G4endl;
435 G4cout <<
" G4tgbMaterialMgr::FindOrBuildG4Material() -"
436 <<
" G4Material already built: " << g4mate->
GetName() <<
G4endl;
453 g4mate = (*cite).second;
457 G4cout <<
" G4tgbMaterialMgr::FindBuiltG4Material() - Material: "
458 << name <<
" = " << g4mate <<
G4endl;
475 mate = (*cite).second;
479 G4cout <<
" G4tgbMaterialMgr::FindG4tgbMaterial() -"
480 <<
" G4tgbMaterial found: " << ( (*cite).second )->GetName()
481 <<
" type " << ( (*cite).second )->GetName() <<
G4endl;
486 if( (mate == 0) && bMustExist )
488 G4String ErrMessage =
"Material " + name +
" not found !";
489 G4Exception(
"G4tgbMaterialMgr::FindG4tgbMaterial()",
G4tgbMaterial * FindG4tgbMaterial(const G4String &name, G4bool bMustExist=0) const
static G4int GetVerboseLevel()
static G4tgbMaterialMgr * GetInstance()
const G4String & GetName() const
G4mstgbisot theG4tgbIsotopes
std::map< G4String, G4tgrElement * > G4mstgrelem
const G4String & GetType() const
const G4String & GetName() const
std::map< G4String, G4tgrIsotope * > G4mstgrisot
G4tgbIsotope * FindG4tgbIsotope(const G4String &name, G4bool bMustExist=0) const
static G4tgrMaterialFactory * GetInstance()
const G4mstgrisot & GetIsotopeList() const
G4Element * BuildG4ElementFromIsotopes()
G4Material * FindOrBuildG4Material(const G4String &name, G4bool bMustExist=1)
G4Element * FindBuiltG4Element(const G4String &name) const
void SetMeanExcitationEnergy(G4double value)
static G4ThreadLocal G4tgbMaterialMgr * theInstance
G4msg4mate theG4Materials
G4double GetIonisationMeanExcitationEnergy() const
G4Material * FindBuiltG4Material(const G4String &name) const
G4Isotope * FindOrBuildG4Isotope(const G4String &name)
const G4String & GetName() const
G4Element * FindOrBuildElement(G4int Z, G4bool isotopes=true)
virtual G4Material * BuildG4Material()=0
G4Isotope * FindBuiltG4Isotope(const G4String &name) const
G4Material * FindOrBuildMaterial(const G4String &name, G4bool isotopes=true, G4bool warning=false)
const G4String & GetName() const
G4tgbElement * FindG4tgbElement(const G4String &name, G4bool bMustExist=0) const
G4tgrMaterial * GetTgrMate() const
const G4mstgrelem & GetElementList() const
const G4String & GetName() const
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *description)
std::map< G4String, G4tgrMaterial * > G4mstgrmate
G4Element * FindOrBuildG4Element(const G4String &name, G4bool bMustExist=1)
G4IonisParamMat * GetIonisation() const
const G4String & GetName() const
G4GLOB_DLL std::ostream G4cout
G4mstgbmate theG4tgbMaterials
const G4mstgrmate & GetMaterialList() const
G4mstgbelem theG4tgbElements
const G4String & GetType() const
G4Isotope * BuildG4Isotope()
G4Element * BuildG4ElementSimple()
static G4NistManager * Instance()