Import Geant4 10.3.0.beta source tree

This commit is contained in:
Gabriele Cosmo
2016-06-30 14:12:05 +02:00
parent a654a7ab1f
commit 4ec577e5c4
2021 changed files with 100995 additions and 78277 deletions
@@ -23,7 +23,7 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4GDMLReadDefine.cc 92977 2015-09-24 14:56:22Z gcosmo $
// $Id: G4GDMLReadDefine.cc 96190 2016-03-29 08:07:36Z gcosmo $
//
// class G4GDMLReadDefine Implementation
//
@@ -299,7 +299,11 @@ G4GDMLReadDefine::PositionRead(const xercesc::DOMElement* const positionElement)
const G4String attValue = Transcode(attribute->getValue());
if (attName=="name") { name = GenerateName(attValue); } else
if (attName=="unit") { unit = G4UnitDefinition::GetValueOf(attValue); } else
if (attName=="unit") { unit = G4UnitDefinition::GetValueOf(attValue);
if (G4UnitDefinition::GetCategory(attValue)!="Length") {
G4Exception("G4GDMLReadDefine::PositionRead()", "InvalidRead",
FatalException, "Invalid unit for length!"); }
} else
if (attName=="x") { position.setX(eval.Evaluate(attValue)); } else
if (attName=="y") { position.setY(eval.Evaluate(attValue)); } else
if (attName=="z") { position.setZ(eval.Evaluate(attValue)); }
@@ -338,8 +342,12 @@ G4GDMLReadDefine::RotationRead(const xercesc::DOMElement* const rotationElement)
const G4String attValue = Transcode(attribute->getValue());
if (attName=="name") { name = GenerateName(attValue); } else
if (attName=="unit") { unit = G4UnitDefinition::GetValueOf(attValue); } else
if (attName=="x") { rotation.setX(eval.Evaluate(attValue)); } else
if (attName=="unit") { unit = G4UnitDefinition::GetValueOf(attValue);
if (G4UnitDefinition::GetCategory(attValue)!="Angle") {
G4Exception("G4GDMLReadDefine::RotationRead()", "InvalidRead",
FatalException, "Invalid unit for angle!"); }
} else
if (attName=="x") { rotation.setX(eval.Evaluate(attValue)); } else
if (attName=="y") { rotation.setY(eval.Evaluate(attValue)); } else
if (attName=="z") { rotation.setZ(eval.Evaluate(attValue)); }
}