CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
DDLSolid.cc
Go to the documentation of this file.
1 /***************************************************************************
2  DDLSolid.cc - description
3  -------------------
4  begin : Wed Oct 3 2002
5  email : case@ucdhep.ucdavis.edu
6  ***************************************************************************/
7 
8 /***************************************************************************
9  * *
10  * DDDParser sub-component of DDD *
11  * *
12  ***************************************************************************/
13 
15 
17 
19  : DDXMLElement( myreg )
20 {}
21 
23 {}
24 
25 void
27 {
28  // in case it was a BooleanSolid or a ReflectionSolid, clear rSolid.
29  DDXMLElement* myrSolid = myRegistry_->getElement("rSolid");
30  myrSolid->clear();
31 
32  // Make sure Solid elements are in LogicalPart elements.
33  if (parent() == "LogicalPart")
34  {
35  DDXMLElement* refsol = myRegistry_->getElement("rSolid");
36  std::vector<std::string> names;
37  std::vector<std::string> values;
38  names.push_back("name");
39  values.push_back(getAttributeSet().find("name")->second);
40  refsol->loadAttributes("rSolid", names, values, nmspace, cpv);
41  }
42 
43  // clear THIS solid's values.
44  clear();
45 
46  DCOUT_V('P', "DDLSolid::setReference completed");
47 }
DDLElementRegistry * myRegistry_
Definition: DDXMLElement.h:186
static const HistoName names[]
virtual ~DDLSolid(void)
Destructor.
Definition: DDLSolid.cc:22
virtual const DDXMLAttribute & getAttributeSet(size_t aIndex=0) const
Get a &quot;row&quot; of attributes, i.e. one attribute set.
Definition: DDXMLElement.cc:79
const std::string & parent(void) const
access to parent element name
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:7
type of data representation of DDCompactView
Definition: DDCompactView.h:77
U second(std::pair< T, U > const &p)
DDXMLElement * getElement(const std::string &name)
THE most important part. Getting the pointer to a given element type.
void loadAttributes(const std::string &elemName, const std::vector< std::string > &names, const std::vector< std::string > &values, const std::string &nmspace, DDCompactView &cpv)
Load the element attributes.
Definition: DDXMLElement.cc:41
#define DCOUT_V(M_v_Y, M_v_S)
Definition: DDdebug.h:54
DDLSolid(DDLElementRegistry *myreg)
Constructor.
Definition: DDLSolid.cc:18
This is a base class for processing XML elements in the DDD.
Definition: DDXMLElement.h:58
The main class for processing parsed elements.
virtual void clear(void)
clear this element&#39;s contents.
Definition: DDXMLElement.cc:61
void setReference(const std::string &nmspace, DDCompactView &cpv)
Definition: DDLSolid.cc:26