1 // Copyright (C) 2007-2016 CEA/DEN, EDF R&D, OPEN CASCADE
3 // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
6 // This library is free software; you can redistribute it and/or
7 // modify it under the terms of the GNU Lesser General Public
8 // License as published by the Free Software Foundation; either
9 // version 2.1 of the License, or (at your option) any later version.
11 // This library is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 // Lesser General Public License for more details.
16 // You should have received a copy of the GNU Lesser General Public
17 // License along with this library; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
23 #ifndef _BlockFix_BlockFixAPI_HeaderFile
24 #define _BlockFix_BlockFixAPI_HeaderFile
26 #include <Standard.hxx>
27 #include <Standard_DefineHandle.hxx>
29 #include <ShapeBuild_ReShape.hxx>
30 #include <TopoDS_Shape.hxx>
31 #include <Standard_Real.hxx>
32 #include <MMgt_TShared.hxx>
34 #include <Basics_OCCTVersion.hxx>
36 DEFINE_STANDARD_HANDLE(BlockFix_BlockFixAPI, MMgt_TShared);
38 class BlockFix_BlockFixAPI : public MMgt_TShared
41 Standard_EXPORT BlockFix_BlockFixAPI();
42 Standard_EXPORT ~BlockFix_BlockFixAPI();
44 void SetShape(const TopoDS_Shape& Shape);
45 TopoDS_Shape Shape() const;
46 Handle(ShapeBuild_ReShape)& Context();
47 Standard_Real& Tolerance();
48 Standard_Integer& OptimumNbFaces();
49 Standard_EXPORT void Perform();
51 OCCT_DEFINE_STANDARD_RTTIEXT(BlockFix_BlockFixAPI,MMgt_TShared)
54 Handle(ShapeBuild_ReShape) myContext;
56 Standard_Real myTolerance;
57 Standard_Integer myOptimumNbFaces;
60 //=======================================================================
63 //=======================================================================
64 inline void BlockFix_BlockFixAPI::SetShape(const TopoDS_Shape& Shape)
69 //=======================================================================
72 //=======================================================================
73 inline TopoDS_Shape BlockFix_BlockFixAPI::Shape() const
78 //=======================================================================
81 //=======================================================================
82 inline Handle(ShapeBuild_ReShape)& BlockFix_BlockFixAPI::Context()
87 //=======================================================================
88 //function : Tolerance
90 //=======================================================================
91 inline Standard_Real& BlockFix_BlockFixAPI::Tolerance()
96 //=======================================================================
97 //function : OptimumNbFaces
99 //=======================================================================
100 inline Standard_Integer& BlockFix_BlockFixAPI::OptimumNbFaces()
102 return myOptimumNbFaces;