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 10 of file Orb.h.

Constructor & Destructor Documentation

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

Definition at line 13 of file Orb.h.

References DDI::Solid::p_.

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

Definition at line 18 of file Orb.h.

18 { }

Member Function Documentation

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

Reimplemented from DDI::Solid.

Definition at line 5 of file Orb.cc.

References DDI::Solid::p_.

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

Reimplemented from DDI::Solid.

Definition at line 20 of file Orb.h.

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

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