#include <DetectorDescription/Parser/src/DDLTorus.h>
Public Member Functions | |
DDLTorus () | |
Constructor. | |
void | processElement (const std::string &name, const std::string &nmspace) |
Processing the element. | |
~DDLTorus () | |
Destructor. |
DDLTorus.h - description ------------------- begin: Fri May 25 2007 email: case@ucdhep.ucdavis.edu
Torus, same as G4Torus
Definition at line 25 of file DDLTorus.h.
DDLTorus::DDLTorus | ( | ) |
DDLTorus::~DDLTorus | ( | ) |
void DDLTorus::processElement | ( | const std::string & | name, | |
const std::string & | nmspace | |||
) | [virtual] |
Processing the element.
The processElement method completes any necessary work to process the XML element.
For example, this can be used to call the DDCore to make the geometry in memory. There is a default for this so that if not declared in the inheriting class, no processing is done.
Reimplemented from DDXMLElement.
Definition at line 45 of file DDLTorus.cc.
References DCOUT_V, ExprEvalInterface::eval(), DDXMLElement::getAttributeSet(), DDXMLElement::getDDName(), DDI::Singleton< I >::instance(), DDLSolid::setReference(), and DDSolidFactory::torus().
00046 { 00047 DCOUT_V('P', "DDLTorus::processElement started"); 00048 00049 ExprEvalInterface & ev = ExprEvalSingleton::instance(); 00050 DDXMLAttribute atts = getAttributeSet(); 00051 00052 DDSolid myTorus = 00053 DDSolidFactory::torus(getDDName(nmspace) 00054 , ev.eval(nmspace, atts.find("innerRadius")->second) 00055 , ev.eval(nmspace, atts.find("outerRadius")->second) 00056 , ev.eval(nmspace, atts.find("torusRadius")->second) 00057 , ev.eval(nmspace, atts.find("startPhi")->second) 00058 , ev.eval(nmspace, atts.find("deltaPhi")->second) 00059 ); 00060 DDLSolid::setReference(nmspace); 00061 00062 DCOUT_V('P', "DDLTorus::processElement completed"); 00063 }