cgma
Body.hpp
Go to the documentation of this file.
00001 /*-------------------------------------------------------------------------
00002  * Filename      : Body.hpp
00003  *
00004  * Purpose       : This class represents the topological entity, Body,
00005  *                 which is the highest level abstraction for a complete
00006  *                 geometric model.
00007  *
00008  * Special Notes : Body is a GroupingEntity in the TopologyEntity hierarchy.
00009  *                 It is also a RefEntity and get a lot of its functionality
00010  *                 and data from the RefEntity base class for meshing
00011  *                 purposes.
00012  *
00013  *                 The user is provided a handle to Bodies.
00014  *
00015  * Creator       : 
00016  *
00017  * Creation Date : 
00018  *
00019  * Owner         : 
00020  *-------------------------------------------------------------------------
00021  */
00022 
00023 #ifndef BODY_HPP
00024 #define BODY_HPP
00025 
00026 #include "GroupingEntity.hpp"
00027 #include "RefEntity.hpp"
00028 #include "CoVolume.hpp"
00029 #include "RefVolume.hpp"
00030 
00031 class CubitTransformMatrix;
00032 
00034 class CUBIT_GEOM_EXPORT Body : public GroupingEntity,
00035              public RefEntity
00036 {
00037 public :
00038 
00039   /*- the factory is allowed to call the (private) constructors */
00040   friend class RefEntityFactory;
00041 
00042     /* constructors/destructors */
00043 
00044   virtual ~Body() ;
00045   /*- The destructor. */
00046 
00047     /* topology */
00048   
00050   DagType dag_type() const { return DagType::body_type(); }
00051 
00052   void get_parent_ref_entities(DLIList<RefEntity*>& entity_list) { entity_list.clean_out(); }
00053 
00055   const std::type_info& entity_type_info() const { return typeid(Body); }
00056 
00058   static const char* get_class_name()
00059      {
00060        return "Body";
00061      }
00062 
00064   virtual const char* class_name() const
00065      {
00066        return get_class_name();
00067      }
00068   
00070   BodySM* get_body_sm_ptr() const;
00071 
00073   virtual CubitBox bounding_box();
00074 
00076   virtual CubitVector center_point();
00077 
00079   CubitBoolean get_mass_props(CubitVector& cofg);
00080        
00083   CubitPointContainment point_containment( CubitVector &point );
00084   
00086   virtual double measure();
00087 
00089   CubitBoolean is_sheet_body();
00090 
00092   virtual int validate();
00093   
00095   virtual CubitString measure_label();
00096 
00098   virtual void color(int value);
00100   virtual int color() const;
00101 
00102 protected: 
00103 
00104   Body() ;
00105   /*- The default constructor.
00106    */
00107 
00108   Body(BodySM* OSMEPtr) ;
00109   /*- The constructor with a pointer to an other solid model entity.
00110    */
00111 
00112 private:
00113    
00114   Body( const Body& );
00115   void operator=( const Body& );
00116 
00117 } ;
00118 
00119 #endif
00120 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines