1 // File: ShHealOper_RemoveFace.hxx
2 // Created: 15.04.04 18:10:16
3 // Author: Galina KULIKOVA
4 // < MODULE = KERNEL> <PACKAGE = ShHealOper> : <Shape Healing Operations>
5 // Copyright (C) 2003 CEA
7 // This library is free software; you can redistribute it and/or
8 // modify it under the terms of the GNU Lesser General Public
9 // License as published by the Free Software Foundation; either
10 // version 2.1 of the License.
13 // This library is distributed in the hope that it will be useful,
14 // but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 // Lesser General Public License for more details.
18 // You should have received a copy of the GNU Lesser General Public
19 // License along with this library; if not, write to the Free Software
20 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
25 #ifndef ShHealOper_RemoveFace_HeaderFile
26 #define ShHealOper_RemoveFace_HeaderFile
28 #include <MMgt_TShared.hxx>
29 #include <ShHealOper_Tool.hxx>
30 #include <TopoDS_Shape.hxx>
31 #include <TopTools_SequenceOfShape.hxx>
32 #include <TopTools_MapOfShape.hxx>
33 #include <TopoDS_Solid.hxx>
34 #include <TopoDS_Shell.hxx>
35 #include <TopoDS_Face.hxx>
36 #include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
37 /// Class ShHealOper_RemoveFace
38 //Class intended to removing faces from shape.
40 class ShHealOper_RemoveFace : public ShHealOper_Tool
43 // ---------- PUBLIC METHODS ----------
45 Standard_EXPORT ShHealOper_RemoveFace ();
48 Standard_EXPORT ShHealOper_RemoveFace (const TopoDS_Shape& theShape);
49 // Constructor initialized by shape from which faces will be removed.
50 Standard_EXPORT virtual void Init(const TopoDS_Shape& theShape);
51 //Method for initalization by whole shape.
52 Standard_EXPORT Standard_Boolean Perform();
53 //Removes all faces from specified shape.
55 Standard_EXPORT Standard_Boolean Perform(const TopTools_SequenceOfShape& theRemovedFaces);
56 //Removes faces specified in the sequence of faces from specified shape.
61 Standard_Boolean removeFaces(const TopoDS_Shape& theShape,TopoDS_Shape& theNewShape);
62 Standard_Boolean removeFaces(const TopoDS_Solid& theShape,TopoDS_Shape& theNewShape);
63 Standard_Boolean removeFaces(const TopoDS_Shell& theShell,TopoDS_Shape& theNewShape);
64 Standard_Boolean isReplace(const TopoDS_Shape& theOldShape,TopoDS_Shape& theNewShape);
65 //Methods for removing faces from sub-shapes.
67 void removePCurve(const TopoDS_Face& theFace);
68 //method for removing pcurves belonging to face
70 Standard_Boolean isManifold(const TopoDS_Shell& aShell);
71 //denenes manifold shell.
73 // ---------- PRIVATE FIELDS ----------
75 TopTools_MapOfShape myMapFaces;
76 TopTools_IndexedDataMapOfShapeListOfShape myMapEdgesFace;
78 // Declaration of CASCADE RTTI
79 //DEFINE_STANDARD_RTTI (ShHealOper_RemoveFace)
82 // Definition of HANDLE object using Standard_DefineHandle.hxx
83 //DEFINE_STANDARD_HANDLE (ShHealOper_RemoveFace, )