cgma
OCCLoop.hpp
Go to the documentation of this file.
00001 //-------------------------------------------------------------------------
00002 // Filename      : OCCLoop.hpp
00003 //
00004 // Purpose       : 
00005 //
00006 // Special Notes :
00007 //
00008 // Creator       : Jane Hu 
00009 //
00010 // Creation Date : 11/16/07
00011 //
00012 // Owner         : 
00013 //-------------------------------------------------------------------------
00014 
00015 #ifndef LOOP_OCC_HPP
00016 #define LOOP_OCC_HPP
00017 
00018 #include "CubitDefines.h"
00019 #include "CubitEntity.hpp"
00020 #include "LoopSM.hpp"
00021 #include "DLIList.hpp"
00022 #include "OCCCoEdge.hpp"
00023 #include "TopoDS_Wire.hxx"
00024 
00025 class GeometryEntity;
00026 
00027 class OCCBody;
00028 class OCCLump;
00029 class OCCShell;
00030 class OCCSurface;
00031 class OCCCoEdge;
00032 class OCCCurve;
00033 class OCCPoint;
00034 class BRepBuilderAPI_ModifyShape;
00035 class BRepAlgoAPI_BooleanOperation;
00036 class LocOpe_SplitShape;
00037 class OCCLoop : public LoopSM
00038 {
00039 public :
00040  
00041   OCCLoop( TopoDS_Wire *theLoop );  
00042 
00043   void coedges(DLIList<OCCCoEdge *> coedges) {myCoEdgeList = coedges;}
00044 
00045   DLIList<OCCCoEdge*> coedges() {return myCoEdgeList;}
00046 
00047   OCCCoEdge* remove_coedge(OCCCoEdge *coedge);
00048 
00049   void disconnect_all_curves();
00050 
00051   inline TopoDS_Wire* get_TopoDS_Wire() {return myTopoDSWire;}
00052   void set_TopoDS_Wire(TopoDS_Wire loop);
00053 
00054   virtual LoopType loop_type(){return LOOP_TYPE_UNKNOWN;};
00055 
00056   virtual ~OCCLoop() ;
00057     //- The destructor
00058   
00059   virtual CubitBox bounding_box() const ;
00060     // see comments in GeometryEntity.hpp
00061   
00062   virtual GeometryQueryEngine* 
00063   get_geometry_query_engine() const;
00064     //R GeometryQueryEngine*
00065     //R- A pointer to the geometric modeling engine associated with
00066     //R- the object.
00067     //- This function returns a pointer to the geometric modeling engine
00068     //- associated with the object.
00069 
00070   virtual void append_simple_attribute_virt(const CubitSimpleAttrib&);
00071     //R void
00072     //I
00073     //I-
00074     //I- that is to be appended to this OSME object.
00075     //- The purpose of this function is to append a
00076     //- attribute to the OSME. The  is attached to each of the
00077     //- underlying solid model entities this one points to.
00078 
00079   virtual void remove_simple_attribute_virt(const CubitSimpleAttrib&);
00080     //R void
00081     //I CubitSimpleAttrib*
00082     //I- A reference to a CubitSimpleAttrib object which is the object
00083     //I- that is to be removed to this OSME object.
00084     //- The purpose of this function is to remove a simple
00085     //- attribute from the OSME. The attribute is attached to each of the
00086     //- underlying solid model entities this one points to.
00087 
00088   virtual void remove_all_simple_attribute_virt();
00089     //R void
00090     //I-
00091     //- The purpose of this function is to remove all simple
00092     //- attributes from the OSME.
00093 
00094   virtual CubitStatus get_simple_attribute(DLIList<CubitSimpleAttrib>&);
00095   virtual CubitStatus get_simple_attribute(const CubitString& name,
00096                                            DLIList<CubitSimpleAttrib>&);
00097     //R CubitSimpleAttrib*
00098     //R- the returned cubit simple attribute.
00099     //- The purpose of this function is to get the attributes
00100     //- of the geometry entity. The name is attached to the underlying solid
00101     //- model entity(ies) this one points to.
00102     //- MJP Note:
00103     //- This is the code that implements the requirement that names
00104     //- of VGI Entities propagate across solid model boolean
00105     //- operations.  The success of this relies, of course, on the underlying
00106     //- solid modeler being able to propagate attributes across
00107     //- such operations on its entities. If it cannot, then "names"
00108     //- of VGI entities will not propagate.
00109  
00110     virtual void get_parents_virt(DLIList<TopologyBridge*>&);
00111     virtual void get_children_virt(DLIList<TopologyBridge*>&);
00112 
00113     //ModifyShape now refers only to Transform and GTransform (1/10/11)
00114     CubitStatus update_OCC_entity( BRepBuilderAPI_ModifyShape *aBRepTrsf,
00115                                    BRepAlgoAPI_BooleanOperation *op =NULL);
00116     static CubitStatus update_OCC_entity(TopoDS_Wire & old_loop,
00117                                   LocOpe_SplitShape* sp);
00118 protected: 
00119 
00120 private:
00121   TopoDS_Wire *myTopoDSWire;
00122   DLIList<OCCCoEdge *> myCoEdgeList;
00123 
00124 };
00125 
00126 
00127 // ********** BEGIN INLINE FUNCTIONS       **********
00128 // ********** END INLINE FUNCTIONS         **********
00129 
00130 // ********** BEGIN FRIEND FUNCTIONS       **********
00131 // ********** END FRIEND FUNCTIONS         **********
00132 
00133 // ********** BEGIN EXTERN FUNCTIONS       **********
00134 // ********** END EXTERN FUNCTIONS         **********
00135 
00136 #endif
00137 
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines