CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions
DDI::Orb Class Reference

#include <Orb.h>

Inheritance diagram for DDI::Orb:
DDI::Solid

Public Member Functions

 Orb (double rMax)
 
void stream (std::ostream &os) const
 
double volume () const
 
 ~Orb ()
 
- Public Member Functions inherited from DDI::Solid
const std::vector< double > & parameters () const
 
void setParameters (std::vector< double > const &p)
 
DDSolidShape shape () const
 
 Solid ()
 
 Solid (DDSolidShape shape)
 
virtual ~Solid ()
 

Additional Inherited Members

- Protected Attributes inherited from DDI::Solid
std::vector< double > p_
 
DDSolidShape shape_
 

Detailed Description

Definition at line 13 of file Orb.h.

Constructor & Destructor Documentation

DDI::Orb::Orb ( double  rMax)
inline

Definition at line 16 of file Orb.h.

References DDI::Solid::p_.

17  : Solid(ddorb)
18  {
19  p_.push_back(rMax);
20  }
Solid()
Definition: Solid.h:14
std::vector< double > p_
Definition: Solid.h:32
DDI::Orb::~Orb ( )
inline

Definition at line 21 of file Orb.h.

21 { }

Member Function Documentation

void DDI::Orb::stream ( std::ostream &  os) const
virtual

Reimplemented from DDI::Solid.

Definition at line 8 of file Orb.cc.

References DDI::Solid::p_.

9 {
10  os << " radius[cm]=" << p_[0]/cm;
11 }
std::vector< double > p_
Definition: Solid.h:32
double DDI::Orb::volume ( void  ) const
inlinevirtual

Reimplemented from DDI::Solid.

Definition at line 23 of file Orb.h.

References DDI::Solid::p_, and Geom::pi().

23 { return (4.*Geom::pi()*p_[0]*p_[0]*p_[0])/3.; }
std::vector< double > p_
Definition: Solid.h:32
constexpr double pi()
Definition: Pi.h:31