CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
DDLTorus.cc
Go to the documentation of this file.
1 
2 /***************************************************************************
3  DDLTorus.cc - description
4  -------------------
5  begin : Fri May 25 2007
6  email : case@ucdhep.ucdavis.edu
7  ***************************************************************************/
8 
9 /***************************************************************************
10  * *
11  * DDDParser sub-component of DDD *
12  * *
13  ***************************************************************************/
14 
16 
20 
22 
24  : DDLSolid( myreg )
25 {}
26 
28 {}
29 
30 // Upon encountering an end of the tag, call DDCore's Torus.
31 void
33 {
34  DCOUT_V('P', "DDLTorus::processElement started");
35 
38 
39  DDSolid myTorus =
41  ev.eval(nmspace, atts.find("innerRadius")->second),
42  ev.eval(nmspace, atts.find("outerRadius")->second),
43  ev.eval(nmspace, atts.find("torusRadius")->second),
44  ev.eval(nmspace, atts.find("startPhi")->second),
45  ev.eval(nmspace, atts.find("deltaPhi")->second));
46  DDLSolid::setReference( nmspace, cpv );
47 
48  DCOUT_V('P', "DDLTorus::processElement completed");
49 }
static DDSolid torus(const DDName &name, double rMin, double rMax, double rTorus, double startPhi, double deltaPhi)
Definition: DDSolid.cc:778
DDLElementRegistry * myRegistry_
Definition: DDXMLElement.h:186
virtual const DDXMLAttribute & getAttributeSet(size_t aIndex=0) const
Get a "row" of attributes, i.e. one attribute set.
Definition: DDXMLElement.cc:79
DDLTorus(DDLElementRegistry *myreg)
Constructor.
Definition: DDLTorus.cc:23
bool ev
type of data representation of DDCompactView
Definition: DDCompactView.h:76
~DDLTorus(void)
Destructor.
Definition: DDLTorus.cc:27
std::map< std::string, std::string > DDXMLAttribute
Definition: DDXMLElement.h:55
A DDSolid represents the shape of a part.
Definition: DDSolid.h:35
ClhepEvaluator & evaluator()
void processElement(const std::string &name, const std::string &nmspace, DDCompactView &cpv)
Processing the element.
Definition: DDLTorus.cc:32
#define DCOUT_V(M_v_Y, M_v_S)
Definition: DDdebug.h:54
DDLSolid processes Box elements.
Definition: DDLSolid.h:27
double eval(const std::string &ns, const std::string &expr)
The main class for processing parsed elements.
virtual const DDName getDDName(const std::string &defaultNS, const std::string &attname=std::string("name"), size_t aIndex=0)
Definition: DDXMLElement.cc:86
void setReference(const std::string &nmspace, DDCompactView &cpv)
Definition: DDLSolid.cc:26