Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:05:24

0001 #ifndef DDI_Solid_h
0002 #define DDI_Solid_h
0003 
0004 #include <iosfwd>
0005 #include <vector>
0006 #include "DetectorDescription/Core/interface/DDSolidShapes.h"
0007 
0008 namespace DDI {
0009 
0010   class Solid {
0011   public:
0012     Solid() : shape_(DDSolidShape::dd_not_init) {}
0013 
0014     Solid(DDSolidShape shape) : shape_(shape) {}
0015 
0016     virtual ~Solid() {}
0017 
0018     const std::vector<double> &parameters() const { return p_; }
0019 
0020     virtual double volume() const { return 0; }
0021 
0022     DDSolidShape shape() const { return shape_; }
0023 
0024     virtual void stream(std::ostream &) const;
0025 
0026     void setParameters(std::vector<double> const &p) { p_ = p; }
0027 
0028   protected:
0029     DDSolidShape shape_;
0030     std::vector<double> p_;
0031   };
0032 }  // namespace DDI
0033 
0034 #endif  // DDI_Solid_h