CMS 3D CMS Logo

List of all members | Public Member Functions
DDHtmlRoDetails Class Reference

#include <DDHtmlFormatter.h>

Inheritance diagram for DDHtmlRoDetails:
DDHtmlDetails

Public Member Functions

 DDHtmlRoDetails (const std::string &cat, const std::string &txt)
 
bool details (std::ostream &os, const DDName &) override
 
ns_typenames () override
 
- Public Member Functions inherited from DDHtmlDetails
const std::string & category ()
 
 DDHtmlDetails (const std::string &cat, const std::string &txt)
 
const std::string & text ()
 
virtual ~DDHtmlDetails ()
 

Additional Inherited Members

- Protected Attributes inherited from DDHtmlDetails
std::string cat_
 
DDHtmlFormatter f_
 
ns_type names_
 
std::string txt_
 

Detailed Description

Definition at line 184 of file DDHtmlFormatter.h.

Constructor & Destructor Documentation

◆ DDHtmlRoDetails()

DDHtmlRoDetails::DDHtmlRoDetails ( const std::string &  cat,
const std::string &  txt 
)
inline

Definition at line 186 of file DDHtmlFormatter.h.

186 : DDHtmlDetails(cat, txt) {}

Member Function Documentation

◆ details()

bool DDHtmlRoDetails::details ( std::ostream &  os,
const DDName  
)
overridevirtual

Implements DDHtmlDetails.

Definition at line 129 of file DDHtmlFormatter.cc.

129  {
130  os << f_.header("Rotations Details");
131 
132  DDRotation ddr(nm);
133  if (ddr.isDefined().second == false) {
134  os << "<b>ERROR!</b><br><p>The Rotation " << nm << " is not defined!</p>" << endl;
135  return false;
136  }
137  DD3Vector x, y, z;
138  ddr.matrix().GetComponents(x, y, z);
139  os << f_.h2("Rotation: " + nm.fullname());
140  os << f_.h3("GEANT3 style:");
141  os << "<table border=\"0\">" << endl
142  << "<tr><td>thetaX =</td><td>" << convertRadToDeg(x.Theta()) << " deg</td><tr>" << endl
143  << "<tr><td>phiX =</td><td>" << convertRadToDeg(x.Phi()) << " deg</td><tr>" << endl
144  << "<tr><td>thetaY =</td><td>" << convertRadToDeg(y.Theta()) << " deg</td><tr>" << endl
145  << "<tr><td>phiY =</td><td>" << convertRadToDeg(y.Phi()) << " deg</td><tr>" << endl
146  << "<tr><td>thetaZ =</td><td>" << convertRadToDeg(z.Theta()) << " deg</td><tr>" << endl
147  << "<tr><td>phiZ =</td><td>" << convertRadToDeg(z.Phi()) << " deg</td><tr>" << endl
148  << "</table>";
149 
150  os << f_.h3("Rotation axis & angle (theta,phi,angle)") << endl;
151  os << DDRotation(nm);
152  return true;
153 }

References angle_units::operators::convertRadToDeg(), DDHtmlDetails::f_, DDName::fullname(), DDHtmlFormatter::h2(), DDHtmlFormatter::h3(), DDHtmlFormatter::header(), DDBase< N, C >::isDefined(), DDRotation::matrix(), x, y, and z.

◆ names()

ns_type & DDHtmlRoDetails::names ( void  )
overridevirtual

Implements DDHtmlDetails.

Definition at line 111 of file DDHtmlFormatter.cc.

111  {
112  DDRotation lp;
113  findNameSpaces(lp, names_);
114  return names_;
115 }

References findNameSpaces(), and DDHtmlDetails::names_.

DDHtmlFormatter::h3
DDHtmlFormatter h3(const std::string &content)
Definition: DDHtmlFormatter.h:64
DDAxes::y
angle_units::operators::convertRadToDeg
constexpr NumType convertRadToDeg(NumType radians)
Definition: angle_units.h:21
eostools.cat
def cat(path)
Definition: eostools.py:401
DDAxes::x
findNameSpaces
bool findNameSpaces(T dummy, ns_type &m)
Definition: DDErrorDetection.h:68
DDAxes::z
DD3Vector
ROOT::Math::DisplacementVector3D< ROOT::Math::Cartesian3D< double > > DD3Vector
Definition: PGeometricDetBuilder.cc:19
DDHtmlDetails::DDHtmlDetails
DDHtmlDetails(const std::string &cat, const std::string &txt)
Definition: DDHtmlFormatter.cc:85
DDHtmlFormatter::header
DDHtmlFormatter header(const std::string &text, const std::string &style="../../style.css")
Definition: DDHtmlFormatter.cc:40
DDHtmlDetails::names_
ns_type names_
Definition: DDHtmlFormatter.h:158
DDHtmlFormatter::h2
DDHtmlFormatter h2(const std::string &content)
Definition: DDHtmlFormatter.h:59
DDRotation
Represents a uniquely identifyable rotation matrix.
Definition: DDTransform.h:57
DDHtmlDetails::f_
DDHtmlFormatter f_
Definition: DDHtmlFormatter.h:160
DDRotation
ROOT::Math::Rotation3D DDRotation
Definition: DDEcalEndcapAlgo.cc:18