61 if (myrRotation->size() > 0){
62 rotn = myrRotation->getDDName(nmspace);
64 else if (myDDLRotation->size() > 0) {
69 rotn = myDDLRotation->getDDName(nmspace);
71 else if (myDDLRefl->size() > 0) {
75 rotn = myDDLRefl->getDDName(nmspace);
77 else if (myrRefl->size() > 0) {
78 rotn = myrRefl->getDDName(nmspace);
83 double x = 0.0,
y = 0.0,
z = 0.0;
84 if (myTranslation->size() > 0)
87 x = ev.
eval(nmspace, atts.find(
"x")->second);
88 y = ev.
eval(nmspace, atts.find(
"y")->second);
89 z = ev.
eval(nmspace, atts.find(
"z")->second);
92 std::unique_ptr<DDRotation> myDDRotation;
94 if ( rotn.
name() !=
"" && rotn.
ns() !=
"" ) {
95 myDDRotation = std::make_unique<DDRotation>(rotn);
100 if ( !myDDRotation->isValid() ) {
110 if (atts.find(
"copyNumber") != atts.end())
111 copyno = atts.find(
"copyNumber")->second;
122 myTranslation->clear();
123 myDDLRotation->clear();
124 myrRotation->clear();
void preProcessElement(const std::string &name, const std::string &nmspace, DDCompactView &cpv) override
Called by loadAttributes AFTER attributes are loaded.
DDLElementRegistry * myRegistry_
virtual const DDXMLAttribute & getAttributeSet(size_t aIndex=0) const
Get a "row" of attributes, i.e. one attribute set.
const std::string & ns() const
Returns the namespace.
DDName is used to identify DDD entities uniquely.
type of data representation of DDCompactView
std::map< std::string, std::string > DDXMLAttribute
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DDTranslation
ClhepEvaluator & evaluator()
void processElement(const std::string &name, const std::string &nmspace, DDCompactView &cpv) override
Processing the element.
DDLPosPart(DDLElementRegistry *myreg)
std::shared_ptr< DDXMLElement > getElement(const std::string &name)
THE most important part. Getting the pointer to a given element type.
A DDLogicalPart aggregates information concerning material, solid and sensitveness ...
This is a base class for processing XML elements in the DDD.
void position(const DDLogicalPart &self, const DDLogicalPart &parent, const std::string ©no, const DDTranslation &trans, const DDRotation &rot, const DDDivision *div=0)
double eval(const std::string &ns, const std::string &expr)
The main class for processing parsed elements.
virtual void clear(void)
clear this element's contents.
ROOT::Math::Rotation3D DDRotationMatrix
A DDRotationMatrix is currently implemented with a ROOT Rotation3D.
const std::string & name() const
Returns the name.