1 // Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
2 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
4 // This library is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU Lesser General Public
6 // License as published by the Free Software Foundation; either
7 // version 2.1 of the License.
9 // This library is distributed in the hope that it will be useful
10 // but WITHOUT ANY WARRANTY; without even the implied warranty of
11 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 // Lesser General Public License for more details.
14 // You should have received a copy of the GNU Lesser General Public
15 // License along with this library; if not, write to the Free Software
16 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 #ifndef _GEOMAlgo_WESCorrector_HeaderFile
21 #define _GEOMAlgo_WESCorrector_HeaderFile
23 #ifndef _GEOMAlgo_PWireEdgeSet_HeaderFile
24 #include <GEOMAlgo_PWireEdgeSet.hxx>
26 #ifndef _GEOMAlgo_WireEdgeSet_HeaderFile
27 #include <GEOMAlgo_WireEdgeSet.hxx>
29 #ifndef _BOP_ListOfConnexityBlock_HeaderFile
30 #include <BOP_ListOfConnexityBlock.hxx>
32 #ifndef _GEOMAlgo_Algo_HeaderFile
33 #include <GEOMAlgo_Algo.hxx>
35 class GEOMAlgo_WireEdgeSet;
38 #ifndef _Standard_HeaderFile
39 #include <Standard.hxx>
41 #ifndef _Standard_Macro_HeaderFile
42 #include <Standard_Macro.hxx>
46 //! The algorithm to change the Wire Edges Set (WES) contents. <br>
47 //! The NewWES will contain only wires instead of wires and edges. <br>
48 class GEOMAlgo_WESCorrector : public GEOMAlgo_Algo {
52 void* operator new(size_t,void* anAddress)
56 void* operator new(size_t size)
58 return Standard::Allocate(size);
60 void operator delete(void *anAddress)
62 if (anAddress) Standard::Free((Standard_Address&)anAddress);
68 //! Empty constructor; <br>
70 Standard_EXPORT GEOMAlgo_WESCorrector();
71 Standard_EXPORT virtual ~GEOMAlgo_WESCorrector();
75 Standard_EXPORT void SetWES(const GEOMAlgo_WireEdgeSet& aWES) ;
78 //! Performs the algorithm that consists of two steps <br>
79 //! 1. Make conexity blocks ( DoConnexityBlocks() ) <br>
80 //! 2. Make corrections ( DoCorrections() ) <br>
81 Standard_EXPORT virtual void Perform() ;
85 Standard_EXPORT GEOMAlgo_WireEdgeSet& WES() ;
89 Standard_EXPORT GEOMAlgo_WireEdgeSet& NewWES() ;
101 Standard_EXPORT void DoConnexityBlocks() ;
104 Standard_EXPORT void DoCorrections() ;
109 GEOMAlgo_PWireEdgeSet myWES;
110 GEOMAlgo_WireEdgeSet myNewWES;
111 BOP_ListOfConnexityBlock myConnexityBlocks;
130 // other Inline functions and methods (like "C++: function call" methods)