-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo.cdl
-- Created: Sat Dec 04 12:36:22 2004
-- Author: Peter KURNEV
-- <peter@PREFEX>
----Copyright: Matra Datavision 2004
-
package GEOMAlgo
uses
TCollection,
- TColStd,
+
+ TColgp,
Geom,
Bnd,
gp,
TopTools,
IntTools,
BOPTools,
- BOP
-
+ BOP,
+ --||
+ TColStd,
+ BOPTColStd,
+ BRepAlgo,
+ NMTDS,
+ NMTTools
+ --||
+
is
- -- enumerations
+ --
+ -- enumerations
--
enumeration State is
ST_UNKNOWN,
--
-- classes
--
- deferred class Algo;
- deferred class ShapeAlgo;
+ deferred class Algo;
+ deferred class ShapeAlgo;
--
-- gluer
class Gluer;
class PassKeyShape;
class SurfaceTools;
class Tools;
-
--
-- finder on
deferred class ShapeSolid;
class FinderShapeOn1;
class StateCollector;
--
+ -- Builder/Splitter
+ deferred class BuilderShape;
+
+ class Builder;
+ class Splitter;
+ class Tools3D;
+ class BuilderTools;
+ class ShapeSet;
+
+ deferred class BuilderArea;
+ class BuilderFace;
+ class BuilderSolid;
+
+ class WireSplitter;
+ class WireEdgeSet;
+ class WESCorrector;
+ --
+ -- Pointers
+ --
+ pointer PWireEdgeSet to WireEdgeSet from GEOMAlgo;
+ --
+ --
+ -- Instantiations
+ class DataMapOfShapeShapeSet instantiates
+ DataMap from TCollection(Shape from TopoDS,
+ ShapeSet from GEOMAlgo,
+ ShapeMapHasher from TopTools);
+
+ class DataMapOfShapeReal instantiates
+ DataMap from TCollection(Shape from TopoDS,
+ Real from Standard,
+ ShapeMapHasher from TopTools);
+
+
+ class DataMapOfRealListOfShape instantiates
+ DataMap from TCollection(Real from Standard,
+ ListOfShape from TopTools,
+ MapRealHasher from TColStd);
+ --
-- instantiations
class IndexedDataMapOfPassKeyShapeListOfShape
instantiates IndexedDataMap from TCollection (PassKeyShape from GEOMAlgo,
instantiates IndexedDataMap from TCollection (Shape from TopoDS,
State from TopAbs,
ShapeMapHasher from TopTools);
---
class ListOfPnt
instantiates List from TCollection (Pnt from gp);
--- class IndexedDataMapOfPassKeyInteger
--- instantiates IndexedDataMap from TCollection (PassKeyRoot from GEOMAlgo,
--- Integer from Standard,
--- PassKeyMapHasher from GEOMAlgo);
-
+
class DataMapOfPassKeyInteger
instantiates DataMap from TCollection (PassKey from GEOMAlgo,
Integer from Standard,
PassKeyMapHasher from GEOMAlgo);
-
-
end GEOMAlgo;
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_Algo.cdl
-- Created: Sat Dec 04 12:37:56 2004
-- Author: Peter KURNEV
-- <peter@PREFEX>
----Copyright: Matra Datavision 2004
deferred class Algo from GEOMAlgo
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_Algo {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT virtual void Perform() = 0;
+
+
Standard_EXPORT Standard_Integer ErrorStatus() const;
+
+
Standard_EXPORT Standard_Integer WarningStatus() const;
// Methods PROTECTED
//
+
+
Standard_EXPORT GEOMAlgo_Algo();
Standard_EXPORT virtual ~GEOMAlgo_Algo();
+
+
Standard_EXPORT virtual void CheckData() ;
+
+
Standard_EXPORT virtual void CheckResult() ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _GEOMAlgo_Algo_HeaderFile
#include <GEOMAlgo_Algo.hxx>
#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_Builder.cdl
+-- Created:
+-- Author: Peter KURNEV
+
+
+class Builder from GEOMAlgo
+ inherits BuilderShape from GEOMAlgo
+
+ ---Purpose:
+
+uses
+ ShapeEnum from TopAbs,
+ Shape from TopoDS,
+
+ ListOfShape from TopTools,
+ IndexedDataMapOfShapeListOfShape from TopTools,
+ IndexedDataMapOfShapeShape from TopTools,
+ MapOfShape from TopTools,
+ Image from BRepAlgo,
+
+ DSFiller from NMTTools,
+ PDSFiller from NMTTools
+
+--raises
+
+is
+
+ Create
+ ---Purpose: Empty constructor
+ returns Builder from GEOMAlgo;
+ ---C++: alias "Standard_EXPORT virtual ~GEOMAlgo_Builder();"
+
+ Perform(me:out)
+ ---Purpose: Performs calculations
+ is redefined;
+
+ PerformWithFiller(me:out;
+ theDSF: DSFiller from NMTTools)
+ ---Purpose: Performs calculations using prepared DSFiller
+ -- object theDSF
+ is virtual;
+
+ AddShape (me:out;
+ theShape: Shape from TopoDS)
+ ---Purpose: Adds argument theShape of the operation
+ is virtual;
+
+ Clear(me:out)
+ ---Purpose: Clears internal fields and arguments
+ is virtual;
+
+ Shapes(me)
+ ---Purpose: Returns the arguments of the operation
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+ --
+ -- History support
+ --
+ Generated (me:out;
+ theS : Shape from TopoDS)
+ ---Purpose: Returns the list of shapes generated from the
+ -- shape theS.
+ returns ListOfShape from TopTools
+ is redefined;
+ ---C++: return const &
+
+ Modified (me:out;
+ theS : Shape from TopoDS)
+ ---Purpose: Returns the list of shapes modified from the shape
+ -- theS.
+ returns ListOfShape from TopTools
+ is redefined;
+ ---C++: return const &
+
+ IsDeleted (me:out;
+ theS : Shape from TopoDS)
+ ---Purpose: Returns true if the shape theS has been deleted.
+ returns Boolean from Standard
+ is redefined;
+ --
+ -- protected methods
+ --
+ PrepareHistory (me:out)
+ ---Purpose: Prepare information for history support
+ is redefined protected;
+
+ ClearInternals(me:out)
+ ---Purpose: Clears internal fields
+ is virtual protected;
+
+ Prepare(me:out)
+ ---Purpose: Provides preparing actions
+ is virtual protected;
+
+ PostTreat(me:out)
+ ---Purpose: Provides post-tratment actions
+ is virtual protected;
+
+ AddShape1 (me:out;
+ theShape: Shape from TopoDS)
+ ---Purpose: Append the argument theShape to
+ -- typified lists of arguments myShapes1
+ is protected;
+
+ BuildResult(me:out;
+ theType: ShapeEnum from TopAbs)
+ ---Purpose: Build the resulting shapes of type theType
+ is virtual protected;
+
+ -- Vertices
+ FillImagesVertices(me:out)
+ ---Purpose: Fill Images for vertices
+ is protected;
+
+ -- Edges
+ FillImagesEdges(me:out)
+ ---Purpose: Fill Images for edges
+ is protected;
+ --
+ -- Faces
+ FillImagesFaces(me:out)
+ ---Purpose: Fill Images for faces
+ is protected;
+
+ FillIn2DParts(me:out)
+ ---Purpose: For each interferred face find split edges
+ -- that are in 2-D domain of the face
+ is protected;
+
+ BuildSplitFaces(me:out)
+ ---Purpose: Build draft faces
+ is protected;
+
+ FillSameDomainFaces(me:out)
+ ---Purpose: Among draft faces find same domain faces
+ is protected;
+
+ FillImagesFaces1(me:out)
+ ---Purpose: Fill Images for faces
+ -- taking into account same domain faces
+ is protected;
+
+ FillInternalVertices(me:out)
+ ---Purpose: Update Images for faces by
+ -- internal vertices
+ is protected;
+ --
+ -- Wires, Shells, Compsolids, Compounds
+ FillImagesContainers(me:out;
+ theType:ShapeEnum from TopAbs)
+ ---Purpose: Fill Images for Wires, Shells, Compsolids, Compounds
+ is protected;
+ --
+ -- Solids
+ FillImagesSolids(me:out)
+ ---Purpose: Fill Images for solids
+ is protected;
+
+ FillIn3DParts(me:out)
+ ---Purpose: For each interferred solid find split faces
+ -- that are in 3-D domain of the solid
+ is protected;
+
+ BuildSplitSolids(me:out)
+ ---Purpose: Build draft solids
+ is protected;
+
+ FillInternalShapes(me:out)
+ ---Purpose: Update draft solids by
+ -- internal shells, edges, vertices
+ is protected;
+
+ BuildDraftSolid(me:out;
+ theSolid: Shape from TopoDS;
+ theDraftSolid: out Shape from TopoDS;
+ theInternalFaces: out ListOfShape from TopTools)
+ ---Purpose: Build solid theDraftSolid that consists of
+ -- non-internal split faces of the solid
+ -- theSolid.
+ -- All splits of internal faces of
+ -- theSolid are in the list: theInternalFaces
+ is protected;
+ --
+ -- debug methods
+ --
+ AddCompound (me:out;
+ theShape: Shape from TopoDS);
+ ---Purpose: Adds arguments of the operation as
+ -- shapes of upper level of container shape theShape
+ Shapes1(me;
+ theType: Integer from Standard)
+ ---Purpose: Returns list of arguments of type theType
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+ Images(me)
+ ---Purpose: Returns image shapes
+ returns Image from BRepAlgo;
+ ---C++: return const &
+
+ InParts(me;
+ theShape:Shape from TopoDS)
+ ---Purpose: Returns split-parts of shapes that have
+ -- state IN for the domain of shape theShape
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+ -- =====================================================
+
+fields
+ myDSFiller : PDSFiller from NMTTools is protected;
+ myShapes : ListOfShape from TopTools is protected;
+ -- Common usage
+ myNbTypes : Integer from Standard is protected;
+ myMapFence : MapOfShape from TopTools is protected;
+ myShapes1 : ListOfShape from TopTools[9] is protected;
+ myImages : Image from BRepAlgo is protected;
+ myInParts : IndexedDataMapOfShapeListOfShape from TopTools is protected;
+
+ -- Faces
+ mySplitFaces : Image from BRepAlgo is protected;
+ mySameDomainShapes: IndexedDataMapOfShapeShape from TopTools is protected;
+ -- solids
+ myDraftSolids : IndexedDataMapOfShapeShape from TopTools is protected;
+
+ --
+end Builder;
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_Builder.cxx
+// Created:
+// Author: Peter KURNEV
+
+
+#include <GEOMAlgo_Builder.ixx>
+
+#include <TopAbs_ShapeEnum.hxx>
+
+#include <TopoDS_Shape.hxx>
+#include <TopoDS_Compound.hxx>
+#include <TopoDS_Iterator.hxx>
+
+#include <BRep_Builder.hxx>
+
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+
+#include <BOP_CorrectTolerances.hxx>
+
+#include <NMTTools_DSFiller.hxx>
+
+#include <BRepLib.hxx>
+
+//=======================================================================
+//function :
+//purpose :
+//=======================================================================
+ GEOMAlgo_Builder::GEOMAlgo_Builder()
+:
+ GEOMAlgo_BuilderShape()
+{
+ myNbTypes=9;
+ myDSFiller=NULL;
+}
+//=======================================================================
+//function : ~
+//purpose :
+//=======================================================================
+ GEOMAlgo_Builder::~GEOMAlgo_Builder()
+{
+}
+//=======================================================================
+//function : AddCompound
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::AddCompound(const TopoDS_Shape& theShape)
+{
+ TopoDS_Iterator aIt;
+ //
+ aIt.Initialize(theShape);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ AddShape(aS);
+ }
+}
+//=======================================================================
+//function : AddShape
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::AddShape(const TopoDS_Shape& theShape)
+{
+ if (myMapFence.Add(theShape)) {
+ myShapes.Append(theShape);
+ }
+}
+//=======================================================================
+//function : Shapes
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_Builder::Shapes()const
+{
+ return myShapes;
+}
+//=======================================================================
+//function : Clear
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::Clear()
+{
+ myShapes.Clear();
+ ClearInternals();
+}
+//=======================================================================
+//function : ClearInternals
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::ClearInternals()
+{
+ Standard_Integer i;
+ //
+ for (i=0; i<myNbTypes; ++i){
+ myShapes1[i].Clear();
+ }
+ myImages.Clear();
+ //
+ myInParts.Clear();
+ mySplitFaces.Clear();
+ mySameDomainShapes.Clear();
+ myDraftSolids.Clear();
+ myMapFence.Clear();
+}
+//=======================================================================
+//function : Prepare
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::Prepare()
+{
+ myErrorStatus=0;
+ //
+ Standard_Integer aNb;
+ BRep_Builder aBB;
+ TopoDS_Compound aC;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ aNb=myShapes.Extent();
+ if (aNb<2) {
+ myErrorStatus=10; // No shapes to process
+ return;
+ }
+ //
+ // 1. myShape is empty compound
+ aBB.MakeCompound(aC);
+ myShape=aC;
+ //
+ // 2. myShapes1
+ aIt.Initialize(myShapes);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ AddShape1(aS);
+ }
+}
+//=======================================================================
+//function : PostTreat
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::PostTreat()
+{
+ Standard_Integer aNbS;
+ TopoDS_Iterator aIt;
+ TopTools_ListOfShape aLS;
+ //
+ aIt.Initialize(myShape);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ aLS.Append(aS);
+ }
+ aNbS=aLS.Extent();
+ if (aNbS==1) {
+ myShape=aLS.First();
+ }
+
+ BRepLib::SameParameter(myShape, 1.e-7, Standard_True);
+}
+//=======================================================================
+//function : AddShape1
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::AddShape1(const TopoDS_Shape& theShape)
+{
+ Standard_Integer iType;
+ TopAbs_ShapeEnum aType;
+ TopoDS_Iterator aIt;
+ TopTools_MapOfShape aM;
+ //
+ aType=theShape.ShapeType();
+ if (aType==TopAbs_COMPOUND) {
+ aIt.Initialize(theShape);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ AddShape1(aS);
+ }
+ }
+ //
+ iType=(Standard_Integer)aType;
+ if (aM.Add(theShape)) {
+ myShapes1[iType].Append(theShape);
+ }
+}
+//=======================================================================
+//function : BuildResult
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::BuildResult(const TopAbs_ShapeEnum theType)
+{
+ myErrorStatus=0;
+ //
+ TopAbs_ShapeEnum aType;
+ BRep_Builder aBB;
+ TopTools_MapOfShape aM;
+ TopTools_ListIteratorOfListOfShape aIt, aItIm;
+ //
+ aIt.Initialize(myShapes);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ aType=aS.ShapeType();
+ if (aType==theType) {
+ if (myImages.HasImage(aS)){
+ const TopTools_ListOfShape& aLSIm=myImages.Image(aS);
+ aItIm.Initialize(aLSIm);
+ for (; aItIm.More(); aItIm.Next()) {
+ const TopoDS_Shape& aSIm=aItIm.Value();
+ if (aM.Add(aSIm)) {
+ aBB.Add(myShape, aSIm);
+ }
+ }
+ }
+ else {
+ if (aM.Add(aS)) {
+ aBB.Add(myShape, aS);
+ }
+ }
+ }
+ }
+}
+//=======================================================================
+//function : Perform
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::Perform()
+{
+ myErrorStatus=0;
+ //
+ BRep_Builder aBB;
+ TopoDS_Compound aCS;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ aBB.MakeCompound(aCS);
+ //
+ aIt.Initialize(myShapes);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ aBB.Add(aCS, aS);
+ }
+ //
+ NMTTools_DSFiller* pDSF=new NMTTools_DSFiller;
+ //
+ pDSF->SetCompositeShape(aCS);
+ pDSF->Perform();
+ //
+ PerformWithFiller(*pDSF);
+}
+//=======================================================================
+//function : PerformWithFiller
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::PerformWithFiller(const NMTTools_DSFiller& theDSF)
+{
+ myErrorStatus=0;
+ //
+ Standard_Boolean bIsDone;
+ //
+ // 0. myDSFiller
+ myDSFiller=(NMTTools_DSFiller *)&theDSF;
+ //
+ bIsDone=myDSFiller->IsDone();
+ if (!bIsDone) {
+ myErrorStatus=2; // DSFiller is failed
+ return;
+ }
+ //
+ // 1. Clear Internal fields
+ ClearInternals();
+ //
+ // 2. Prepare
+ Prepare();
+ if (myErrorStatus) {
+ return;
+ }
+ //
+ // 3. Fill Images
+ //
+ // 3.1 Vertices
+ FillImagesVertices();
+ if (myErrorStatus) {
+ return;
+ }
+ //
+ BuildResult(TopAbs_VERTEX);
+ if (myErrorStatus) {
+ return;
+ }
+ // 3.2 Edges
+ FillImagesEdges();
+ if (myErrorStatus) {
+ return;
+ }
+
+ BuildResult(TopAbs_EDGE);
+ if (myErrorStatus) {
+ return;
+ }
+ // 3.3 Wires
+ FillImagesContainers(TopAbs_WIRE);
+ if (myErrorStatus) {
+ return;
+ }
+
+ BuildResult(TopAbs_WIRE);
+ if (myErrorStatus) {
+ return;
+ }
+
+ // 3.4 Faces
+ FillImagesFaces();
+ if (myErrorStatus) {
+ return;
+ }
+
+ BuildResult(TopAbs_FACE);
+ if (myErrorStatus) {
+ return;
+ }
+ // 3.5 Shells
+
+ FillImagesContainers(TopAbs_SHELL);
+ if (myErrorStatus) {
+ return;
+ }
+
+ BuildResult(TopAbs_SHELL);
+ if (myErrorStatus) {
+ return;
+ }
+ // 3.6 Solids
+ FillImagesSolids();
+ if (myErrorStatus) {
+ return;
+ }
+
+ BuildResult(TopAbs_SOLID);
+ if (myErrorStatus) {
+ return;
+ }
+ // 3.7 CompSolids
+ FillImagesContainers(TopAbs_COMPSOLID);
+ if (myErrorStatus) {
+ return;
+ }
+
+ BuildResult(TopAbs_COMPSOLID);
+ if (myErrorStatus) {
+ return;
+ }
+ // 3.8 Compounds
+ FillImagesContainers(TopAbs_COMPOUND);
+ if (myErrorStatus) {
+ return;
+ }
+
+ BuildResult(TopAbs_COMPOUND);
+ if (myErrorStatus) {
+ return;
+ }
+ //
+ // 4.History
+ PrepareHistory();
+ //
+ // 5 Post-treatment
+ PostTreat();
+}
+//
+// myErrorStatus
+//
+// 0 - Ok
+// 1 - The object is just initialized
+// 2 - DSFiller is failed
+// 10 - No shapes to process
+// 30 - SolidBuilder failed
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_Builder_HeaderFile
+#define _GEOMAlgo_Builder_HeaderFile
+
+#ifndef _NMTTools_PDSFiller_HeaderFile
+#include <NMTTools_PDSFiller.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _TopTools_MapOfShape_HeaderFile
+#include <TopTools_MapOfShape.hxx>
+#endif
+#ifndef _BRepAlgo_Image_HeaderFile
+#include <BRepAlgo_Image.hxx>
+#endif
+#ifndef _TopTools_IndexedDataMapOfShapeListOfShape_HeaderFile
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
+#endif
+#ifndef _TopTools_IndexedDataMapOfShapeShape_HeaderFile
+#include <TopTools_IndexedDataMapOfShapeShape.hxx>
+#endif
+#ifndef _GEOMAlgo_BuilderShape_HeaderFile
+#include <GEOMAlgo_BuilderShape.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+#ifndef _TopAbs_ShapeEnum_HeaderFile
+#include <TopAbs_ShapeEnum.hxx>
+#endif
+class NMTTools_DSFiller;
+class TopoDS_Shape;
+class TopTools_ListOfShape;
+class BRepAlgo_Image;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class GEOMAlgo_Builder : public GEOMAlgo_BuilderShape {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+//! Empty constructor <br>
+Standard_EXPORT GEOMAlgo_Builder();
+Standard_EXPORT virtual ~GEOMAlgo_Builder();
+
+//! Performs calculations <br>
+Standard_EXPORT virtual void Perform() ;
+
+//! Performs calculations using prepared DSFiller <br>
+//! object theDSF <br>
+Standard_EXPORT virtual void PerformWithFiller(const NMTTools_DSFiller& theDSF) ;
+
+//! Adds argument theShape of the operation <br>
+Standard_EXPORT virtual void AddShape(const TopoDS_Shape& theShape) ;
+
+//! Clears internal fields and arguments <br>
+Standard_EXPORT virtual void Clear() ;
+
+//! Returns the arguments of the operation <br>
+Standard_EXPORT const TopTools_ListOfShape& Shapes() const;
+
+//! Returns the list of shapes generated from the <br>
+//! shape theS. <br>
+Standard_EXPORT virtual const TopTools_ListOfShape& Generated(const TopoDS_Shape& theS) ;
+
+//! Returns the list of shapes modified from the shape <br>
+//! theS. <br>
+Standard_EXPORT virtual const TopTools_ListOfShape& Modified(const TopoDS_Shape& theS) ;
+
+//! Returns true if the shape theS has been deleted. <br>
+Standard_EXPORT virtual Standard_Boolean IsDeleted(const TopoDS_Shape& theS) ;
+
+//! Adds arguments of the operation as <br>
+//! shapes of upper level of container shape theShape <br>
+Standard_EXPORT void AddCompound(const TopoDS_Shape& theShape) ;
+
+//! Returns list of arguments of type theType <br>
+Standard_EXPORT const TopTools_ListOfShape& Shapes1(const Standard_Integer theType) const;
+
+//! Returns image shapes <br>
+Standard_EXPORT const BRepAlgo_Image& Images() const;
+
+//! Returns split-parts of shapes that have <br>
+//! state IN for the domain of shape theShape <br>
+Standard_EXPORT const TopTools_ListOfShape& InParts(const TopoDS_Shape& theShape) const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+//! Prepare information for history support <br>
+Standard_EXPORT virtual void PrepareHistory() ;
+
+//! Clears internal fields <br>
+Standard_EXPORT virtual void ClearInternals() ;
+
+//! Provides preparing actions <br>
+Standard_EXPORT virtual void Prepare() ;
+
+//! Provides post-tratment actions <br>
+Standard_EXPORT virtual void PostTreat() ;
+
+//! Append the argument theShape to <br>
+//! typified lists of arguments myShapes1 <br>
+Standard_EXPORT void AddShape1(const TopoDS_Shape& theShape) ;
+
+//! Build the resulting shapes of type theType <br>
+Standard_EXPORT virtual void BuildResult(const TopAbs_ShapeEnum theType) ;
+
+//! Fill Images for vertices <br>
+Standard_EXPORT void FillImagesVertices() ;
+
+//! Fill Images for edges <br>
+Standard_EXPORT void FillImagesEdges() ;
+
+//! Fill Images for faces <br>
+Standard_EXPORT void FillImagesFaces() ;
+
+//! For each interferred face find split edges <br>
+//! that are in 2-D domain of the face <br>
+Standard_EXPORT void FillIn2DParts() ;
+
+//! Build draft faces <br>
+Standard_EXPORT void BuildSplitFaces() ;
+
+//! Among draft faces find same domain faces <br>
+Standard_EXPORT void FillSameDomainFaces() ;
+
+//! Fill Images for faces <br>
+//! taking into account same domain faces <br>
+Standard_EXPORT void FillImagesFaces1() ;
+
+//! Update Images for faces by <br>
+//! internal vertices <br>
+Standard_EXPORT void FillInternalVertices() ;
+
+//! Fill Images for Wires, Shells, Compsolids, Compounds <br>
+Standard_EXPORT void FillImagesContainers(const TopAbs_ShapeEnum theType) ;
+
+//! Fill Images for solids <br>
+Standard_EXPORT void FillImagesSolids() ;
+
+//! For each interferred solid find split faces <br>
+//! that are in 3-D domain of the solid <br>
+Standard_EXPORT void FillIn3DParts() ;
+
+//! Build draft solids <br>
+Standard_EXPORT void BuildSplitSolids() ;
+
+//! Update draft solids by <br>
+//! internal shells, edges, vertices <br>
+Standard_EXPORT void FillInternalShapes() ;
+
+//! Build solid theDraftSolid that consists of <br>
+//! non-internal split faces of the solid <br>
+//! theSolid. <br>
+//! All splits of internal faces of <br>
+//! theSolid are in the list: theInternalFaces <br>
+Standard_EXPORT void BuildDraftSolid(const TopoDS_Shape& theSolid,TopoDS_Shape& theDraftSolid,TopTools_ListOfShape& theInternalFaces) ;
+
+
+ // Fields PROTECTED
+ //
+NMTTools_PDSFiller myDSFiller;
+TopTools_ListOfShape myShapes;
+Standard_Integer myNbTypes;
+TopTools_MapOfShape myMapFence;
+TopTools_ListOfShape myShapes1[9];
+BRepAlgo_Image myImages;
+TopTools_IndexedDataMapOfShapeListOfShape myInParts;
+BRepAlgo_Image mySplitFaces;
+TopTools_IndexedDataMapOfShapeShape mySameDomainShapes;
+TopTools_IndexedDataMapOfShapeShape myDraftSolids;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_Builder.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTTools_DSFiller_HeaderFile
+#include <NMTTools_DSFiller.hxx>
+#endif
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _BRepAlgo_Image_HeaderFile
+#include <BRepAlgo_Image.hxx>
+#endif
+#ifndef _GEOMAlgo_Builder_HeaderFile
+#include <GEOMAlgo_Builder.hxx>
+#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: ModGlue_BuilderArea.cdl
+-- Created:
+-- Author: Peter KURNEV
+
+deferred class BuilderArea from GEOMAlgo
+ inherits Algo from GEOMAlgo
+
+ ---Purpose: The root class for algorithms to build
+ -- faces/solids from set of edges/faces
+
+uses
+ Shape from TopoDS,
+ ListOfShape from TopTools,
+ MapOfOrientedShape from TopTools,
+ Context from IntTools,
+ PContext from IntTools
+
+--raises
+
+is
+ Initialize
+ ---Purpose: Empty constructor
+ returns BuilderArea from GEOMAlgo;
+ ---C++: alias "Standard_EXPORT virtual ~GEOMAlgo_BuilderArea();"
+
+ SetContext(me:out;
+ theContext:Context from IntTools);
+ ---Purpose: Sets cashed geometrical tools
+
+ SetShapes(me:out;
+ theLS:ListOfShape from TopTools);
+ ---Purpose: Sets edges/faces to process
+
+ Shapes(me)
+ ---Purpose: Returns edges/faces to process
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+ Loops(me)
+ ---Purpose: Returns wires/shells that have been built
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+ Areas(me)
+ ---Purpose: Returns faces/solids that have been built
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+ PerformShapesToAvoid(me:out)
+ ---Purpose: Collect the edges/faces that
+ -- a) are internal
+ -- b) are the same and have different orientation
+ is virtual protected;
+
+ PerformLoops(me:out)
+ ---Purpose: Build draft faces/shells
+ -- a)myLoops - draft faces/shells that consist of
+ -- boundary edges/faces
+ -- b)myLoopsInternal - draft faces/shells that contains
+ -- inner edges/faces
+ is virtual protected;
+
+ PerformAreas(me:out)
+ ---Purpose: Build draft faces/solids that contains boundary faces
+ is virtual protected;
+
+ PerformInternalShapes(me:out)
+ ---Purpose: Build finalized faces/solids with internal wires/shells
+ is virtual protected;
+
+
+fields
+ myShapes : ListOfShape from TopTools is protected;
+ myLoops : ListOfShape from TopTools is protected;
+ myLoopsInternal : ListOfShape from TopTools is protected;
+ myShapesToAvoid : MapOfOrientedShape from TopTools is protected;
+ myAreas : ListOfShape from TopTools is protected;
+ --
+ myContext : PContext from IntTools is protected;
+
+end BuilderArea;
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_BuilderArea.cxx
+// Created:
+// Author: Peter KURNEV
+
+
+#include <GEOMAlgo_BuilderArea.ixx>
+
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopoDS_Shape.hxx>
+
+//=======================================================================
+//function :
+//purpose :
+//=======================================================================
+ GEOMAlgo_BuilderArea::GEOMAlgo_BuilderArea()
+:
+ GEOMAlgo_Algo()
+{
+ myContext=NULL;
+}
+//=======================================================================
+//function : ~
+//purpose :
+//=======================================================================
+ GEOMAlgo_BuilderArea::~GEOMAlgo_BuilderArea()
+{
+}
+//=======================================================================
+//function : SetContext
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderArea::SetContext(const IntTools_Context& theContext)
+{
+ myContext=(IntTools_Context*)&theContext;
+}
+//=======================================================================
+//function : SetShapes
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderArea::SetShapes(const TopTools_ListOfShape& theLF)
+{
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ myShapes.Clear();
+ aIt.Initialize(theLF);
+ for(; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ myShapes.Append(aF);
+ }
+}
+//=======================================================================
+//function : Shapes
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_BuilderArea::Shapes()const
+{
+ return myShapes;
+}
+//=======================================================================
+//function : Loops
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_BuilderArea::Loops()const
+{
+ return myLoops;
+}
+//=======================================================================
+//function : Solids
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_BuilderArea::Areas()const
+{
+ return myAreas;
+}
+//=======================================================================
+//function :PerformShapesToAvoid
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderArea::PerformShapesToAvoid()
+{
+}
+//=======================================================================
+//function : PerformLoops
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderArea::PerformLoops()
+{
+}
+//=======================================================================
+//function : PerformAreas
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderArea::PerformAreas()
+{
+}
+//=======================================================================
+//function : PerformInternalShapes
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderArea::PerformInternalShapes()
+{
+}
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_BuilderArea_HeaderFile
+#define _GEOMAlgo_BuilderArea_HeaderFile
+
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TopTools_MapOfOrientedShape_HeaderFile
+#include <TopTools_MapOfOrientedShape.hxx>
+#endif
+#ifndef _IntTools_PContext_HeaderFile
+#include <IntTools_PContext.hxx>
+#endif
+#ifndef _GEOMAlgo_Algo_HeaderFile
+#include <GEOMAlgo_Algo.hxx>
+#endif
+class IntTools_Context;
+class TopTools_ListOfShape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+//! The root class for algorithms to build <br>
+//! faces/solids from set of edges/faces <br>
+class GEOMAlgo_BuilderArea : public GEOMAlgo_Algo {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+//! Sets cashed geometrical tools <br>
+Standard_EXPORT void SetContext(const IntTools_Context& theContext) ;
+
+//! Sets edges/faces to process <br>
+Standard_EXPORT void SetShapes(const TopTools_ListOfShape& theLS) ;
+
+//! Returns edges/faces to process <br>
+Standard_EXPORT const TopTools_ListOfShape& Shapes() const;
+
+//! Returns wires/shells that have been built <br>
+Standard_EXPORT const TopTools_ListOfShape& Loops() const;
+
+//! Returns faces/solids that have been built <br>
+Standard_EXPORT const TopTools_ListOfShape& Areas() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+//! Empty constructor <br>
+Standard_EXPORT GEOMAlgo_BuilderArea();
+Standard_EXPORT virtual ~GEOMAlgo_BuilderArea();
+
+//! Collect the edges/faces that <br>
+//! a) are internal <br>
+//! b) are the same and have different orientation <br>
+Standard_EXPORT virtual void PerformShapesToAvoid() ;
+
+//! Build draft faces/shells <br>
+//! a)myLoops - draft faces/shells that consist of <br>
+//! boundary edges/faces <br>
+//! b)myLoopsInternal - draft faces/shells that contains <br>
+//! inner edges/faces <br>
+Standard_EXPORT virtual void PerformLoops() ;
+
+//! Build draft faces/solids that contains boundary faces <br>
+Standard_EXPORT virtual void PerformAreas() ;
+
+//! Build finalized faces/solids with internal wires/shells <br>
+Standard_EXPORT virtual void PerformInternalShapes() ;
+
+
+ // Fields PROTECTED
+ //
+TopTools_ListOfShape myShapes;
+TopTools_ListOfShape myLoops;
+TopTools_ListOfShape myLoopsInternal;
+TopTools_MapOfOrientedShape myShapesToAvoid;
+TopTools_ListOfShape myAreas;
+IntTools_PContext myContext;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_BuilderArea.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _IntTools_Context_HeaderFile
+#include <IntTools_Context.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_BuilderArea_HeaderFile
+#include <GEOMAlgo_BuilderArea.hxx>
+#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_BuilderFace.cdl
+-- Created:
+-- Author: Peter KURNEV
+
+
+
+class BuilderFace from GEOMAlgo
+ inherits BuilderArea from GEOMAlgo
+
+ ---Purpose: The algorithm to build faces from set of edges
+
+uses
+ Face from TopoDS
+
+--raises
+
+is
+ Create
+ ---Purpose: Empty constructor
+ returns BuilderFace from GEOMAlgo;
+ ---C++: alias "Standard_EXPORT virtual ~GEOMAlgo_BuilderFace();"
+
+ SetFace(me:out;
+ theFace:Face from TopoDS);
+ ---Purpose: Sets the face generatix
+
+ Face(me)
+ ---Purpose: Returns the face generatix
+ returns Face from TopoDS;
+ ---C++: return const &
+
+ Perform(me:out)
+ ---Purpose: Performs the algorithm
+ is redefined;
+
+ PerformShapesToAvoid(me:out)
+ ---Purpose: Collect the edges that
+ -- a) are internal
+ -- b) are the same and have different orientation
+ is redefined protected;
+
+ PerformLoops(me:out)
+ ---Purpose: Build draft wires
+ -- a)myLoops - draft wires that consist of
+ -- boundary edges
+ -- b)myLoopsInternal - draft wires that contains
+ -- inner edges
+ is redefined protected;
+
+ PerformAreas(me:out)
+ ---Purpose: Build draft faces that contains boundary edges
+ is redefined protected;
+
+ PerformInternalShapes(me:out)
+ ---Purpose: Build finalized faces with internals
+ is redefined protected;
+
+
+fields
+ myFace : Face from TopoDS is protected;
+
+end BuilderFace;
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_BuilderFace.cxx
+// Created:
+// Author: Peter KURNEV
+
+#include <GEOMAlgo_BuilderFace.ixx>
+
+#include <gp_Pnt2d.hxx>
+#include <gp_Pln.hxx>
+#include <gp_Vec.hxx>
+#include <gp_Dir.hxx>
+#include <gp_Pnt.hxx>
+
+#include <Geom_Surface.hxx>
+
+#include <TopAbs.hxx>
+#include <TopLoc_Location.hxx>
+
+#include <TopoDS_Iterator.hxx>
+#include <TopoDS_Face.hxx>
+#include <TopoDS.hxx>
+#include <TopoDS_Shape.hxx>
+#include <TopoDS_Wire.hxx>
+#include <TopoDS_Edge.hxx>
+#include <TopoDS_Vertex.hxx>
+
+#include <BRep_Builder.hxx>
+#include <BRep_Tool.hxx>
+#include <BRepTools.hxx>
+
+#include <TopExp.hxx>
+#include <TopExp_Explorer.hxx>
+
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_MapIteratorOfMapOfShape.hxx>
+#include <TopTools_MapOfOrientedShape.hxx>
+#include <TopTools_MapIteratorOfMapOfOrientedShape.hxx>
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_DataMapOfShapeShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
+#include <TopTools_DataMapOfShapeListOfShape.hxx>
+#include <TopTools_DataMapIteratorOfDataMapOfShapeListOfShape.hxx>
+
+#include <IntTools_FClass2d.hxx>
+#include <IntTools_Context.hxx>
+
+#include <BOPTools_Tools2D.hxx>
+#include <BOP_WireEdgeSet.hxx>
+#include <BOP_WESCorrector.hxx>
+
+#include <NMTTools_ListOfCoupleOfShape.hxx>
+#include <NMTTools_CoupleOfShape.hxx>
+#include <NMTTools_ListIteratorOfListOfCoupleOfShape.hxx>
+
+#include <GEOMAlgo_Tools3D.hxx>
+#include <GEOMAlgo_BuilderTools.hxx>
+#include <GEOMAlgo_WireEdgeSet.hxx>
+#include <GEOMAlgo_WESCorrector.hxx>
+
+//
+static
+ Standard_Boolean IsGrowthWire(const TopoDS_Shape& ,
+
+ const TopTools_IndexedMapOfShape& );
+
+static
+ Standard_Boolean IsInside(const TopoDS_Shape& ,
+ const TopoDS_Shape& ,
+ IntTools_PContext& );
+static
+ void MakeInternalWires(const TopTools_MapOfShape& ,
+ TopTools_ListOfShape& );
+
+//=======================================================================
+//function :
+//purpose :
+//=======================================================================
+ GEOMAlgo_BuilderFace::GEOMAlgo_BuilderFace()
+:
+ GEOMAlgo_BuilderArea()
+{
+}
+//=======================================================================
+//function : ~
+//purpose :
+//=======================================================================
+ GEOMAlgo_BuilderFace::~GEOMAlgo_BuilderFace()
+{
+}
+//=======================================================================
+//function : SetFace
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderFace::SetFace(const TopoDS_Face& theFace)
+{
+ myFace=theFace;
+}
+//=======================================================================
+//function : Face
+//purpose :
+//=======================================================================
+ const TopoDS_Face& GEOMAlgo_BuilderFace::Face()const
+{
+ return myFace;
+}
+//=======================================================================
+//function : Perform
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderFace::Perform()
+{
+ myErrorStatus=0;
+ //
+ if (myContext==NULL) {
+ myErrorStatus=11;// Null Context
+ return;
+ }
+ //
+ if (myFace.IsNull()) {
+ myErrorStatus=12;// Null face generix
+ return;
+ }
+ //
+ PerformShapesToAvoid();
+ if (myErrorStatus) {
+ return;
+ }
+ //
+ PerformLoops();
+ if (myErrorStatus) {
+ return;
+ }
+ //
+ PerformAreas();
+ if (myErrorStatus) {
+ return;
+ }
+ //
+ PerformInternalShapes();
+ if (myErrorStatus) {
+ return;
+ }
+}
+//=======================================================================
+//function :PerformShapesToAvoid
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderFace::PerformShapesToAvoid()
+{
+ Standard_Boolean bFound;
+ Standard_Integer i, iCnt, aNbV, aNbE;
+ TopTools_IndexedDataMapOfShapeListOfShape aMVE;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ myShapesToAvoid.Clear();
+ //
+ iCnt=0;
+ while (1) {
+ ++iCnt;
+ bFound=Standard_False;
+ //
+ // 1. MEF
+ aMVE.Clear();
+ aIt.Initialize (myShapes);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aE=aIt.Value();
+ if (!myShapesToAvoid.Contains(aE)) {
+ TopExp::MapShapesAndAncestors(aE, TopAbs_VERTEX, TopAbs_EDGE, aMVE);
+ }
+ else {
+ int a=0;
+ }
+ }
+ aNbV=aMVE.Extent();
+ //
+ // 2. myEdgesToAvoid
+ for (i=1; i<=aNbV; ++i) {
+ const TopoDS_Vertex& aV=TopoDS::Vertex(aMVE.FindKey(i));
+ //
+ TopTools_ListOfShape& aLE=aMVE.ChangeFromKey(aV);
+ aNbE=aLE.Extent();
+ if (!aNbE) {
+ continue;
+ }
+ //
+ const TopoDS_Edge& aE1=TopoDS::Edge(aLE.First());
+ if (aNbE==1) {
+ if (BRep_Tool::Degenerated(aE1)) {
+ continue;
+ }
+ if (aV.Orientation()==TopAbs_INTERNAL) {
+ continue;
+ }
+ bFound=Standard_True;
+ myShapesToAvoid.Add(aE1);
+ }
+ else if (aNbE==2) {
+ const TopoDS_Edge& aE2=TopoDS::Edge(aLE.Last());
+ if (aE2.IsSame(aE1)) {
+ TopoDS_Vertex aV1x, aV2x;
+ //
+ TopExp::Vertices(aE1, aV1x, aV2x);
+ if (aV1x.IsSame(aV2x)) {
+ continue;
+ }
+ bFound=Standard_True;
+ myShapesToAvoid.Add(aE1);
+ myShapesToAvoid.Add(aE2);
+ }
+ }
+ }// for (i=1; i<=aNbE; ++i) {
+ //
+ if (!bFound) {
+ break;
+ }
+ //
+ }//while (1)
+ //printf(" EdgesToAvoid=%d, iCnt=%d\n", EdgesToAvoid.Extent(), iCnt);
+}
+//=======================================================================
+//function : PerformLoops
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderFace::PerformLoops()
+{
+ myErrorStatus=0;
+ //
+ Standard_Boolean bFlag;
+ Standard_Integer aNbEA;
+ TopTools_ListIteratorOfListOfShape aIt;
+ TopTools_MapIteratorOfMapOfOrientedShape aItM;
+ TopTools_IndexedDataMapOfShapeListOfShape aVEMap;
+ TopTools_MapOfOrientedShape aMAdded;
+ BRep_Builder aBB;
+ GEOMAlgo_WireEdgeSet aWES;
+ GEOMAlgo_WESCorrector aWESCor;
+ //
+ // 1. Usual Wires
+ myLoops.Clear();
+ aWES.SetFace(myFace);
+ //
+ aIt.Initialize (myShapes);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aE=aIt.Value();
+ if (!myShapesToAvoid.Contains(aE)) {
+ aWES.AddStartElement(aE);
+ }
+ }
+ //
+ aWESCor.SetWES(aWES);
+ aWESCor.Perform();
+ //
+ GEOMAlgo_WireEdgeSet& aWESN=aWESCor.NewWES();
+ const TopTools_ListOfShape& aLW=aWESN.Shapes();
+ //
+ aIt.Initialize (aLW);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aW=aIt.Value();
+ myLoops.Append(aW);
+ }
+ //
+ // 2. Internal Wires
+ myLoopsInternal.Clear();
+ //
+ aNbEA=myShapesToAvoid.Extent();
+ aItM.Initialize(myShapesToAvoid);
+ for (; aItM.More(); aItM.Next()) {
+ const TopoDS_Shape& aEE=aItM.Key();
+ TopExp::MapShapesAndAncestors(aEE, TopAbs_VERTEX, TopAbs_EDGE, aVEMap);
+ }
+ //
+ bFlag=Standard_True;
+ aItM.Initialize(myShapesToAvoid);
+ for (; aItM.More()&&bFlag; aItM.Next()) {
+ const TopoDS_Shape& aEE=aItM.Key();
+ if (!aMAdded.Add(aEE)) {
+ continue;
+ }
+ //
+ // make new wire
+ TopoDS_Wire aW;
+ aBB.MakeWire(aW);
+ aBB.Add(aW, aEE);
+ //
+ TopoDS_Iterator aItW (aW);
+ for (; aItW.More()&&bFlag; aItW.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(aItW.Value());
+ //
+ TopoDS_Iterator aItE(aE);
+ for (; aItE.More()&&bFlag; aItE.Next()) {
+ const TopoDS_Vertex& aV = TopoDS::Vertex(aItE.Value());
+ const TopTools_ListOfShape& aLE=aVEMap.FindFromKey(aV);
+ aIt.Initialize(aLE);
+ for (; aIt.More()&&bFlag; aIt.Next()) {
+ const TopoDS_Shape& aEx=aIt.Value();
+ if (aMAdded.Add(aEx)) {
+ aBB.Add(aW, aEx);
+ if(aMAdded.Extent()==aNbEA) {
+ bFlag=!bFlag;
+ }
+ }
+ }//for (; aIt.More(); aIt.Next()) {
+ }//for (; aItE.More(); aItE.Next()) {
+ }//for (; aItW.More(); aItW.Next()) {
+ myLoopsInternal.Append(aW);
+ }//for (; aItM.More(); aItM.Next()) {
+}
+//=======================================================================
+//function : PerformAreas
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderFace::PerformAreas()
+{
+ myErrorStatus=0;
+ //
+ Standard_Boolean bIsGrowth, bIsHole;
+ Standard_Real aTol;
+ TopTools_ListOfShape aNewFaces, aHoleWires;
+ TopoDS_Shape anInfinitePointShape;
+ TopTools_DataMapOfShapeShape aInOutMap;
+ TopTools_DataMapOfShapeListOfShape aMSH;
+ TopTools_DataMapIteratorOfDataMapOfShapeListOfShape aItMSH;
+ TopTools_ListIteratorOfListOfShape aIt1, aIt2;
+ TopTools_IndexedMapOfShape aMHE;
+ BRep_Builder aBB;
+ Handle(Geom_Surface) aS;
+ TopLoc_Location aLoc;
+ //
+ aTol=BRep_Tool::Tolerance(myFace);
+ aS=BRep_Tool::Surface(myFace, aLoc);
+ //
+ myAreas.Clear();
+ //
+ // Draft faces [aNewFaces]
+ aIt1.Initialize(myLoops);
+ for ( ; aIt1.More(); aIt1.Next()) {
+ const TopoDS_Shape& aWire=aIt1.Value();
+ //
+ bIsGrowth=IsGrowthWire(aWire, aMHE);
+ if (bIsGrowth) {
+ // make a growth face from a wire
+ TopoDS_Face aFace;
+ aBB.MakeFace(aFace, aS, aLoc, aTol);
+ aBB.Add (aFace, aWire);
+ //
+ aNewFaces.Append (aFace);
+ }
+ else{
+ // check if a wire is a hole
+ //XX
+ //bIsHole=IsHole(aWire, myFace, myContext);
+ bIsHole=GEOMAlgo_BuilderTools::IsHole(aWire, myFace);
+ //XX
+ if (bIsHole) {
+ aHoleWires.Append(aWire);
+ TopExp::MapShapes(aWire, TopAbs_EDGE, aMHE);
+ }
+ else {
+ // make a growth face from a wire
+ TopoDS_Face aFace;
+ aBB.MakeFace(aFace, aS, aLoc, aTol);
+ aBB.Add (aFace, aWire);
+ //
+ aNewFaces.Append (aFace);
+ }
+ }
+ }
+ //
+ // 2. Find outer growth shell that is most close to each hole shell
+ aIt2.Initialize(aHoleWires);
+ for (; aIt2.More(); aIt2.Next()) {
+ const TopoDS_Shape& aHole = aIt2.Value();
+ //
+ aIt1.Initialize(aNewFaces);
+ for ( ; aIt1.More(); aIt1.Next()) {
+ const TopoDS_Shape& aF=aIt1.Value();
+ //
+ if (!IsInside(aHole, aF, myContext)){
+ continue;
+ }
+ //
+ if ( aInOutMap.IsBound (aHole)){
+ const TopoDS_Shape& aF2=aInOutMap(aHole);
+ if (IsInside(aF, aF2, myContext)) {
+ aInOutMap.UnBind(aHole);
+ aInOutMap.Bind (aHole, aF);
+ }
+ }
+ else{
+ aInOutMap.Bind (aHole, aF);
+ }
+ }
+ //
+ // Add aHole to a map Face/ListOfHoles [aMSH]
+ if (aInOutMap.IsBound(aHole)){
+ const TopoDS_Shape& aF=aInOutMap(aHole);
+ if (aMSH.IsBound(aF)) {
+ TopTools_ListOfShape& aLH=aMSH.ChangeFind(aF);
+ aLH.Append(aHole);
+ }
+ else {
+ TopTools_ListOfShape aLH;
+ aLH.Append(aHole);
+ aMSH.Bind(aF, aLH);
+ }
+ }
+ }// for (; aIt2.More(); aIt2.Next())
+ //
+ // 3. Add aHoles to Faces
+ aItMSH.Initialize(aMSH);
+ for (; aItMSH.More(); aItMSH.Next()) {
+ TopoDS_Face aF=TopoDS::Face(aItMSH.Key());
+ //
+ const TopTools_ListOfShape& aLH=aItMSH.Value();
+ aIt2.Initialize(aLH);
+ for (; aIt2.More(); aIt2.Next()) {
+ const TopoDS_Shape& aHole = aIt2.Value();
+ aBB.Add (aF, aHole);
+ }
+ //
+ // update classifier
+ aTol=BRep_Tool::Tolerance(aF);
+ IntTools_FClass2d& aClsf=myContext->FClass2d(aF);
+ aClsf.Init(aF, aTol);
+ }
+ //
+ // These aNewFaces are draft faces that
+ // do not contain any internal shapes
+ //
+ myAreas.Append(aNewFaces);
+}
+//=======================================================================
+//function : PerformInternalShapes
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderFace::PerformInternalShapes()
+{
+ myErrorStatus=0;
+ //
+ Standard_Integer aNbWI=myLoopsInternal.Extent();
+ if (!aNbWI) {// nothing to do
+ return;
+ }
+ //
+ //Standard_Real aTol;
+ BRep_Builder aBB;
+ TopTools_ListIteratorOfListOfShape aIt1, aIt2;
+ TopoDS_Iterator aIt;
+ TopTools_MapOfShape aME, aMEP;
+ TopTools_MapIteratorOfMapOfShape aItME;
+ TopTools_IndexedDataMapOfShapeListOfShape aMVE;
+ TopTools_ListOfShape aLSI;
+ //
+ // 1. All internal edges
+ aIt1.Initialize(myLoopsInternal);
+ for (; aIt1.More(); aIt1.Next()) {
+ const TopoDS_Shape& aWire=aIt1.Value();
+ aIt.Initialize(aWire);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aE=aIt.Value();
+ aME.Add(aE);
+ }
+ }
+ aNbWI=aME.Extent();
+ //
+ // 2 Process faces
+ aIt2.Initialize(myAreas);
+ for ( ; aIt2.More(); aIt2.Next()) {
+ TopoDS_Face& aF=TopoDS::Face(aIt2.Value());
+ //
+ aMVE.Clear();
+ TopExp::MapShapesAndAncestors(aF, TopAbs_VERTEX, TopAbs_EDGE, aMVE);
+ //
+ // 2.1 Separate faces to process aMEP
+ aMEP.Clear();
+ aItME.Initialize(aME);
+ for (; aItME.More(); aItME.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(aItME.Key());
+ if (IsInside(aE, aF, myContext)) {
+ aMEP.Add(aE);
+ }
+ }
+ //
+ // 2.2 Make Internal Wires
+ aLSI.Clear();
+ MakeInternalWires(aMEP, aLSI);
+ //
+ // 2.3 Add them to aF
+ aIt1.Initialize(aLSI);
+ for (; aIt1.More(); aIt1.Next()) {
+ const TopoDS_Shape& aSI=aIt1.Value();
+ aBB.Add (aF, aSI);
+ }
+ //
+ // 2.4 Remove faces aMFP from aMF
+ aItME.Initialize(aMEP);
+ for (; aItME.More(); aItME.Next()) {
+ const TopoDS_Shape& aE=aItME.Key();
+ aME.Remove(aE);
+ }
+ //
+ aNbWI=aME.Extent();
+ if (!aNbWI) {
+ break;
+ }
+ } //for ( ; aIt2.More(); aIt2.Next()) {
+}
+//=======================================================================
+//function : MakeInternalWires
+//purpose :
+//=======================================================================
+void MakeInternalWires(const TopTools_MapOfShape& theME,
+ TopTools_ListOfShape& theWires)
+{
+ TopTools_MapIteratorOfMapOfShape aItM;
+ TopTools_MapOfShape aAddedMap;
+ TopTools_ListIteratorOfListOfShape aItE;
+ TopTools_IndexedDataMapOfShapeListOfShape aMVE;
+ BRep_Builder aBB;
+ //
+ aItM.Initialize(theME);
+ for (; aItM.More(); aItM.Next()) {
+ const TopoDS_Shape& aE=aItM.Key();
+ TopExp::MapShapesAndAncestors(aE, TopAbs_VERTEX, TopAbs_EDGE, aMVE);
+ }
+ //
+ aItM.Initialize(theME);
+ for (; aItM.More(); aItM.Next()) {
+ TopoDS_Shape aEE=aItM.Key();
+ if (!aAddedMap.Add(aEE)) {
+ continue;
+ }
+ //
+ // make a new shell
+ TopoDS_Wire aW;
+ aBB.MakeWire(aW);
+ aEE.Orientation(TopAbs_INTERNAL);
+ aBB.Add(aW, aEE);
+ //
+ TopoDS_Iterator aItAdded (aW);
+ for (; aItAdded.More(); aItAdded.Next()) {
+ const TopoDS_Shape& aE =aItAdded.Value();
+ //
+ TopExp_Explorer aExp(aE, TopAbs_VERTEX);
+ for (; aExp.More(); aExp.Next()) {
+ const TopoDS_Shape& aV =aExp.Current();
+ const TopTools_ListOfShape& aLE=aMVE.FindFromKey(aV);
+ aItE.Initialize(aLE);
+ for (; aItE.More(); aItE.Next()) {
+ TopoDS_Shape aEL=aItE.Value();
+ if (aAddedMap.Add(aEL)){
+ aEL.Orientation(TopAbs_INTERNAL);
+ aBB.Add(aW, aEL);
+ }
+ }
+ }
+ }
+ theWires.Append(aW);
+ }
+}
+
+//=======================================================================
+//function : IsInside
+//purpose :
+//=======================================================================
+Standard_Boolean IsInside(const TopoDS_Shape& theHole,
+ const TopoDS_Shape& theF2,
+ IntTools_PContext& theContext)
+{
+ Standard_Real aT, aU, aV;
+ TopExp_Explorer aExp;
+ TopAbs_State aState=TopAbs_UNKNOWN;
+ gp_Pnt2d aP2D;
+ //
+ const TopoDS_Face& aF2=TopoDS::Face(theF2);
+ //
+ aExp.Init(theHole, TopAbs_EDGE);
+ if (aExp.More()){
+ const TopoDS_Edge& aE = TopoDS::Edge(aExp.Current());
+ aT=BOPTools_Tools2D::IntermediatePoint(aE);
+ BOPTools_Tools2D::PointOnSurface(aE, aF2, aT, aU, aV);
+ aP2D.SetCoord(aU, aV);
+ //
+ IntTools_FClass2d& aClsf=theContext->FClass2d(aF2);
+ aState=aClsf.Perform(aP2D);
+ }
+ return (aState==TopAbs_IN);
+}
+//=======================================================================
+//function : IsGrowthWire
+//purpose :
+//=======================================================================
+Standard_Boolean IsGrowthWire(const TopoDS_Shape& theWire,
+ const TopTools_IndexedMapOfShape& theMHE)
+{
+ Standard_Boolean bRet;
+ TopoDS_Iterator aIt;
+ //
+ bRet=Standard_False;
+ if (theMHE.Extent()) {
+ aIt.Initialize(theWire);
+ for(; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aE=aIt.Value();
+ if (theMHE.Contains(aE)) {
+ return !bRet;
+ }
+ }
+ }
+ return bRet;
+}
+//modified by NIZNHY-PKV Mon Sep 18 13:18:27 2006f
+/*
+static
+ Standard_Boolean IsHole(const TopoDS_Shape& ,
+ const TopoDS_Face& ,
+ IntTools_PContext& );
+*/
+//modified by NIZNHY-PKV Mon Sep 18 13:18:34 2006t
+//modified by NIZNHY-PKV Mon Sep 18 13:18:13 2006f
+/*
+//=======================================================================
+//function : IsHole
+//purpose :
+//=======================================================================
+Standard_Boolean IsHole(const TopoDS_Shape& theS2,
+ const TopoDS_Face& theFace,
+ IntTools_PContext& theContext)
+{
+ Standard_Boolean bIsHole;
+ Standard_Real aTol;
+ Handle(Geom_Surface) aS;
+ TopLoc_Location aLoc;
+ TopoDS_Face aF;
+ BRep_Builder aBB;
+ //
+ aTol=BRep_Tool::Tolerance(theFace);
+ aS=BRep_Tool::Surface(theFace, aLoc);
+ aBB.MakeFace(aF, aS, aLoc, aTol);
+ aBB.Add (aF, theS2);
+ //
+ IntTools_FClass2d& aClsf=theContext->FClass2d(aF);
+ //
+ bIsHole=aClsf.IsHole();
+ //
+ return bIsHole;
+ //
+}
+*/
+//modified by NIZNHY-PKV Mon Sep 18 13:18:06 2006t
+
+//BRepTools::Write(aFF, "ff");
+//
+// ErrorStatus :
+// 11 - Null Context
+// 12 - Null face generix
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_BuilderFace_HeaderFile
+#define _GEOMAlgo_BuilderFace_HeaderFile
+
+#ifndef _TopoDS_Face_HeaderFile
+#include <TopoDS_Face.hxx>
+#endif
+#ifndef _GEOMAlgo_BuilderArea_HeaderFile
+#include <GEOMAlgo_BuilderArea.hxx>
+#endif
+class TopoDS_Face;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+//! The algorithm to build faces from set of edges <br>
+class GEOMAlgo_BuilderFace : public GEOMAlgo_BuilderArea {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+//! Empty constructor <br>
+Standard_EXPORT GEOMAlgo_BuilderFace();
+Standard_EXPORT virtual ~GEOMAlgo_BuilderFace();
+
+//! Sets the face generatix <br>
+Standard_EXPORT void SetFace(const TopoDS_Face& theFace) ;
+
+//! Returns the face generatix <br>
+Standard_EXPORT const TopoDS_Face& Face() const;
+
+//! Performs the algorithm <br>
+Standard_EXPORT virtual void Perform() ;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+//! Collect the edges that <br>
+//! a) are internal <br>
+//! b) are the same and have different orientation <br>
+Standard_EXPORT virtual void PerformShapesToAvoid() ;
+
+//! Build draft wires <br>
+//! a)myLoops - draft wires that consist of <br>
+//! boundary edges <br>
+//! b)myLoopsInternal - draft wires that contains <br>
+//! inner edges <br>
+Standard_EXPORT virtual void PerformLoops() ;
+
+//! Build draft faces that contains boundary edges <br>
+Standard_EXPORT virtual void PerformAreas() ;
+
+//! Build finalized faces with internals <br>
+Standard_EXPORT virtual void PerformInternalShapes() ;
+
+
+ // Fields PROTECTED
+ //
+TopoDS_Face myFace;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_BuilderFace.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _TopoDS_Face_HeaderFile
+#include <TopoDS_Face.hxx>
+#endif
+#ifndef _GEOMAlgo_BuilderFace_HeaderFile
+#include <GEOMAlgo_BuilderFace.hxx>
+#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_BuilderShape.cdl
+-- Created:
+-- Author: Peter KURNEV
+
+
+
+deferred class BuilderShape from GEOMAlgo
+ inherits Algo from GEOMAlgo
+
+ ---Purpose: Root class for algorithms that has shape as result
+
+uses
+ Shape from TopoDS,
+ ListOfShape from TopTools,
+ MapOfShape from TopTools
+
+--raises
+
+is
+ Initialize
+ ---Purpose: Empty constructor
+ returns BuilderShape from GEOMAlgo;
+ ---C++: alias "Standard_EXPORT virtual ~GEOMAlgo_BuilderShape();"
+
+ Shape(me)
+ ---Purpose: Returns the result of algorithm
+ returns Shape from TopoDS;
+ ---C++: return const &
+
+
+ ------------------------------------------------------------------
+ --- The following methods are not implemented at this level.
+ -- An empty list is returned.
+ --- They are optional and can be redefined.
+ ------------------------------------------------------------------
+ Generated (me:out;
+ theS : Shape from TopoDS)
+ ---Purpose: Returns the list of shapes generated from the
+ -- shape theS.
+ returns ListOfShape from TopTools
+ is virtual;
+ ---C++: return const &
+
+ Modified (me:out;
+ theS : Shape from TopoDS)
+ ---Purpose: Returns the list of shapes modified from the
+ -- shape theS.
+ returns ListOfShape from TopTools
+ is virtual;
+ ---C++: return const &
+
+ IsDeleted (me:out;
+ theS : Shape from TopoDS)
+ ---Purpose: Returns true if the shape theS has been deleted.
+ returns Boolean from Standard
+ is virtual;
+
+ HasDeleted (me)
+ ---Purpose: Returns true if the at least one shape(or subshape)
+ -- of arguments has been deleted.
+ returns Boolean from Standard;
+
+ HasGenerated (me)
+ ---Purpose: Returns true if the at least one shape(or subshape)
+ -- of arguments has generated shapes.
+ returns Boolean from Standard;
+
+ HasModified (me)
+ ---Purpose: Returns true if the at least one shape(or subshape)
+ -- of arguments has modified shapes.
+ returns Boolean from Standard;
+
+ PrepareHistory (me:out)
+ ---Purpose: Prepare information for history support
+ is virtual protected;
+
+
+fields
+ myShape : Shape from TopoDS is protected;
+ --
+ myHistShapes : ListOfShape from TopTools is protected;
+ myMapShape : MapOfShape from TopTools is protected;
+ myHasDeleted : Boolean from Standard is protected;
+ myHasGenerated : Boolean from Standard is protected;
+ myHasModified : Boolean from Standard is protected;
+
+end BuilderShape;
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_BuilderShape.cxx
+// Created:
+// Author: Peter KURNEV
+
+
+#include <GEOMAlgo_BuilderShape.ixx>
+//=======================================================================
+//function :
+//purpose :
+//=======================================================================
+ GEOMAlgo_BuilderShape::GEOMAlgo_BuilderShape()
+:
+ GEOMAlgo_Algo()
+{
+ myHasDeleted=Standard_False;
+ myHasGenerated=Standard_False;
+ myHasModified=Standard_False;
+}
+//=======================================================================
+//function : ~
+//purpose :
+//=======================================================================
+ GEOMAlgo_BuilderShape::~GEOMAlgo_BuilderShape()
+{
+}
+//=======================================================================
+//function : Shape
+//purpose :
+//=======================================================================
+ const TopoDS_Shape& GEOMAlgo_BuilderShape::Shape() const
+{
+ return myShape;
+}
+//
+//=======================================================================
+//function : Generated
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_BuilderShape::Generated(const TopoDS_Shape& )
+{
+ myHistShapes.Clear();
+ return myHistShapes;
+}
+//=======================================================================
+//function : Modified
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_BuilderShape::Modified(const TopoDS_Shape& )
+{
+ myHistShapes.Clear();
+ return myHistShapes;
+}
+//=======================================================================
+//function : IsDeleted
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_BuilderShape::IsDeleted(const TopoDS_Shape& theS)
+{
+ Standard_Boolean bRet;
+ //
+ bRet=!myMapShape.Contains(theS);
+ return bRet;
+}
+//=======================================================================
+//function : HasDeleted
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_BuilderShape::HasDeleted()const
+{
+ return myHasDeleted;
+}
+//=======================================================================
+//function : HasGenerated
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_BuilderShape::HasGenerated()const
+{
+ return myHasGenerated;
+}
+//=======================================================================
+//function : HasModified
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_BuilderShape::HasModified()const
+{
+ return myHasModified;
+}
+//=======================================================================
+//function : PrepareHistory
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderShape::PrepareHistory()
+{
+ myHistShapes.Clear();
+ myMapShape.Clear();
+ myHasDeleted=Standard_False;
+ myHasGenerated=Standard_False;
+ myHasModified=Standard_False;
+}
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_BuilderShape_HeaderFile
+#define _GEOMAlgo_BuilderShape_HeaderFile
+
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TopTools_MapOfShape_HeaderFile
+#include <TopTools_MapOfShape.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+#ifndef _GEOMAlgo_Algo_HeaderFile
+#include <GEOMAlgo_Algo.hxx>
+#endif
+class TopoDS_Shape;
+class TopTools_ListOfShape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+//! Root class for algorithms that has shape as result <br>
+class GEOMAlgo_BuilderShape : public GEOMAlgo_Algo {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+//! Returns the result of algorithm <br>
+Standard_EXPORT const TopoDS_Shape& Shape() const;
+
+//! Returns the list of shapes generated from the <br>
+//! shape theS. <br>
+Standard_EXPORT virtual const TopTools_ListOfShape& Generated(const TopoDS_Shape& theS) ;
+
+//! Returns the list of shapes modified from the <br>
+//! shape theS. <br>
+Standard_EXPORT virtual const TopTools_ListOfShape& Modified(const TopoDS_Shape& theS) ;
+
+//! Returns true if the shape theS has been deleted. <br>
+Standard_EXPORT virtual Standard_Boolean IsDeleted(const TopoDS_Shape& theS) ;
+
+//! Returns true if the at least one shape(or subshape) <br>
+//! of arguments has been deleted. <br>
+Standard_EXPORT Standard_Boolean HasDeleted() const;
+
+//! Returns true if the at least one shape(or subshape) <br>
+//! of arguments has generated shapes. <br>
+Standard_EXPORT Standard_Boolean HasGenerated() const;
+
+//! Returns true if the at least one shape(or subshape) <br>
+//! of arguments has modified shapes. <br>
+Standard_EXPORT Standard_Boolean HasModified() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+//! Empty constructor <br>
+Standard_EXPORT GEOMAlgo_BuilderShape();
+Standard_EXPORT virtual ~GEOMAlgo_BuilderShape();
+
+//! Prepare information for history support <br>
+Standard_EXPORT virtual void PrepareHistory() ;
+
+
+ // Fields PROTECTED
+ //
+TopoDS_Shape myShape;
+TopTools_ListOfShape myHistShapes;
+TopTools_MapOfShape myMapShape;
+Standard_Boolean myHasDeleted;
+Standard_Boolean myHasGenerated;
+Standard_Boolean myHasModified;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_BuilderShape.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_BuilderShape_HeaderFile
+#include <GEOMAlgo_BuilderShape.hxx>
+#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_BuilderSolid.cdl
+-- Created:
+-- Author: Peter KURNEV
+
+class BuilderSolid from GEOMAlgo
+ inherits BuilderArea from GEOMAlgo
+
+ ---Purpose: The algorithm to build solids from set of faces
+
+--uses
+--raises
+
+is
+ Create
+ ---Purpose: Empty constructor
+ returns BuilderSolid from GEOMAlgo;
+ ---C++: alias "Standard_EXPORT virtual ~GEOMAlgo_BuilderSolid();"
+
+
+ Perform(me:out)
+ ---Purpose: Performs the algorithm
+ is redefined;
+
+ PerformShapesToAvoid(me:out)
+ ---Purpose: Collect the faces that
+ -- a) are internal
+ -- b) are the same and have different orientation
+ is redefined protected;
+
+ PerformLoops(me:out)
+ ---Purpose: Build draft shells
+ -- a)myLoops - draft shells that consist of
+ -- boundary faces
+ -- b)myLoopsInternal - draft shells that contains
+ -- inner faces
+ is redefined protected;
+
+ PerformAreas(me:out)
+ ---Purpose: Build draft solids that contains boundary faces
+ is redefined protected;
+
+ PerformInternalShapes(me:out)
+ ---Purpose: Build finalized solids with internal shells
+ is redefined protected;
+
+--fields
+
+end BuilderSolid;
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_BuilderSolid.cxx
+// Created:
+// Author: Peter KURNEV
+
+
+#include <GEOMAlgo_BuilderSolid.ixx>
+
+#include <gp_Pnt2d.hxx>
+#include <gp_Pln.hxx>
+#include <gp_Vec.hxx>
+#include <gp_Dir.hxx>
+#include <gp_Pnt.hxx>
+
+#include <Geom_Curve.hxx>
+#include <Geom_Surface.hxx>
+#include <Geom2d_Curve.hxx>
+
+#include <TopAbs.hxx>
+
+#include <TopoDS_Iterator.hxx>
+#include <TopoDS_Face.hxx>
+#include <TopoDS.hxx>
+#include <TopoDS_Shape.hxx>
+#include <TopoDS_Shell.hxx>
+#include <TopoDS_Edge.hxx>
+#include <TopoDS_Solid.hxx>
+#include <TopoDS_Vertex.hxx>
+#include <TopoDS_Compound.hxx>
+
+#include <BRep_Builder.hxx>
+#include <BRep_Tool.hxx>
+#include <BRepTools.hxx>
+#include <BRepClass3d_SolidClassifier.hxx>
+
+#include <TopExp.hxx>
+#include <TopExp_Explorer.hxx>
+
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_MapIteratorOfMapOfShape.hxx>
+#include <TopTools_MapOfOrientedShape.hxx>
+#include <TopTools_MapIteratorOfMapOfOrientedShape.hxx>
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_DataMapOfShapeShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
+#include <TopTools_DataMapOfShapeListOfShape.hxx>
+#include <TopTools_DataMapIteratorOfDataMapOfShapeListOfShape.hxx>
+
+#include <IntTools_Context.hxx>
+
+#include <BOPTools_Tools2D.hxx>
+#include <BOPTools_Tools3D.hxx>
+
+#include <NMTTools_ListOfCoupleOfShape.hxx>
+#include <NMTTools_CoupleOfShape.hxx>
+#include <NMTTools_ListIteratorOfListOfCoupleOfShape.hxx>
+
+#include <GEOMAlgo_Tools3D.hxx>
+#include <GEOMAlgo_BuilderTools.hxx>
+
+//
+static
+ Standard_Boolean IsGrowthShell(const TopoDS_Shape& ,
+ const TopTools_IndexedMapOfShape& );
+static
+ Standard_Boolean IsHole(const TopoDS_Shape& ,
+ IntTools_PContext& );
+static
+ Standard_Boolean IsInside(const TopoDS_Shape& ,
+ const TopoDS_Shape& ,
+ IntTools_PContext& );
+static
+ void MakeInternalShells(const TopTools_MapOfShape& ,
+ TopTools_ListOfShape& );
+
+
+
+//=======================================================================
+//function :
+//purpose :
+//=======================================================================
+ GEOMAlgo_BuilderSolid::GEOMAlgo_BuilderSolid()
+:
+ GEOMAlgo_BuilderArea()
+{
+}
+//=======================================================================
+//function : ~
+//purpose :
+//=======================================================================
+ GEOMAlgo_BuilderSolid::~GEOMAlgo_BuilderSolid()
+{
+}
+//=======================================================================
+//function : Perform
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderSolid::Perform()
+{
+ myErrorStatus=0;
+ //
+ //
+ TopoDS_Compound aC;
+ BRep_Builder aBB;
+ TopTools_ListIteratorOfListOfShape aIt;
+
+ aBB.MakeCompound(aC);
+ aIt.Initialize(myShapes);
+ for(; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ aBB.Add(aC, aF);
+ }
+ //
+ //
+ if (myContext==NULL) {
+ myErrorStatus=11;// Null Context
+ return;
+ }
+ //
+ PerformShapesToAvoid();
+ if (myErrorStatus) {
+ return;
+ }
+ //
+ PerformLoops();
+ if (myErrorStatus) {
+ return;
+ }
+ PerformAreas();
+ if (myErrorStatus) {
+ return;
+ }
+ PerformInternalShapes();
+ if (myErrorStatus) {
+ return;
+ }
+}
+//=======================================================================
+//function :PerformShapesToAvoid
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderSolid::PerformShapesToAvoid()
+{
+ Standard_Boolean bFound;
+ Standard_Integer i, iCnt, aNbE, aNbF;
+ TopAbs_Orientation aOrE;
+ TopTools_IndexedDataMapOfShapeListOfShape aMEF;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ myShapesToAvoid.Clear();
+ //
+ iCnt=0;
+ while (1) {
+ ++iCnt;
+ bFound=Standard_False;
+ //
+ // 1. MEF
+ aMEF.Clear();
+ aIt.Initialize (myShapes);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ if (!myShapesToAvoid.Contains(aF)) {
+ TopExp::MapShapesAndAncestors(aF, TopAbs_EDGE, TopAbs_FACE, aMEF);
+ }
+ else {
+ int a=0;
+ }
+ }
+ aNbE=aMEF.Extent();
+ //
+ // 2. myFacesToAvoid
+ for (i=1; i<=aNbE; ++i) {
+ const TopoDS_Edge& aE=TopoDS::Edge(aMEF.FindKey(i));
+ if (BRep_Tool::Degenerated(aE)) {
+ continue;
+ }
+ //
+ TopTools_ListOfShape& aLF=aMEF.ChangeFromKey(aE);
+ //
+ aNbF=aLF.Extent();
+ if (!aNbF) {
+ continue;
+ }
+ //
+ aOrE=aE.Orientation();
+ //
+ const TopoDS_Face& aF1=TopoDS::Face(aLF.First());
+ if (aNbF==1) {
+ if (aOrE==TopAbs_INTERNAL) {
+ continue;
+ }
+ bFound=Standard_True;
+ myShapesToAvoid.Add(aF1);
+ }
+ else if (aNbF==2) {
+ const TopoDS_Face& aF2=TopoDS::Face(aLF.Last());
+ if (aF2.IsSame(aF1)) {
+ if (BRep_Tool::IsClosed(aE, aF1)) {
+ continue;
+ }
+ //
+ if (aOrE==TopAbs_INTERNAL) {
+ continue;
+ }
+ //
+ bFound=Standard_True;
+ myShapesToAvoid.Add(aF1);
+ myShapesToAvoid.Add(aF2);
+ }
+ }
+ }// for (i=1; i<=aNbE; ++i) {
+ //
+ if (!bFound) {
+ break;
+ }
+ //
+ }//while (1)
+}
+//=======================================================================
+//function : PerformLoops
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderSolid::PerformLoops()
+{
+ myErrorStatus=0;
+ //
+ myLoops.Clear();
+ //
+ Standard_Integer aNbLF, aNbOff, aNbFP;
+ TopAbs_Orientation anOr;
+ TopoDS_Edge aEL;
+ BRep_Builder aBB;
+ NMTTools_CoupleOfShape aCSOff;
+ TopTools_MapOfOrientedShape AddedFacesMap;
+ TopTools_IndexedDataMapOfShapeListOfShape aEFMap, aMEFP;
+ TopTools_ListIteratorOfListOfShape aItF;
+ //
+ //=================================================
+ //
+ // 1. Shells Usual
+ //
+ aItF.Initialize (myShapes);
+ for (; aItF.More(); aItF.Next()) {
+ const TopoDS_Shape& aFF = aItF.Value();
+ TopExp::MapShapesAndAncestors(aFF, TopAbs_EDGE, TopAbs_FACE, aEFMap);
+ }
+ //
+ aItF.Initialize (myShapes);
+ for (; aItF.More(); aItF.Next()) {
+ const TopoDS_Shape& aFF = aItF.Value();
+ if (myShapesToAvoid.Contains(aFF)) {
+ continue;
+ }
+ if (!AddedFacesMap.Add(aFF)) {
+ continue;
+ }
+ //
+ // make a new shell
+ TopoDS_Shell aShell;
+ aBB.MakeShell(aShell);
+ aBB.Add(aShell, aFF);
+ //
+ aMEFP.Clear();
+ TopExp::MapShapesAndAncestors(aFF, TopAbs_EDGE, TopAbs_FACE, aMEFP);
+ //
+ // loop on faces added to Shell; add their neighbor faces to Shell and so on
+ TopoDS_Iterator aItAddedF (aShell);
+ for (; aItAddedF.More(); aItAddedF.Next()) {
+ const TopoDS_Face& aF = TopoDS::Face(aItAddedF.Value());
+ //
+ // loop on edges of aF; find a good neighbor face of aF by aE
+ TopExp_Explorer aEdgeExp(aF, TopAbs_EDGE);
+ for (; aEdgeExp.More(); aEdgeExp.Next()) {
+ const TopoDS_Edge& aE = TopoDS::Edge(aEdgeExp.Current());
+ //
+ //1
+ if (aMEFP.Contains(aE)) {
+ const TopTools_ListOfShape& aLFP=aMEFP.FindFromKey(aE);
+ aNbFP=aLFP.Extent();
+ if (aNbFP>1) {
+ continue;
+ }
+ }
+ //2
+ anOr=aE.Orientation();
+ if (anOr==TopAbs_INTERNAL) {
+ continue;
+ }
+ //3
+ if (BRep_Tool::Degenerated(aE)) {
+ continue;
+ }
+ //
+ // candidate faces list
+ const TopTools_ListOfShape& aLF=aEFMap.FindFromKey(aE);
+ aNbLF=aLF.Extent();
+ if (!aNbLF) {
+ continue;
+ }
+ //
+ // try to select one of neighbors
+ // check if a face already added to Shell shares E
+ Standard_Boolean bFound;
+ TopTools_ListIteratorOfListOfShape aItLF;
+ NMTTools_ListOfCoupleOfShape aLCSOff;
+ //
+ aItLF.Initialize(aLF);
+ for (; aItLF.More(); aItLF.Next()) {
+ const TopoDS_Face& aFL=TopoDS::Face(aItLF.Value());
+ if (myShapesToAvoid.Contains(aFL)) {
+ continue;
+ }
+ if (aF.IsSame(aFL)) {
+ continue;
+ }
+ if (AddedFacesMap.Contains(aFL)){
+ continue;
+ }
+ //
+ bFound=GEOMAlgo_Tools3D::GetEdgeOff(aE, aFL, aEL);
+ if (!bFound) {
+ continue;
+ }
+ //
+ aCSOff.SetShape1(aEL);
+ aCSOff.SetShape2(aFL);
+ aLCSOff.Append(aCSOff);
+ }//for (; aItLF.More(); aItLF.Next()) {
+ //
+ aNbOff=aLCSOff.Extent();
+ if (!aNbOff){
+ continue;
+ }
+ //
+ TopoDS_Face aSelF;
+ if (aNbOff==1) {
+ aSelF=TopoDS::Face(aLCSOff.First().Shape2());
+ }
+ else if (aNbOff>1){
+ GEOMAlgo_Tools3D::GetFaceOff(aE, aF, aLCSOff, aSelF);
+ }
+ //
+ if (!aSelF.IsNull() && AddedFacesMap.Add(aSelF)) {
+ aBB.Add(aShell, aSelF);
+ TopExp::MapShapesAndAncestors(aSelF, TopAbs_EDGE, TopAbs_FACE, aMEFP);
+ }
+ } // for (; aEdgeExp.More(); aEdgeExp.Next()) {
+ } //for (; aItAddedF.More(); aItAddedF.Next()) {
+ myLoops.Append(aShell);
+ } // for (; aItF.More(); aItF.Next()) {
+ //=================================================
+ //
+ // 2.Internal Shells
+ //
+ myLoopsInternal.Clear();
+ //
+ Standard_Integer aNbFA;
+ TopTools_MapIteratorOfMapOfOrientedShape aItM;
+ //
+ aEFMap.Clear();
+ AddedFacesMap.Clear();
+ //
+ aNbFA=myShapesToAvoid.Extent();
+ //
+ aItM.Initialize(myShapesToAvoid);
+ for (; aItM.More(); aItM.Next()) {
+ const TopoDS_Shape& aFF=aItM.Key();
+ TopExp::MapShapesAndAncestors(aFF, TopAbs_EDGE, TopAbs_FACE, aEFMap);
+ }
+ //
+ aItM.Initialize(myShapesToAvoid);
+ for (; aItM.More(); aItM.Next()) {
+ const TopoDS_Shape& aFF=aItM.Key();
+ if (!AddedFacesMap.Add(aFF)) {
+ continue;
+ }
+ //
+ // make a new shell
+ TopoDS_Shell aShell;
+ aBB.MakeShell(aShell);
+ aBB.Add(aShell, aFF);
+ //
+ TopoDS_Iterator aItAddedF (aShell);
+ for (; aItAddedF.More(); aItAddedF.Next()) {
+ const TopoDS_Face& aF = TopoDS::Face(aItAddedF.Value());
+ //
+ TopExp_Explorer aEdgeExp(aF, TopAbs_EDGE);
+ for (; aEdgeExp.More(); aEdgeExp.Next()) {
+ const TopoDS_Edge& aE = TopoDS::Edge(aEdgeExp.Current());
+ const TopTools_ListOfShape& aLF=aEFMap.FindFromKey(aE);
+ aItF.Initialize(aLF);
+ for (; aItF.More(); aItF.Next()) {
+ const TopoDS_Face& aFL=TopoDS::Face(aItF.Value());
+ if (AddedFacesMap.Add(aFL)){
+ aBB.Add(aShell, aFL);
+ }
+ }
+ }
+ }
+ myLoopsInternal.Append(aShell);
+ }
+}
+//=======================================================================
+//function : PerformAreas
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderSolid::PerformAreas()
+{
+ myErrorStatus=0;
+ //
+ Standard_Boolean bIsGrowthShell, bIsHole;
+ TopTools_ListOfShape aNewSolids, aHoleShells;
+ TopoDS_Shape anInfinitePointShape;
+ TopTools_DataMapOfShapeShape aInOutMap;
+ TopTools_DataMapOfShapeListOfShape aMSH;
+ TopTools_DataMapIteratorOfDataMapOfShapeListOfShape aItMSH;
+ TopTools_ListIteratorOfListOfShape aShellIt, aSolidIt;
+ TopTools_IndexedMapOfShape aMHF;
+ BRep_Builder aBB;
+ //
+ myAreas.Clear();
+ //
+ // Draft solids [aNewSolids]
+ aShellIt.Initialize(myLoops);
+ for ( ; aShellIt.More(); aShellIt.Next()) {
+ const TopoDS_Shape& aShell = aShellIt.Value();
+ //
+ bIsGrowthShell=IsGrowthShell(aShell, aMHF);
+ if (bIsGrowthShell) {
+ // make a growth solid from a shell
+ TopoDS_Solid Solid;
+ aBB.MakeSolid(Solid);
+ aBB.Add (Solid, aShell);
+ //
+ aNewSolids.Append (Solid);
+ }
+ else{
+ // check if a shell is a hole
+ //XX
+ bIsHole=IsHole(aShell, myContext);
+ //bIsHole=GEOMAlgo_BuilderTools::IsHole(aShell);
+ //XX
+ if (bIsHole) {
+ aHoleShells.Append(aShell);
+ TopExp::MapShapes(aShell, TopAbs_FACE, aMHF);
+ }
+ else {
+ // make a growth solid from a shell
+ TopoDS_Solid Solid;
+ aBB.MakeSolid(Solid);
+ aBB.Add (Solid, aShell);
+ //
+ aNewSolids.Append (Solid);
+ }
+ }
+ }
+ //
+ // 2. Find outer growth shell that is most close to each hole shell
+ aShellIt.Initialize(aHoleShells);
+ for (; aShellIt.More(); aShellIt.Next()) {
+ const TopoDS_Shape& aHole = aShellIt.Value();
+ //
+ aSolidIt.Initialize(aNewSolids);
+ for ( ; aSolidIt.More(); aSolidIt.Next()) {
+ const TopoDS_Shape& aSolid = aSolidIt.Value();
+ //
+ if (!IsInside(aHole, aSolid, myContext)){
+ continue;
+ }
+ //
+ if ( aInOutMap.IsBound (aHole)){
+ const TopoDS_Shape& aSolid2 = aInOutMap(aHole);
+ if (IsInside(aSolid, aSolid2, myContext)) {
+ aInOutMap.UnBind(aHole);
+ aInOutMap.Bind (aHole, aSolid);
+ }
+ }
+ else{
+ aInOutMap.Bind (aHole, aSolid);
+ }
+ }
+ //
+ // Add aHole to a map Solid/ListOfHoles [aMSH]
+ if (aInOutMap.IsBound(aHole)){
+ const TopoDS_Shape& aSolid=aInOutMap(aHole);
+ if (aMSH.IsBound(aSolid)) {
+ TopTools_ListOfShape& aLH=aMSH.ChangeFind(aSolid);
+ aLH.Append(aHole);
+ }
+ else {
+ TopTools_ListOfShape aLH;
+ aLH.Append(aHole);
+ aMSH.Bind(aSolid, aLH);
+ }
+ //aBB.Add (aSolid, aHole);
+ }
+ }// for (; aShellIt.More(); aShellIt.Next()) {
+ //
+ // 3. Add aHoles to Solids
+ aItMSH.Initialize(aMSH);
+ for (; aItMSH.More(); aItMSH.Next()) {
+ TopoDS_Solid aSolid=TopoDS::Solid(aItMSH.Key());
+ //
+ const TopTools_ListOfShape& aLH=aItMSH.Value();
+ aShellIt.Initialize(aLH);
+ for (; aShellIt.More(); aShellIt.Next()) {
+ const TopoDS_Shape& aHole = aShellIt.Value();
+ aBB.Add (aSolid, aHole);
+ }
+ //
+ // update classifier
+ BRepClass3d_SolidClassifier& aSC=myContext->SolidClassifier(aSolid);
+ aSC.Load(aSolid);
+ //
+ }
+ //
+ // These aNewSolids are draft solids that
+ // do not contain any internal shapes
+ //
+ myAreas.Append(aNewSolids);
+}
+//=======================================================================
+//function : PerformInternalShapes
+//purpose :
+//=======================================================================
+ void GEOMAlgo_BuilderSolid::PerformInternalShapes()
+{
+ myErrorStatus=0;
+ //
+ Standard_Integer aNbFI=myLoopsInternal.Extent();
+ if (!aNbFI) {// nothing to do
+ return;
+ }
+ //
+ BRep_Builder aBB;
+ TopTools_ListIteratorOfListOfShape aShellIt, aSolidIt;
+ TopoDS_Iterator aIt;
+ TopTools_MapOfShape aMF, aMFP;
+ TopTools_MapIteratorOfMapOfShape aItMF;
+ TopTools_IndexedDataMapOfShapeListOfShape aMEF;
+ TopTools_ListOfShape aLSI;
+ //
+ // 1. All internal faces
+ aShellIt.Initialize(myLoopsInternal);
+ for (; aShellIt.More(); aShellIt.Next()) {
+ const TopoDS_Shape& aShell=aShellIt.Value();
+ aIt.Initialize(aShell);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ aMF.Add(aF);
+ }
+ }
+ aNbFI=aMF.Extent();
+ //
+ // 2 Process solids
+ aSolidIt.Initialize(myAreas);
+ for ( ; aSolidIt.More(); aSolidIt.Next()) {
+ TopoDS_Solid& aSolid=TopoDS::Solid(aSolidIt.Value());
+ //
+ aMEF.Clear();
+ TopExp::MapShapesAndAncestors(aSolid, TopAbs_EDGE, TopAbs_FACE, aMEF);
+ //
+ // 2.1 Separate faces to process aMFP
+ aMFP.Clear();
+ aItMF.Initialize(aMF);
+ for (; aItMF.More(); aItMF.Next()) {
+ const TopoDS_Face& aF=TopoDS::Face(aItMF.Key());
+ if (GEOMAlgo_Tools3D::IsInternalFace(aF, aSolid, aMEF, 1.e-14, *myContext)) {
+ aMFP.Add(aF);
+ }
+ }
+ //
+ // 2.2 Make Internal Shells
+ aLSI.Clear();
+ MakeInternalShells(aMFP, aLSI);
+ //
+ // 2.3 Add them to aSolid
+ aShellIt.Initialize(aLSI);
+ for (; aShellIt.More(); aShellIt.Next()) {
+ const TopoDS_Shape& aSI=aShellIt.Value();
+ aBB.Add (aSolid, aSI);
+ }
+ //
+ // 2.4 Remove faces aMFP from aMF
+ aItMF.Initialize(aMFP);
+ for (; aItMF.More(); aItMF.Next()) {
+ const TopoDS_Shape& aF=aItMF.Key();
+ aMF.Remove(aF);
+ }
+ //
+ aNbFI=aMF.Extent();
+ if (!aNbFI) {
+ break;
+ }
+ } //for ( ; aSolidIt.More(); aSolidIt.Next()) {
+}
+
+//=======================================================================
+//function : MakeInternalShells
+//purpose :
+//=======================================================================
+void MakeInternalShells(const TopTools_MapOfShape& theMF,
+ TopTools_ListOfShape& theShells)
+{
+ TopTools_MapIteratorOfMapOfShape aItM;
+ TopTools_MapOfShape aAddedFacesMap;
+ TopTools_ListIteratorOfListOfShape aItF;
+ TopTools_IndexedDataMapOfShapeListOfShape aMEF;
+ BRep_Builder aBB;
+ //
+ aItM.Initialize(theMF);
+ for (; aItM.More(); aItM.Next()) {
+ const TopoDS_Shape& aF=aItM.Key();
+ TopExp::MapShapesAndAncestors(aF, TopAbs_EDGE, TopAbs_FACE, aMEF);
+ }
+ //
+ aItM.Initialize(theMF);
+ for (; aItM.More(); aItM.Next()) {
+ TopoDS_Shape aFF=aItM.Key();
+ if (!aAddedFacesMap.Add(aFF)) {
+ continue;
+ }
+ //
+ // make a new shell
+ TopoDS_Shell aShell;
+ aBB.MakeShell(aShell);
+ aFF.Orientation(TopAbs_INTERNAL);
+ aBB.Add(aShell, aFF);
+ //
+ TopoDS_Iterator aItAddedF (aShell);
+ for (; aItAddedF.More(); aItAddedF.Next()) {
+ const TopoDS_Shape& aF =aItAddedF.Value();
+ //
+ TopExp_Explorer aEdgeExp(aF, TopAbs_EDGE);
+ for (; aEdgeExp.More(); aEdgeExp.Next()) {
+ const TopoDS_Shape& aE =aEdgeExp.Current();
+ const TopTools_ListOfShape& aLF=aMEF.FindFromKey(aE);
+ aItF.Initialize(aLF);
+ for (; aItF.More(); aItF.Next()) {
+ TopoDS_Shape aFL=aItF.Value();
+ if (aAddedFacesMap.Add(aFL)){
+ aFL.Orientation(TopAbs_INTERNAL);
+ aBB.Add(aShell, aFL);
+ }
+ }
+ }
+ }
+ theShells.Append(aShell);
+ }
+}
+//=======================================================================
+//function : IsHole
+//purpose :
+//=======================================================================
+Standard_Boolean IsHole(const TopoDS_Shape& theS2,
+ IntTools_PContext& theContext)
+{
+ TopoDS_Solid *pS2=(TopoDS_Solid *)&theS2;
+ BRepClass3d_SolidClassifier& aClsf=theContext->SolidClassifier(*pS2);
+ //
+ aClsf.PerformInfinitePoint(::RealSmall());
+ //
+ return (aClsf.State()==TopAbs_IN);
+}
+//=======================================================================
+//function : IsInside
+//purpose :
+//=======================================================================
+Standard_Boolean IsInside(const TopoDS_Shape& theS1,
+ const TopoDS_Shape& theS2,
+ IntTools_PContext& theContext)
+{
+ TopExp_Explorer aExp;
+ TopAbs_State aState;
+ //
+ TopoDS_Solid *pS2=(TopoDS_Solid *)&theS2;
+ //
+ aExp.Init(theS1, TopAbs_FACE);
+ if (!aExp.More()){
+ BRepClass3d_SolidClassifier& aClsf=theContext->SolidClassifier(*pS2);
+ aClsf.PerformInfinitePoint(::RealSmall());
+ aState=aClsf.State();
+ }
+ else {
+ TopTools_IndexedMapOfShape aBounds;
+ const TopoDS_Face& aF = TopoDS::Face(aExp.Current());
+ aState=GEOMAlgo_Tools3D::ComputeState(aF, *pS2, 1.e-14, aBounds, *theContext);
+ }
+ return (aState==TopAbs_IN);
+}
+//=======================================================================
+//function : IsGrowthShell
+//purpose :
+//=======================================================================
+Standard_Boolean IsGrowthShell(const TopoDS_Shape& theShell,
+ const TopTools_IndexedMapOfShape& theMHF)
+{
+ Standard_Boolean bRet;
+ TopoDS_Iterator aIt;
+ //
+ bRet=Standard_False;
+ if (theMHF.Extent()) {
+ aIt.Initialize(theShell);
+ for(; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ if (theMHF.Contains(aF)) {
+ return !bRet;
+ }
+ }
+ }
+ return bRet;
+}
+
+//BRepTools::Write(aFF, "ff");
+//
+// ErrorStatus :
+// 11 - Null Context
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_BuilderSolid_HeaderFile
+#define _GEOMAlgo_BuilderSolid_HeaderFile
+
+#ifndef _GEOMAlgo_BuilderArea_HeaderFile
+#include <GEOMAlgo_BuilderArea.hxx>
+#endif
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+//! The algorithm to build solids from set of faces <br>
+class GEOMAlgo_BuilderSolid : public GEOMAlgo_BuilderArea {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+//! Empty constructor <br>
+Standard_EXPORT GEOMAlgo_BuilderSolid();
+Standard_EXPORT virtual ~GEOMAlgo_BuilderSolid();
+
+//! Performs the algorithm <br>
+Standard_EXPORT virtual void Perform() ;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+//! Collect the faces that <br>
+//! a) are internal <br>
+//! b) are the same and have different orientation <br>
+Standard_EXPORT virtual void PerformShapesToAvoid() ;
+
+//! Build draft shells <br>
+//! a)myLoops - draft shells that consist of <br>
+//! boundary faces <br>
+//! b)myLoopsInternal - draft shells that contains <br>
+//! inner faces <br>
+Standard_EXPORT virtual void PerformLoops() ;
+
+//! Build draft solids that contains boundary faces <br>
+Standard_EXPORT virtual void PerformAreas() ;
+
+//! Build finalized solids with internal shells <br>
+Standard_EXPORT virtual void PerformInternalShapes() ;
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_BuilderSolid.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_BuilderSolid_HeaderFile
+#include <GEOMAlgo_BuilderSolid.hxx>
+#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_BuilderTools.cdl
+-- Created:
+-- Author: Peter KURNEV
+-- <pkv@irinox>
+
+
+class BuilderTools from GEOMAlgo
+
+ ---Purpose:
+
+uses
+ Shape from TopoDS
+
+--raises
+
+is
+ IsHole(myclass;
+ aW: Shape from TopoDS;
+ aF: Shape from TopoDS)
+ returns Boolean from Standard;
+
+ IsHole(myclass;
+ aShell: Shape from TopoDS)
+ returns Boolean from Standard;
+
+--fields
+
+end BuilderTools;
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_BuilderTools.cxx
+// Created:
+// Author: Peter KURNEV
+// <pkv@irinox>
+
+
+#include <GEOMAlgo_BuilderTools.ixx>
+
+#include <TColStd_Array1OfReal.hxx>
+
+#include <gp_Pnt2d.hxx>
+#include <gp_Vec.hxx>
+#include <gp_Dir.hxx>
+#include <gp_Pnt.hxx>
+
+#include <TColgp_Array1OfPnt.hxx>
+
+#include <Poly_Triangulation.hxx>
+#include <Poly_Array1OfTriangle.hxx>
+#include <Poly_Triangle.hxx>
+
+#include <Geom2d_Curve.hxx>
+#include <Geom2dInt_Geom2dCurveTool.hxx>
+
+#include <TopLoc_Location.hxx>
+#include <TopAbs_Orientation.hxx>
+
+#include <TopoDS_Face.hxx>
+#include <TopoDS_Iterator.hxx>
+#include <TopoDS_Wire.hxx>
+#include <TopoDS.hxx>
+#include <TopoDS_Edge.hxx>
+#include <TopExp_Explorer.hxx>
+
+#include <BRep_Tool.hxx>
+#include <BRepBndLib.hxx>
+#include <BRepMesh_FastDiscret.hxx>
+#include <Bnd_Box.hxx>
+#include <BRepAdaptor_Curve2d.hxx>
+
+static
+ Standard_Integer ComputeProps(const TopoDS_Face& aF,
+ Standard_Real& aA,
+ Standard_Real& aV);
+static
+ void BuildTriangulation(const TopoDS_Face& aF);
+
+//=======================================================================
+//function : IsHole
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_BuilderTools::IsHole(const TopoDS_Shape& aW,
+ const TopoDS_Shape& aFace)
+{
+ Standard_Boolean bIsHole;
+ Standard_Integer i, aNbS;
+ Standard_Real aT1, aT2, aS;
+ Standard_Real aU1, aU2, aU, dU;
+ Standard_Real aX1, aY1, aX0, aY0;
+ TopAbs_Orientation aOr;
+
+ gp_Pnt2d aP2D0, aP2D1;
+ Handle(Geom2d_Curve) aC2D;
+ TopoDS_Face aF, aFF;
+ TopoDS_Iterator aItW;
+ //
+ bIsHole=Standard_False;
+ //
+ aF=TopoDS::Face(aFace);
+ aFF=aF;
+ aFF.Orientation(TopAbs_FORWARD);
+ //
+ aS=0.;
+ aItW.Initialize(aW);
+ for (; aItW.More(); aItW.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(aItW.Value());
+ aOr=aE.Orientation();
+ if (!(aOr==TopAbs_FORWARD ||
+ aOr==TopAbs_REVERSED)) {
+ continue;
+ }
+ //
+ aC2D=BRep_Tool::CurveOnSurface(aE, aFF, aT1, aT2);
+ if (aC2D.IsNull()) {
+ break; //xx
+ }
+ //
+ BRepAdaptor_Curve2d aBAC2D(aE, aFF);
+ aNbS=Geom2dInt_Geom2dCurveTool::NbSamples(aBAC2D);
+ if (aNbS>2) {
+ aNbS*=4;
+ }
+ //
+ dU=(aT2-aT1)/(Standard_Real)(aNbS-1);
+ aU =aT1;
+ aU1=aT1;
+ aU2=aT2;
+ if (aOr==TopAbs_REVERSED) {
+ aU =aT2;
+ aU1=aT2;
+ aU2=aT1;
+ dU=-dU;
+ }
+ //
+ aC2D->D0(aU, aP2D0);
+ for(i=2; i<=aNbS; i++) {
+ aU=aU1+(i-1)*dU;
+ aC2D->D0(aU, aP2D1);
+ aP2D0.Coord(aX0, aY0);
+ aP2D1.Coord(aX1, aY1);
+ //
+ aS=aS+(aY0+aY1)*(aX1-aX0);
+ //
+ aP2D0=aP2D1;
+ }
+ }//for (; aItW.More(); aItW.Next()) {
+ bIsHole=(aS>0.);
+ return bIsHole;
+}
+//=======================================================================
+//function : IsHole
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_BuilderTools::IsHole(const TopoDS_Shape& aShell)
+{
+ Standard_Boolean bIsHole;
+ Standard_Integer iRet;
+ Standard_Real aAi, aA, aV, aVi;
+ TopExp_Explorer aExp;
+ //
+ aA=0.;
+ aV=0.;
+ aExp.Init(aShell, TopAbs_FACE);
+ for (; aExp.More(); aExp.Next()) {
+ const TopoDS_Face& aF=TopoDS::Face(aExp.Current());
+ iRet=ComputeProps(aF, aAi, aVi);
+ if (!iRet) {
+ aA+=aAi;
+ aV+=aVi;
+ }
+ }
+ //
+ bIsHole=aV<0.;
+ return bIsHole;
+}
+//=======================================================================
+//function : ComputeProps
+//purpose :
+//=======================================================================
+Standard_Integer ComputeProps(const TopoDS_Face& aF,
+ Standard_Real& aA,
+ Standard_Real& aV)
+{
+ Standard_Integer j, i, i1, i2, aNbNodes, aNbTrigs, n[3];
+ Standard_Real aAi, aVi;
+ gp_Pnt aP[3], aGC, aGC1;
+ TopLoc_Location aLoc;
+ TopAbs_Orientation aOr;
+ Handle(Poly_Triangulation) aTri;
+ //
+ aA=0.;
+ aV=0.;
+ //
+ aTri=BRep_Tool::Triangulation(aF, aLoc);
+ if(aTri.IsNull()) {
+ BuildTriangulation(aF);
+ aTri=BRep_Tool::Triangulation(aF, aLoc);
+ if(aTri.IsNull()) {
+ return 1;// a face is without triangulation
+ }
+ }
+ //
+ aNbNodes=aTri->NbNodes();
+ aNbTrigs=aTri->NbTriangles();
+ if (!aNbTrigs){
+ return 2;//no triangles
+ }
+ //
+ aOr=aF.Orientation();
+ //
+ const TColgp_Array1OfPnt& aNodes=aTri->Nodes();
+ const Poly_Array1OfTriangle& aTriangles=aTri->Triangles();
+ //
+ i1=aTriangles.Lower();
+ i2=aTriangles.Upper();
+ //
+ for (i=i1; i<=i2; ++i){
+ const Poly_Triangle& aTriangle=aTriangles.Value(i);
+ aTriangle.Get(n[0], n[1], n[2]);
+ aGC.SetCoord(0.,0.,0.);
+ for (j=0; j<3; ++j) {
+ aP[j]=aNodes.Value(n[j]);
+ aGC.ChangeCoord()+=aP[j].XYZ();
+ }
+ aGC.ChangeCoord()*=0.333333333333;
+ //
+ // Normal
+ gp_Vec aV01(aP[0], aP[1]);
+ gp_Vec aV12(aP[1], aP[2]);
+ gp_Vec aVN=aV01^aV12;
+ aAi=aVN.Magnitude();
+ aA=aA+aAi;
+ //
+ if (aAi>0.0000001) {
+ Standard_Real aSx, aZx;
+ gp_Dir aDN(aVN);
+ if (aOr==TopAbs_REVERSED) {
+ aDN.Reverse();
+ }
+ //
+ aSx=aAi*aDN.Z();
+ aZx=aGC.Z();
+ aVi=aZx*aSx;
+ aV=aV+aVi;
+ }
+ }
+ return 0;
+}
+//=======================================================================
+//function : BuildTriangulation
+//purpose :
+//=======================================================================
+void BuildTriangulation(const TopoDS_Face& aF)
+{
+ Standard_Boolean bWithShare;
+ Standard_Real aDiscret, aXmin, aYmin, aZmin, aXmax, aYmax, aZmax;
+ Standard_Real dX, dY, dZ, dMax, aCoeff, aAngle;
+ Bnd_Box aBox;
+ //
+ bWithShare=Standard_False;
+ aAngle=0.5;
+ //
+ BRepBndLib::Add(aF, aBox);
+ //
+ // aDiscret
+ aBox.Get(aXmin, aYmin, aZmin, aXmax, aYmax, aZmax);
+ dX=aXmax-aXmin;
+ dY=aYmax-aYmin;
+ dZ=aZmax-aZmin;
+ dMax=dX;
+ if (dY>dMax) {
+ dMax=dY;
+ }
+ if (dZ>dMax) {
+ dMax=dZ;
+ }
+ //
+ aCoeff=0.1;
+ aDiscret=aCoeff*dMax;
+ //
+ BRepMesh_FastDiscret aMesher(aDiscret,
+ aAngle,
+ aBox,
+ bWithShare,
+ Standard_True,
+ Standard_False,
+ Standard_True);
+ aMesher.Add(aF);
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_BuilderTools_HeaderFile
+#define _GEOMAlgo_BuilderTools_HeaderFile
+
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class TopoDS_Shape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class GEOMAlgo_BuilderTools {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT static Standard_Boolean IsHole(const TopoDS_Shape& aW,const TopoDS_Shape& aF) ;
+
+
+Standard_EXPORT static Standard_Boolean IsHole(const TopoDS_Shape& aShell) ;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_BuilderTools.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _GEOMAlgo_BuilderTools_HeaderFile
+#include <GEOMAlgo_BuilderTools.hxx>
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_Builder.hxx>
+
+#include <NMTDS_ShapesDataStructure.hxx>
+#include <NMTTools_DSFiller.hxx>
+#include <NMTTools_PaveFiller.hxx>
+#include <IntTools_Context.hxx>
+#include <TopoDS_Shape.hxx>
+#include <BOPTools_ListIteratorOfListOfPaveBlock.hxx>
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
+#include <BOPTools_ListOfPaveBlock.hxx>
+#include <BOPTools_PaveBlock.hxx>
+
+//=======================================================================
+//function : Shapes1
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_Builder::Shapes1(const Standard_Integer theType)const
+{
+ return myShapes1[theType];
+}
+//=======================================================================
+//function : Images
+//purpose :
+//=======================================================================
+ const BRepAlgo_Image& GEOMAlgo_Builder::Images()const
+{
+ return myImages;
+}
+//=======================================================================
+//function : InParts
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_Builder::InParts(const TopoDS_Shape& theS)const
+{
+ static TopTools_ListOfShape sLS;
+ //
+ if (myInParts.Contains(theS)) {
+ return myInParts.FindFromKey(theS);
+ }
+ return sLS;
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_Builder_1.cxx
+// Created:
+// Author: Peter KURNEV
+
+#include <GEOMAlgo_Builder.hxx>
+//
+#include <TColStd_ListOfInteger.hxx>
+
+#include <TopoDS.hxx>
+#include <TopoDS_Shape.hxx>
+#include <TopoDS_Wire.hxx>
+#include <TopoDS_Edge.hxx>
+#include <TopoDS_Shell.hxx>
+#include <TopoDS_Iterator.hxx>
+//
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_MapIteratorOfMapOfShape.hxx>
+//
+#include <BRep_Tool.hxx>
+#include <BRep_Builder.hxx>
+//
+#include <IntTools_Context.hxx>
+#include <BOPTools_ListIteratorOfListOfPaveBlock.hxx>
+#include <BOPTools_ListOfPaveBlock.hxx>
+#include <BOPTools_PaveBlock.hxx>
+//
+#include <NMTDS_ShapesDataStructure.hxx>
+//
+#include <NMTTools_DSFiller.hxx>
+#include <NMTTools_PaveFiller.hxx>
+#include <NMTTools_CommonBlockPool.hxx>
+#include <NMTTools_ListIteratorOfListOfCommonBlock.hxx>
+#include <NMTTools_CommonBlock.hxx>
+#include <NMTTools_CommonBlockPool.hxx>
+#include <NMTTools_ListOfCommonBlock.hxx>
+#include <NMTTools_CommonBlockAPI.hxx>
+//
+#include <GEOMAlgo_Tools3D.hxx>
+#include <TColStd_ListIteratorOfListOfInteger.hxx>
+
+
+
+static
+ void FillImagesCompounds(const TopTools_MapOfShape& ,
+ BRepAlgo_Image& );
+
+static
+ void FillImagesCompound(const TopoDS_Shape& ,
+ BRepAlgo_Image& ,
+ TopTools_MapOfShape& );
+
+//=======================================================================
+//function : FillImagesVertices
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::FillImagesVertices()
+{
+ myErrorStatus=0;
+ //
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ //
+ Standard_Integer i, aNb, iV;
+ //
+ aNb=aDS.NumberOfShapesOfTheObject();
+ for (i=1; i<=aNb; ++i) {
+ const TopoDS_Shape& aV=aDS.Shape(i);
+ if (aV.ShapeType()==TopAbs_VERTEX) {
+ iV=pPF->FindSDVertex(i);
+ if (iV) {
+ const TopoDS_Shape& aVSD=aDS.Shape(iV);
+ if (!myImages.HasImage(aV)) {
+ myImages.Bind(aV, aVSD);
+ //
+ mySameDomainShapes.Add(aV, aVSD);
+ //
+ }
+ }
+ }
+ }
+}
+//=======================================================================
+// function: FillImagesEdges
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Builder::FillImagesEdges()
+{
+ myErrorStatus=0;
+ //
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ const BOPTools_SplitShapesPool& aSSP=pPF->SplitShapesPool();
+ NMTTools_CommonBlockPool& aCBP=pPF->ChangeCommonBlockPool();
+ IntTools_Context& aCtx=pPF->ChangeContext();
+ //
+ Standard_Boolean bToReverse;
+ Standard_Integer i, aNb, aNbSp, nSp, nSpR, nSpx;
+ TColStd_ListIteratorOfListOfInteger aItLB;
+ TColStd_ListOfInteger aLB;
+ TopoDS_Edge aEE, aESpR;
+ TopTools_MapOfShape aMFence;
+ TopTools_ListOfShape aLSp;
+ TopTools_ListIteratorOfListOfShape aIt1;
+ BOPTools_ListIteratorOfListOfPaveBlock aIt;
+ //
+ aNb=aDS.NumberOfShapesOfTheObject();
+ for (i=1; i<=aNb; ++i) {
+ const TopoDS_Shape& aE=aDS.Shape(i);
+ if (aE.ShapeType()!=TopAbs_EDGE) {
+ continue;
+ }
+ //
+ if (!aMFence.Add(aE)) {
+ continue;
+ }
+ //
+ const BOPTools_ListOfPaveBlock& aLPB=aSSP(aDS.RefEdge(i));
+ aNbSp=aLPB.Extent();
+ if (!aNbSp) {
+ continue;
+ }
+ //
+ aEE=TopoDS::Edge(aE);
+ aLSp.Clear();
+ //
+ if (aNbSp==1) {
+ const BOPTools_PaveBlock& aPB=aLPB.First();
+ nSp=aPB.Edge();
+ const TopoDS_Shape& aSp=aDS.Shape(nSp);
+ //
+ const BOPTools_PaveBlock& aPBR=pPF->RealPaveBlock(aPB, aLB);
+ nSpR=aPBR.Edge();
+ const TopoDS_Shape& aSpR=aDS.Shape(nSpR);
+ if (aSpR.IsSame(aSp) && aSpR.IsSame(aE)) {
+ continue;
+ }
+ //
+ aESpR=TopoDS::Edge(aSpR);
+ bToReverse=GEOMAlgo_Tools3D::IsSplitToReverse(aESpR, aEE, aCtx);
+ if (bToReverse) {
+ aESpR.Reverse();
+ }
+ aLSp.Append(aESpR);
+ //
+ aItLB.Initialize(aLB);
+ for (; aItLB.More(); aItLB.Next()) {
+ nSpx=aItLB.Value();
+ const TopoDS_Shape& aSpx=aDS.Shape(nSpx);
+ mySameDomainShapes.Add(aSpx ,aSpR);
+ }
+ //
+ //
+ }// if (aNbSp==1) {
+ else {
+ aIt.Initialize(aLPB);
+ for (; aIt.More(); aIt.Next()) {
+ const BOPTools_PaveBlock& aPB=aIt.Value();
+ const BOPTools_PaveBlock& aPBR=pPF->RealPaveBlock(aPB, aLB);
+ nSpR=aPBR.Edge();
+ const TopoDS_Shape& aSpR=aDS.Shape(nSpR);
+ //
+ aESpR=TopoDS::Edge(aSpR);
+ bToReverse=GEOMAlgo_Tools3D::IsSplitToReverse(aESpR, aEE, aCtx);
+ if (bToReverse) {
+ aESpR.Reverse();
+ }
+ aLSp.Append(aESpR);
+ //
+ aItLB.Initialize(aLB);
+ for (; aItLB.More(); aItLB.Next()) {
+ nSpx=aItLB.Value();
+ const TopoDS_Shape& aSpx=aDS.Shape(nSpx);
+ mySameDomainShapes.Add(aSpx ,aSpR);
+ }
+ //
+ }
+ }
+ //
+ myImages.Bind(aE, aLSp);
+
+ }//for (i=1; i<=aNb; ++i)
+}
+//=======================================================================
+// function: FillImagesContainers
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Builder::FillImagesContainers(const TopAbs_ShapeEnum theType)
+{
+ myErrorStatus=0;
+ //
+ Standard_Boolean bInterferred, bToReverse;
+ Standard_Integer i, aNbS;
+ TopAbs_ShapeEnum aType;
+ BRep_Builder aBB;
+ TopoDS_Iterator aIt;
+ TopTools_ListIteratorOfListOfShape aItIm;
+ TopTools_MapOfShape aMS;
+ TopTools_MapIteratorOfMapOfShape aItS;
+ //
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ IntTools_Context& aCtx= pPF->ChangeContext();
+ //
+ aNbS=aDS.NumberOfShapesOfTheObject();
+ for (i=1; i<=aNbS; ++i) {
+ const TopoDS_Shape& aC=aDS.Shape(i);
+ aType=aC.ShapeType();
+ if (aType==theType) {
+ aMS.Add(aC);
+ }
+ }
+ //
+ if (theType==TopAbs_COMPOUND) {
+ FillImagesCompounds(aMS, myImages);
+ return;
+ }
+ //
+ aItS.Initialize(aMS);
+ for (; aItS.More(); aItS.Next()) {
+ const TopoDS_Shape& aC=aItS.Key();
+ // whether the shape has image
+ bInterferred=Standard_False;
+ aIt.Initialize(aC);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ if (myImages.HasImage(aF)) {
+ bInterferred=!bInterferred;
+ break;
+ }
+ }
+ if (!bInterferred){
+ continue;
+ }
+ //
+ TopoDS_Shape aCIm;
+ GEOMAlgo_Tools3D::MakeContainer(theType, aCIm);
+ //
+ aIt.Initialize(aC);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ if (myImages.HasImage(aF)) {
+ const TopTools_ListOfShape& aLFIm=myImages.Image(aF);
+ aItIm.Initialize(aLFIm);
+ for (; aItIm.More(); aItIm.Next()) {
+ TopoDS_Shape aFIm=aItIm.Value();
+ //
+ bToReverse=GEOMAlgo_Tools3D::IsSplitToReverse(aFIm, aF, aCtx);
+ if (bToReverse) {
+ aFIm.Reverse();
+ }
+ aBB.Add(aCIm, aFIm);
+ }
+ }
+ else {
+ aBB.Add(aCIm, aF);
+ }
+ }
+ myImages.Bind(aC, aCIm);
+ }// for (; aItS.More(); aItS.Next()) {
+}
+//=======================================================================
+// function: FillImagesCompounds
+// purpose:
+//=======================================================================
+void FillImagesCompounds(const TopTools_MapOfShape& theMS,
+ BRepAlgo_Image& theImages)
+{
+ TopTools_MapOfShape aMFP;
+ TopTools_MapIteratorOfMapOfShape aItS;
+ //
+ aItS.Initialize(theMS);
+ for (; aItS.More(); aItS.Next()) {
+ const TopoDS_Shape& aC=aItS.Key();
+ FillImagesCompound(aC, theImages, aMFP);
+ }
+}
+//=======================================================================
+//function : FillImagesCompound
+//purpose :
+//=======================================================================
+void FillImagesCompound(const TopoDS_Shape& theS,
+ BRepAlgo_Image& theImages,
+ TopTools_MapOfShape& theMFP)
+{
+ Standard_Boolean bInterferred;
+ TopAbs_ShapeEnum aTypeX;
+ TopAbs_Orientation aOrX;
+ TopoDS_Iterator aIt;
+ BRep_Builder aBB;
+ TopTools_ListIteratorOfListOfShape aItIm;
+ //
+ if (!theMFP.Add(theS)) {
+ return;
+ }
+ //
+ bInterferred=Standard_False;
+ aIt.Initialize(theS);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aSX=aIt.Value();
+ aTypeX=aSX.ShapeType();
+ if (aTypeX==TopAbs_COMPOUND) {
+ FillImagesCompound(aSX, theImages, theMFP);
+ }
+ if (theImages.HasImage(aSX)) {
+ bInterferred=Standard_True;
+ }
+ }
+ if (!bInterferred){
+ return;
+ }
+ //
+ TopoDS_Shape aCIm;
+ GEOMAlgo_Tools3D::MakeContainer(TopAbs_COMPOUND, aCIm);
+ //
+ aIt.Initialize(theS);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aSX=aIt.Value();
+ aOrX=aSX.Orientation();
+ if (theImages.HasImage(aSX)) {
+ const TopTools_ListOfShape& aLFIm=theImages.Image(aSX);
+ aItIm.Initialize(aLFIm);
+ for (; aItIm.More(); aItIm.Next()) {
+ TopoDS_Shape aSXIm=aItIm.Value();
+ aSXIm.Orientation(aOrX);
+ aBB.Add(aCIm, aSXIm);
+ }
+ }
+ else {
+ aBB.Add(aCIm, aSX);
+ }
+ }
+ theImages.Bind(theS, aCIm);
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_Builder_2.cxx
+// Created:
+// Author: Peter KURNEV
+
+#include <GEOMAlgo_Builder.hxx>
+
+#include <TColStd_IndexedMapOfInteger.hxx>
+#include <TColStd_ListOfInteger.hxx>
+
+#include <TopAbs_Orientation.hxx>
+
+#include <TopoDS.hxx>
+#include <TopoDS_Face.hxx>
+#include <TopoDS_Edge.hxx>
+#include <TopoDS_Shape.hxx>
+#include <TopoDS_Compound.hxx>
+
+#include <TopTools_IndexedMapOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+
+#include <TopExp.hxx>
+#include <TopExp_Explorer.hxx>
+
+#include <BRep_Tool.hxx>
+#include <BRep_Builder.hxx>
+#include <BRepAlgo_Image.hxx>
+#include <BRepTools.hxx>
+
+#include <IntTools_Context.hxx>
+#include <IntTools_FClass2d.hxx>
+
+#include <BooleanOperations_OnceExplorer.hxx>
+#include <BOPTColStd_IndexedDataMapOfIntegerIndexedMapOfInteger.hxx>
+#include <BOPTools_ListOfPaveBlock.hxx>
+#include <BOPTools_ListIteratorOfListOfPaveBlock.hxx>
+#include <BOPTools_InterferencePool.hxx>
+#include <BOPTools_CArray1OfSSInterference.hxx>
+#include <BOPTools_SSInterference.hxx>
+#include <BOPTools_SequenceOfCurves.hxx>
+#include <BOPTools_Curve.hxx>
+#include <BOPTools_ListOfPaveBlock.hxx>
+#include <BOPTools_PaveBlock.hxx>
+#include <BOPTools_Tools3D.hxx>
+#include <BOPTools_CArray1OfVSInterference.hxx>
+#include <BOPTools_VSInterference.hxx>
+#include <BOPTools_ESInterference.hxx>
+#include <BOPTools_CArray1OfESInterference.hxx>
+
+#include <NMTDS_ShapesDataStructure.hxx>
+#include <NMTTools_DSFiller.hxx>
+#include <NMTTools_PaveFiller.hxx>
+#include <NMTTools_ListOfCoupleOfShape.hxx>
+#include <NMTTools_Tools.hxx>
+#include <NMTTools_CoupleOfShape.hxx>
+#include <NMTTools_IndexedDataMapOfShapeIndexedMapOfShape.hxx>
+#include <NMTTools_Tools.hxx>
+#include <NMTTools_ListIteratorOfListOfCommonBlock.hxx>
+#include <NMTTools_ListOfCommonBlock.hxx>
+#include <NMTTools_CommonBlock.hxx>
+#include <NMTTools_IndexedDataMapOfIndexedMapOfInteger.hxx>
+//
+#include <GEOMAlgo_Tools3D.hxx>
+#include <GEOMAlgo_WireEdgeSet.hxx>
+#include <GEOMAlgo_BuilderFace.hxx>
+
+static
+ void UpdateCandidates(const Standard_Integer ,
+ const Standard_Integer ,
+ NMTTools_IndexedDataMapOfIndexedMapOfInteger& );
+
+//=======================================================================
+//function : FillImagesFaces
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::FillImagesFaces()
+{
+ myErrorStatus=0;
+ //
+ FillIn2DParts();
+ BuildSplitFaces();
+ FillSameDomainFaces();
+ FillImagesFaces1();
+ FillInternalVertices();
+}
+//=======================================================================
+// function: FillIn2DParts
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Builder::FillIn2DParts()
+{
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ BOPTools_InterferencePool* pIP=(BOPTools_InterferencePool*)&myDSFiller->InterfPool();
+ BOPTools_CArray1OfSSInterference& aFFs=pIP->SSInterferences();
+ NMTTools_CommonBlockPool& aCBP=pPF->ChangeCommonBlockPool();
+ //
+ Standard_Integer j, nSpIn, nSpSc, aNbCurves;
+ Standard_Integer aNbS, nF, aNbCBP, n1, n2, aNbFFs, aNbSpIn;
+ TopTools_MapOfShape aMFence;
+ TopTools_ListOfShape aLSpIn;
+ TopoDS_Face aF;
+ NMTTools_ListIteratorOfListOfCommonBlock aItCB;
+ BOPTools_ListIteratorOfListOfPaveBlock aItPB;
+ //
+ myInParts.Clear();
+ //
+ aNbFFs=aFFs.Extent();
+ aNbCBP=aCBP.Extent();
+ //
+ aNbS=aDS.NumberOfShapesOfTheObject();
+ for (nF=1; nF<=aNbS; ++nF) {
+ if (aDS.GetShapeType(nF)!=TopAbs_FACE) {
+ continue;
+ }
+ //
+ aF=TopoDS::Face(aDS.Shape(nF));
+ //
+ aMFence.Clear();
+ aLSpIn.Clear();
+ //
+ // 1. In Parts
+ for (j=1; j<=aNbCBP; ++j) {
+ NMTTools_ListOfCommonBlock& aLCB=aCBP(j);
+ aItCB.Initialize(aLCB);
+ for (; aItCB.More(); aItCB.Next()) {
+ NMTTools_CommonBlock& aCB=aItCB.Value();
+ if (aCB.IsPaveBlockOnFace(nF)) {
+ const BOPTools_PaveBlock& aPB1=aCB.PaveBlock1();
+ nSpIn=aPB1.Edge();
+ const TopoDS_Shape& aSpIn=aDS.Shape(nSpIn);
+ if (aMFence.Add(aSpIn)){
+ aLSpIn.Append(aSpIn);
+ }
+ }
+ }
+ }
+ //
+ // 2. Section Parts
+ for (j=1; j<=aNbFFs; ++j) {
+ BOPTools_SSInterference& aFF=aFFs(j);
+ aFF.Indices(n1, n2);
+ if (!(n1==nF || n2==nF)) {
+ continue;
+ }
+ BOPTools_SequenceOfCurves& aSC=aFF.Curves();
+ aNbCurves=aSC.Length();
+ if (!aNbCurves) {
+ continue;
+ }
+ //
+ const BOPTools_Curve& aBC=aSC(1);
+ const BOPTools_ListOfPaveBlock& aLPB=aBC.NewPaveBlocks();
+ aItPB.Initialize(aLPB);
+ for (; aItPB.More(); aItPB.Next()) {
+ const BOPTools_PaveBlock& aPBSc=aItPB.Value();
+ nSpSc=aPBSc.Edge();
+ const TopoDS_Shape& aSpSc=aDS.Shape(nSpSc);
+ if (aMFence.Add(aSpSc)){
+ aLSpIn.Append(aSpSc);
+ }
+ }
+ }
+ aNbSpIn=aLSpIn.Extent();
+ if (aNbSpIn) {
+ myInParts.Add(aF, aLSpIn);
+ }
+ }//for (nF=1; nF<=aNbS; ++nF) {
+}
+//=======================================================================
+// function: BuildSplitFaces
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Builder::BuildSplitFaces()
+{
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ BOPTools_InterferencePool* pIP=(BOPTools_InterferencePool*)&myDSFiller->InterfPool();
+ BOPTools_CArray1OfSSInterference& aFFs=pIP->SSInterferences();
+ IntTools_Context& aCtx= pPF->ChangeContext();
+ //
+ Standard_Boolean bToReverse, bIsClosed, bIsDegenerated;
+ Standard_Integer i, aNb, aNbF, nF;
+ TopTools_MapOfShape aMFence;
+ TColStd_IndexedMapOfInteger aMFP;
+ TopExp_Explorer anExp;
+ TopoDS_Face aFF;
+ TopoDS_Edge aSp, aEE;
+ TopTools_ListIteratorOfListOfShape aIt;
+ TopAbs_Orientation anOriF, anOriE;
+ //
+ mySplitFaces.Clear();
+ //
+ // 1. Select Faces to process (MFP)
+ aNb=aDS.NumberOfShapesOfTheObject();
+ for (i=1; i<=aNb; ++i) {
+ const TopoDS_Shape& aF=aDS.Shape(i);
+ if (aF.ShapeType()!=TopAbs_FACE) {
+ continue;
+ }
+ if (!aMFence.Add(aF)) {
+ continue;
+ }
+ //
+ if (myInParts.Contains(aF)) {
+ aMFP.Add(i);
+ continue;
+ }
+ //
+ anExp.Init(aF, TopAbs_EDGE);
+ for (; anExp.More(); anExp.Next()) {
+ const TopoDS_Shape& aE=anExp.Current();
+ if (myImages.HasImage(aE)) {
+ aMFP.Add(i);
+ break;
+ }
+ }
+ //
+ //===
+ {
+ Standard_Integer aNbFFs, aNbSE, j, n1, n2;
+ //
+ aNbFFs=aFFs.Extent();
+ for (j=1; j<=aNbFFs; ++j) {
+ BOPTools_SSInterference& aFFj=aFFs(j);
+ aFFj.Indices(n1, n2);
+ if (!(n1==i || n2==i)) {
+ continue;
+ }
+ //
+ const TColStd_ListOfInteger& aLSE=aFFj.SharedEdges();
+ aNbSE=aLSE.Extent();
+ if (aNbSE) {
+ aMFP.Add(i);
+ }
+ }
+ }
+ //===
+ //
+ }// for (i=1; i<=aNb; ++i)
+ //
+ // 2. ProcessFaces
+ aNbF=aMFP.Extent();
+ for (i=1; i<=aNbF; ++i) {
+ nF=aMFP(i);
+ const TopoDS_Face& aF=TopoDS::Face(aDS.Shape(nF));
+ anOriF=aF.Orientation();
+ aFF=aF;
+ aFF.Orientation(TopAbs_FORWARD);
+ //
+ aMFence.Clear();
+ //
+ // 2.1. Fill WES
+ GEOMAlgo_WireEdgeSet aWES;
+ aWES.SetFace(aFF);
+ //
+ // 2.1.1. Add Split parts
+ anExp.Init(aFF, TopAbs_EDGE);
+ for (; anExp.More(); anExp.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(anExp.Current());
+ anOriE=aE.Orientation();
+ //
+ if (!myImages.HasImage(aE)) {
+ if (anOriE==TopAbs_INTERNAL) {
+ aEE=aE;
+ aEE.Orientation(TopAbs_FORWARD);
+ aWES.AddStartElement(aEE);
+ aEE.Orientation(TopAbs_REVERSED);
+ aWES.AddStartElement(aEE);
+ }
+ else {
+ aWES.AddStartElement(aE);
+ }
+ continue;
+ }
+ //
+ bIsDegenerated=BRep_Tool::Degenerated(aE);
+ bIsClosed=BRep_Tool::IsClosed(aE, aF);
+ //
+ const TopTools_ListOfShape& aLIE=myImages.Image(aE);
+ aIt.Initialize(aLIE);
+ for (; aIt.More(); aIt.Next()) {
+ aSp=TopoDS::Edge(aIt.Value());
+ //
+ if (bIsDegenerated) {
+ aSp.Orientation(anOriE);
+ aWES.AddStartElement(aSp);
+ continue;
+ }
+ //
+ if (anOriE==TopAbs_INTERNAL) {
+ aSp.Orientation(TopAbs_FORWARD);
+ aWES.AddStartElement(aSp);
+ aSp.Orientation(TopAbs_REVERSED);
+ aWES.AddStartElement(aSp);
+ continue;
+ }
+ //
+ if (bIsClosed){
+ if (aMFence.Add(aSp)) {
+ //
+ if (!BRep_Tool::IsClosed(aSp, aF)){
+ BOPTools_Tools3D::DoSplitSEAMOnFace(aSp, aF);
+ }
+ //
+ aSp.Orientation(TopAbs_FORWARD);
+ aWES.AddStartElement(aSp);
+ aSp.Orientation(TopAbs_REVERSED);
+ aWES.AddStartElement(aSp);
+ }
+ continue;
+ }// if (aMFence.Add(aSp))
+ //
+ aSp.Orientation(anOriE);
+ bToReverse=BOPTools_Tools3D::IsSplitToReverse1(aSp, aE, aCtx);
+ if (bToReverse) {
+ aSp.Reverse();
+ }
+ aWES.AddStartElement(aSp);
+ }// for (; aIt.More(); aIt.Next()) {
+ }// for (; anExp.More(); anExp.Next()) {
+ //
+ // 2.1.2. Add In2D Parts
+ if (myInParts.Contains(aF)) {
+ const TopTools_ListOfShape& aLE=myInParts.FindFromKey(aF);
+ aIt.Initialize(aLE);
+ for (; aIt.More(); aIt.Next()) {
+ aSp=TopoDS::Edge(aIt.Value());
+ //
+ aSp.Orientation(TopAbs_FORWARD);
+ aWES.AddStartElement(aSp);
+ //
+ aSp.Orientation(TopAbs_REVERSED);
+ aWES.AddStartElement(aSp);
+ }
+ }
+ //
+ // 2.2. Build images Faces
+ GEOMAlgo_BuilderFace aBF;
+ //
+ aBF.SetFace(aFF);
+ aBF.SetContext(aCtx);
+ const TopTools_ListOfShape& aSE=aWES.StartElements();
+ aBF.SetShapes(aSE);
+ //
+ aBF.Perform();
+ //
+ const TopTools_ListOfShape& aLF=aBF.Areas();
+ //
+ TopTools_ListOfShape aLFR;
+ //
+ aIt.Initialize(aLF);
+ for (; aIt.More(); aIt.Next()) {
+ TopoDS_Shape& aFR=aIt.Value();
+ if (anOriF==TopAbs_REVERSED) {
+ aFR.Orientation(TopAbs_REVERSED);
+ }
+ aLFR.Append(aFR);
+ }
+ //
+ // 2.3. Collect draft images Faces
+ mySplitFaces.Bind(aF, aLFR);
+ }//for (i=1; i<=aNbF; ++i)
+}
+//=======================================================================
+// function: FillSameDomainFaces
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Builder::FillSameDomainFaces()
+{
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ BOPTools_InterferencePool* pIP=(BOPTools_InterferencePool*)&myDSFiller->InterfPool();
+ BOPTools_CArray1OfSSInterference& aFFs=pIP->SSInterferences();
+ IntTools_Context& aCtx= pPF->ChangeContext();
+ //
+ Standard_Boolean bIsSDF;
+ Standard_Integer i, j, aNbFF, nF1, nF2, aNbPBInOn, aNbC, aNbSE;
+ TopTools_MapOfShape aMFence;
+ TopTools_ListIteratorOfListOfShape aItF1, aItF2;
+ NMTTools_ListOfCoupleOfShape aLCS;
+ //
+ //mySameDomainShapes.Clear();
+ //
+ // 1. For each FF find among images of faces
+ // all pairs of same domain faces (SDF) [=> aLCS]
+ aNbFF=aFFs.Extent();
+ for (i=1; i<=aNbFF; ++i) {
+ BOPTools_SSInterference& aFF=aFFs(i);
+ aFF.Indices(nF1, nF2);
+ //
+ const TopoDS_Face& aF1=TopoDS::Face(aDS.Shape(nF1));
+ const TopoDS_Face& aF2=TopoDS::Face(aDS.Shape(nF2));
+ //
+ // if there are no in/on 2D split parts the faces nF1, nF2
+ // can not be SDF
+ const BOPTools_ListOfPaveBlock& aLPBInOn=aFF.PaveBlocks();
+ aNbPBInOn=aLPBInOn.Extent();
+ //
+ //===
+ const TColStd_ListOfInteger& aLSE=aFF.SharedEdges();
+ aNbSE=aLSE.Extent();
+ if (!aNbPBInOn && !aNbSE) {
+ continue;
+ }
+ //===
+ //
+ // if there is at least one section edge between faces nF1, nF2
+ // they can not be SDF
+ BOPTools_SequenceOfCurves& aSC=aFF.Curves();
+ aNbC=aSC.Length();
+ if (aNbC) {
+ continue;
+ }
+ //
+ // the faces are suspected to be SDF.
+ // Try to find SDF among images of nF1, nF2
+ aMFence.Clear();
+ const TopTools_ListOfShape& aLF1=mySplitFaces.Image(aF1);
+ const TopTools_ListOfShape& aLF2=mySplitFaces.Image(aF2);
+ //
+ aItF1.Initialize(aLF1);
+ for (; aItF1.More(); aItF1.Next()) {
+ const TopoDS_Face& aF1x=TopoDS::Face(aItF1.Value());
+ //
+ aItF2.Initialize(aLF2);
+ for (; aItF2.More(); aItF2.Next()) {
+ const TopoDS_Face& aF2y=TopoDS::Face(aItF2.Value());
+ bIsSDF=NMTTools_Tools::AreFacesSameDomain(aF1x, aF2y, aCtx);
+ if (bIsSDF) {
+ if (aMFence.Contains(aF1x) ||
+ aMFence.Contains(aF2y)) {
+ continue;
+ }
+ aMFence.Add(aF1x);
+ aMFence.Add(aF2y);
+ //
+ NMTTools_CoupleOfShape aCS;
+ //
+ aCS.SetShape1(aF1x);
+ aCS.SetShape2(aF2y);
+ aLCS.Append(aCS);
+ //
+ if (aF1x==aF1) {
+ if (!mySplitFaces.HasImage(aF1)) {
+ mySplitFaces.Bind(aF1, aF1);
+ }
+ }
+ if (aF2y==aF2) {
+ if (!mySplitFaces.HasImage(aF2)) {
+ mySplitFaces.Bind(aF2, aF2);
+ }
+ }
+ //
+
+ }
+ }
+ }
+ }//for (i=1; i<=aNbFF; ++i)
+ //
+ aNbC=aLCS.Extent();
+ if (!aNbC) {
+ return;
+ }
+ //
+ // 2. Find Chains
+ NMTTools_IndexedDataMapOfShapeIndexedMapOfShape aMC;
+ //
+ NMTTools_Tools::FindChains(aLCS, aMC);
+ //
+ // 3. Fill the map of SDF mySameDomainFaces
+ aNbC=aMC.Extent();
+ for (i=1; i<=aNbC; ++i) {
+ const TopoDS_Shape& aF=aMC.FindKey(i);
+ const TopTools_IndexedMapOfShape& aMSDF=aMC(i);
+ //
+ aNbFF=aMSDF.Extent();
+ for (j=1; j<=aNbFF; ++j) {
+ const TopoDS_Shape& aFSD=aMSDF(j);
+ mySameDomainShapes.Add(aFSD, aF);
+ }
+ }
+ //
+}
+//=======================================================================
+// function: FillImagesFaces1
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Builder::FillImagesFaces1()
+{
+ Standard_Integer i, aNb, iSense;
+ TopoDS_Face aF, aFSp, aFSD;
+ TopTools_ListOfShape aLFx;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ //
+ aNb=aDS.NumberOfShapesOfTheObject();
+ for (i=1; i<=aNb; ++i) {
+ const TopoDS_Shape& aS=aDS.Shape(i);
+ if (aS.ShapeType()!=TopAbs_FACE) {
+ continue;
+ }
+ //
+ if (!mySplitFaces.HasImage(aS)) {
+ continue;
+ }
+ //
+ aF=TopoDS::Face(aS);
+ //
+ aLFx.Clear();
+ const TopTools_ListOfShape& aLF=mySplitFaces.Image(aF);
+ aIt.Initialize(aLF);
+ for (; aIt.More(); aIt.Next()) {
+ aFSp=TopoDS::Face(aIt.Value());
+ if (!mySameDomainShapes.Contains(aFSp)) {
+ aLFx.Append(aFSp);
+ }
+ else {
+ const TopoDS_Shape& aSx=mySameDomainShapes.FindFromKey(aFSp);
+ aFSD=TopoDS::Face(aSx);
+ iSense=GEOMAlgo_Tools3D::Sense(aFSp, aFSD);
+ if (iSense<0) {
+ aFSD.Reverse();
+ }
+ aLFx.Append(aFSD);
+ }
+ }
+ if (!myImages.HasImage(aF)) {//XX
+ myImages.Bind(aF, aLFx);
+ }
+ }
+}
+//=======================================================================
+// function: FillInternalVertices
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Builder::FillInternalVertices()
+{
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ BOPTools_InterferencePool* pIP=(BOPTools_InterferencePool*)&myDSFiller->InterfPool();
+ IntTools_Context& aCtx= pPF->ChangeContext();
+ //
+ BOPTools_CArray1OfSSInterference& aFFs=pIP->SSInterferences();
+ BOPTools_CArray1OfVSInterference& aVFs=pIP->VSInterferences();
+ BOPTools_CArray1OfESInterference& aEFs=pIP->ESInterferences();
+ const NMTTools_IndexedDataMapOfIndexedMapOfInteger& aMAV=pPF->AloneVertices();
+ //
+ Standard_Boolean bHasImage;
+ Standard_Integer i, j, nF, aNbS, nV, nVSD, n1, n2, iFlag;
+ Standard_Integer aNbVFs, aNbAVF, aNbEFs, aNbVC, aNbE, aNbV;
+ Standard_Real aU1, aU2, aTol;
+ NMTTools_IndexedDataMapOfIndexedMapOfInteger aMFMV;
+ TopTools_MapOfShape aMFence;
+ TopTools_ListIteratorOfListOfShape aIt, aItV;
+ BRep_Builder aBB;
+ //
+ // 1. Collect face-vertex candidates [aMFMV]
+ //
+ // 1.1. VFs
+ aNbVFs=aVFs.Extent();
+ for (i=1; i<=aNbVFs; ++i) {
+ const BOPTools_VSInterference& aVS=aVFs(i);
+ aVS.Indices(n1, n2);
+ nF=n2;
+ nV=n1;
+ if (aDS.Shape(n1).ShapeType()==TopAbs_FACE) {
+ nF=n1;
+ nV=n2;
+ }
+ nVSD=pPF->FindSDVertex(nV);
+ if (nVSD) {
+ nV=nVSD;
+ }
+ //
+ UpdateCandidates(nF, nV, aMFMV);
+ }
+ //
+ // 1.2 EFs
+ aNbEFs=aEFs.Extent();
+ for (i=1; i<=aNbEFs; ++i) {
+ const BOPTools_ESInterference& aEF=aEFs(i);
+ aEF.Indices(n1, n2);
+ nV=aEF.NewShape();
+ if (!nV) {
+ continue;
+ }
+ const TopoDS_Shape& aSnew=aDS.Shape(nV);
+ if (aSnew.ShapeType()!=TopAbs_VERTEX) {
+ continue;
+ }
+ //
+ nF=(aDS.Shape(n1).ShapeType()==TopAbs_FACE) ? n1 : n2;
+ nVSD=pPF->FindSDVertex(nV);
+ if (nVSD) {
+ nV=nVSD;
+ }
+ UpdateCandidates(nF, nV, aMFMV);
+ }
+ //
+ aNbS=aDS.NumberOfShapesOfTheObject();
+ for (nF=1; nF<=aNbS; ++nF) {
+ const TopoDS_Shape& aF=aDS.Shape(nF);
+ //
+ if (aF.ShapeType()!=TopAbs_FACE) {
+ continue;
+ }
+ if (!aMFence.Add(aF)) {
+ continue;
+ }
+ //
+ const TopoDS_Face& aFF=TopoDS::Face(aF);
+ aTol=BRep_Tool::Tolerance(aFF);
+ //
+ // 1.3 FFs
+ if (aMAV.Contains(nF)) {
+ const TColStd_IndexedMapOfInteger& aMAVF=aMAV.FindFromKey(nF);
+ aNbAVF=aMAVF.Extent();
+ for (j=1; j<=aNbAVF; ++j) {
+ nV=aMAVF(j);
+ nVSD=pPF->FindSDVertex(nV);
+ if (nVSD) {
+ nV=nVSD;
+ }
+ //
+ UpdateCandidates(nF, nV, aMFMV);
+ }
+ }
+ //
+ // 1.4 Internal vertices of the face nF
+ BooleanOperations_OnceExplorer aExp(aDS);
+ aExp.Init(nF, TopAbs_VERTEX);
+ for (; aExp.More(); aExp.Next()) {
+ nV=aExp.Current();
+ const TopoDS_Shape& aV=aDS.Shape(nV);
+ if (aV.Orientation()==TopAbs_INTERNAL) {
+ nVSD=pPF->FindSDVertex(nV);
+ if (nVSD) {
+ nV=nVSD;
+ }
+ //
+ UpdateCandidates(nF, nV, aMFMV);
+ }
+ }
+ //
+ // 2. Process face nF
+ if (!aMFMV.Contains(nF)) {
+ continue;
+ }
+ //
+ const TColStd_IndexedMapOfInteger& aMVC=aMFMV.FindFromKey(nF);
+ aNbVC=aMVC.Extent();
+ if (!aNbVC) {
+ continue;
+ }
+ //
+ // 2.1 Refine candidates
+ TopTools_IndexedDataMapOfShapeListOfShape aMVE;
+ TopTools_ListOfShape aLV;
+ //
+ bHasImage=myImages.HasImage(aF);
+ if (bHasImage) {
+ const TopTools_ListOfShape& aLFx=myImages.Image(aF);
+ aIt.Initialize(aLFx);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aFx=aIt.Value();
+ TopExp::MapShapesAndAncestors(aFx, TopAbs_VERTEX, TopAbs_EDGE, aMVE);
+ }
+ }
+ else {
+ Standard_Boolean bFaceToProcess;
+ //
+ TopExp::MapShapesAndAncestors(aF, TopAbs_VERTEX, TopAbs_EDGE, aMVE);
+ bFaceToProcess=Standard_False;
+ for (j=1; j<=aNbVC; ++j) {
+ nV=aMVC(j);
+ const TopoDS_Shape& aV=aDS.Shape(nV);
+ if (!aMVE.Contains(aV)) {
+ bFaceToProcess=!bFaceToProcess;
+ break;
+ }
+ }
+ if (!bFaceToProcess) {
+ continue;
+ }
+ }// else
+ //
+ for (j=1; j<=aNbVC; ++j) {
+ nV=aMVC(j);
+ const TopoDS_Shape& aV=aDS.Shape(nV);
+ if (aMVE.Contains(aV)) {
+ const TopTools_ListOfShape& aLE=aMVE.FindFromKey(aV);
+ aNbE=aLE.Extent();
+ if (aNbE) {
+ continue;
+ }
+ }
+ aLV.Append(aV);
+ }
+ //
+ aNbV=aLV.Extent();
+ if (aNbV) {
+ // 3. Try to put vertices into the face(s)
+ aItV.Initialize(aLV);
+ for (; aItV.More(); aItV.Next()) {
+ TopoDS_Vertex aV=TopoDS::Vertex(aItV.Value());
+ aV.Orientation(TopAbs_INTERNAL);
+ //
+ bHasImage=myImages.HasImage(aF);
+ if (bHasImage) {
+ const TopTools_ListOfShape& aLFx=myImages.Image(aF);
+ aIt.Initialize(aLFx);
+ for (; aIt.More(); aIt.Next()) {
+ TopoDS_Face aFx=TopoDS::Face(aIt.Value());
+ // update classifier
+ IntTools_FClass2d& aClsf=aCtx.FClass2d(aFx);
+ aClsf.Init(aFx, aTol);
+ //
+ iFlag=aCtx.ComputeVS (aV, aFx, aU1, aU2);
+ if (!iFlag) {
+ aBB.Add(aFx, aV);
+ break;
+ }
+ }
+ }
+ else {
+ const TopoDS_Face& aFx=TopoDS::Face(aF);
+ // update classifier
+ IntTools_FClass2d& aClsf=aCtx.FClass2d(aFx);
+ aClsf.Init(aFx, aTol);
+ //
+ iFlag=aCtx.ComputeVS (aV, aFx, aU1, aU2);
+ if (!iFlag) {
+ TopoDS_Face aFz;
+ //
+ GEOMAlgo_Tools3D::CopyFace(aFx, aFz);
+ aBB.Add(aFz, aV);
+ myImages.Bind(aF, aFz);
+ }
+ }
+ }// for (; aItV.More(); aItV.Next()) {
+ }// if (aNbV) {
+ }// for (nF=1; nF<=aNb; ++nF) {
+}
+//=======================================================================
+// function: UpdateCandidates
+// purpose:
+//=======================================================================
+void UpdateCandidates(const Standard_Integer theNF,
+ const Standard_Integer theNV,
+ NMTTools_IndexedDataMapOfIndexedMapOfInteger& theMFMV)
+{
+ if (theMFMV.Contains(theNF)) {
+ TColStd_IndexedMapOfInteger& aMV=theMFMV.ChangeFromKey(theNF);
+ aMV.Add(theNV);
+ }
+ else {
+ TColStd_IndexedMapOfInteger aMV;
+ aMV.Add(theNV);
+ theMFMV.Add(theNF, aMV);
+ }
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_Builder_3.cxx
+// Created:
+// Author: Peter KURNEV
+
+#include <GEOMAlgo_Builder.hxx>
+
+#include <TopAbs_State.hxx>
+
+#include <TopoDS.hxx>
+#include <TopoDS_Iterator.hxx>
+#include <TopoDS_Solid.hxx>
+#include <TopoDS_Shape.hxx>
+#include <TopoDS_Face.hxx>
+#include <TopoDS_Solid.hxx>
+#include <TopoDS_Iterator.hxx>
+#include <TopoDS_Shell.hxx>
+#include <TopoDS_Compound.hxx>
+
+#include <TopExp.hxx>
+#include <TopExp_Explorer.hxx>
+
+#include <BRep_Builder.hxx>
+#include <BRepTools.hxx>
+#include <BRepClass3d_SolidClassifier.hxx>
+
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+#include <TopTools_MapIteratorOfMapOfShape.hxx>
+#include <TopTools_DataMapOfShapeShape.hxx>
+#include <TopTools_DataMapOfShapeInteger.hxx>
+#include <TopTools_DataMapIteratorOfDataMapOfShapeInteger.hxx>
+#include <TopTools_MapOfShape.hxx>
+
+#include <IntTools_Context.hxx>
+
+#include <NMTDS_ShapesDataStructure.hxx>
+#include <NMTTools_DSFiller.hxx>
+#include <NMTTools_PaveFiller.hxx>
+
+#include <GEOMAlgo_Tools3D.hxx>
+#include <GEOMAlgo_BuilderSolid.hxx>
+#include <GEOMAlgo_ShapeSet.hxx>
+#include <GEOMAlgo_DataMapOfShapeShapeSet.hxx>
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet.hxx>
+
+
+
+static
+ void OwnInternalShapes(const TopoDS_Shape& ,
+ TopTools_IndexedMapOfShape& );
+
+//=======================================================================
+//function : FillImagesSolids
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::FillImagesSolids()
+{
+ myErrorStatus=0;
+ //
+ FillIn3DParts();
+ BuildSplitSolids();
+ FillInternalShapes();
+}
+//=======================================================================
+//function : BuildDraftSolid
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::BuildDraftSolid(const TopoDS_Shape& theSolid,
+ TopoDS_Shape& theDraftSolid,
+ TopTools_ListOfShape& theLIF)
+{
+ myErrorStatus=0;
+ //
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ IntTools_Context& aCtx= pPF->ChangeContext();
+ //
+ Standard_Boolean bToReverse;
+ Standard_Integer iFlag;
+ TopAbs_Orientation aOrF, aOrSh, aOrSd;
+ TopoDS_Iterator aIt1, aIt2;
+ TopTools_ListIteratorOfListOfShape aItS;
+ BRep_Builder aBB;
+ TopoDS_Shell aShD;
+ TopoDS_Shape aFSDx, aFx;
+ //
+ aOrSd=theSolid.Orientation();
+ theDraftSolid.Orientation(aOrSd);
+ //
+ aIt1.Initialize(theSolid);
+ for (; aIt1.More(); aIt1.Next()) {
+ const TopoDS_Shape& aSh=aIt1.Value();
+ if(aSh.ShapeType()!=TopAbs_SHELL) {
+ continue; // mb internal edges,vertices
+ }
+ //
+ aOrSh=aSh.Orientation();
+ aBB.MakeShell(aShD);
+ aShD.Orientation(aOrSh);
+ iFlag=0;
+ //
+ aIt2.Initialize(aSh);
+ for (; aIt2.More(); aIt2.Next()) {
+ const TopoDS_Shape& aF=aIt2.Value();
+ aOrF=aF.Orientation();
+ //
+ if (myImages.HasImage(aF)) {
+ const TopTools_ListOfShape& aLSp=myImages.Image(aF);
+ aItS.Initialize(aLSp);
+ for (; aItS.More(); aItS.Next()) {
+ aFx=aItS.Value();
+ //
+ if (mySameDomainShapes.Contains(aFx)) {
+ aFSDx=mySameDomainShapes.FindFromKey(aFx);
+ //
+ if (aOrF==TopAbs_INTERNAL) {
+ aFSDx.Orientation(aOrF);
+ theLIF.Append(aFSDx);
+ }
+ else {
+ bToReverse=GEOMAlgo_Tools3D::IsSplitToReverse(aFSDx, aF, aCtx);
+ if (bToReverse) {
+ aFSDx.Reverse();
+ }
+ //
+ iFlag=1;
+ aBB.Add(aShD, aFSDx);
+ }
+ }// if (mySameDomainShapes.Contains(aFx)) {
+ else {
+ aFx.Orientation(aOrF);
+ if (aOrF==TopAbs_INTERNAL) {
+ theLIF.Append(aFx);
+ }
+ else{
+ iFlag=1;
+ aBB.Add(aShD, aFx);
+ }
+ }
+ }
+ } //if (myImages.HasImage(aF)) {
+ //
+ else {
+ if (aOrF==TopAbs_INTERNAL) {
+ theLIF.Append(aF);
+ }
+ else{
+ iFlag=1;
+ aBB.Add(aShD, aF);
+ }
+ }
+ } //for (; aIt2.More(); aIt2.Next()) {
+ //
+ if (iFlag) {
+ aBB.Add(theDraftSolid, aShD);
+ }
+ } //for (; aIt1.More(); aIt1.Next()) {
+}
+//=======================================================================
+//function : FillIn3DParts
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::FillIn3DParts()
+{
+ myErrorStatus=0;
+ //
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ IntTools_Context& aCtx= pPF->ChangeContext();
+ //
+ Standard_Boolean bIsIN, bHasImage;
+ Standard_Integer aNbS, aNbSolids, i, j, aNbFaces, aNbFP, aNbFPx, aNbFIN, aNbLIF;// k,
+ TopAbs_ShapeEnum aType;
+ TopAbs_State aState;
+ TopTools_IndexedMapOfShape aMSolids, aMS, aMFaces, aMFIN;
+ TopTools_MapOfShape aMFDone;
+ TopTools_IndexedDataMapOfShapeListOfShape aMEF;
+ TopTools_ListIteratorOfListOfShape aItS;
+ TopoDS_Iterator aIt, aItF;
+ BRep_Builder aBB;
+ TopoDS_Solid aSolidSp;
+ TopoDS_Face aFP;
+ //
+ myDraftSolids.Clear();
+ //
+ aNbS=aDS.NumberOfShapesOfTheObject();
+ for (i=1; i<=aNbS; ++i) {
+ const TopoDS_Shape& aS=aDS.Shape(i);
+ //
+ aType=aS.ShapeType();
+ if (aType==TopAbs_SOLID) {
+ // all solids from DS
+ aMSolids.Add(aS);
+ }
+ else if (aType==TopAbs_FACE) {
+ // all faces (originals from DS or theirs images)
+ if (myImages.HasImage(aS)) {
+ const TopTools_ListOfShape& aLS=myImages.Image(aS);
+ aItS.Initialize(aLS);
+ for (; aItS.More(); aItS.Next()) {
+ const TopoDS_Shape& aFx=aItS.Value();
+ //
+ if (mySameDomainShapes.Contains(aFx)) {
+ const TopoDS_Shape& aFSDx=mySameDomainShapes.FindFromKey(aFx);
+ aMFaces.Add(aFSDx);
+ }
+ else {
+ aMFaces.Add(aFx);
+ }
+ }
+ }
+ else {
+ if (mySameDomainShapes.Contains(aS)) {
+ const TopoDS_Shape& aFSDx=mySameDomainShapes.FindFromKey(aS);
+ aMFaces.Add(aFSDx);
+ }
+ else {
+ aMFaces.Add(aS);
+ }
+ }
+ }
+ }
+ //
+ aNbFaces=aMFaces.Extent();
+ aNbSolids=aMSolids.Extent();
+ //
+ for (i=1; i<=aNbSolids; ++i) {
+ const TopoDS_Solid& aSolid=TopoDS::Solid(aMSolids(i));
+ aMFDone.Clear();
+ aMFIN.Clear();
+ aMEF.Clear();
+ //
+ aBB.MakeSolid(aSolidSp);
+ //
+ TopTools_ListOfShape aLIF;
+ //
+ BuildDraftSolid(aSolid, aSolidSp, aLIF);
+ aNbLIF=aLIF.Extent();
+ //
+ // 1 all faces/edges from aSolid [ aMS ]
+ bHasImage=Standard_False;
+ aMS.Clear();
+ aIt.Initialize(aSolid);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aShell=aIt.Value();
+ //
+ if (myImages.HasImage(aShell)) {
+ bHasImage=Standard_True;
+ //
+ const TopTools_ListOfShape& aLS=myImages.Image(aShell);
+ aItS.Initialize(aLS);
+ for (; aItS.More(); aItS.Next()) {
+ const TopoDS_Shape& aSx=aItS.Value();
+ aMS.Add(aSx);
+ TopExp::MapShapes(aSx, TopAbs_FACE, aMS);
+ TopExp::MapShapes(aSx, TopAbs_EDGE, aMS);
+ TopExp::MapShapesAndAncestors(aSx, TopAbs_EDGE, TopAbs_FACE, aMEF);
+ }
+ }
+ else {
+ //aMS.Add(aShell);
+ TopExp::MapShapes(aShell, TopAbs_FACE, aMS);
+ TopExp::MapShapesAndAncestors(aShell, TopAbs_EDGE, TopAbs_FACE, aMEF);
+ }
+ }
+ //
+ // 2 all faces that are not from aSolid [ aLFP1 ]
+ Standard_Integer aNbEFP;
+ TopTools_IndexedDataMapOfShapeListOfShape aMEFP;
+ TopTools_ListIteratorOfListOfShape aItFP, aItEx;
+ TopTools_MapOfShape aMFence;
+ TopTools_ListOfShape aLFP1, aLFP2, aLFP, aLCBF, aLFIN, aLEx;//*pLFP,
+ //
+ // for all non-solid faces build EF map [ aMEFP ]
+ for (j=1; j<=aNbFaces; ++j) {
+ const TopoDS_Shape& aFace=aMFaces(j);
+ if (!aMS.Contains(aFace)) {
+ TopExp::MapShapesAndAncestors(aFace, TopAbs_EDGE, TopAbs_FACE, aMEFP);
+ }
+ }
+ //
+ // among all faces from aMEFP select these that have same edges
+ // with the solid (i.e aMEF). These faces will be treated first
+ // to prevent the usage of 3D classifier.
+ // The full list of faces to process is aLFP1.
+ aNbEFP=aMEFP.Extent();
+ for (j=1; j<=aNbEFP; ++j) {
+ const TopoDS_Shape& aE=aMEFP.FindKey(j);
+ //
+ if (aMEF.Contains(aE)) { // !!
+ const TopTools_ListOfShape& aLF=aMEFP(j);
+ aItFP.Initialize(aLF);
+ for (; aItFP.More(); aItFP.Next()) {
+ const TopoDS_Shape& aF=aItFP.Value();
+ if (aMFence.Add(aF)) {
+ aLFP1.Append(aF);
+ }
+ }
+ }
+ else {
+ aLEx.Append(aE);
+ }
+ }
+ //
+ aItEx.Initialize(aLEx);
+ for (; aItEx.More(); aItEx.Next()) {
+ const TopoDS_Shape& aE=aItEx.Value();
+ const TopTools_ListOfShape& aLF=aMEFP.FindFromKey(aE);
+ aItFP.Initialize(aLF);
+ for (; aItFP.More(); aItFP.Next()) {
+ const TopoDS_Shape& aF=aItFP.Value();
+ if (aMFence.Add(aF)) {
+ aLFP2.Append(aF);
+ }
+ }
+ }
+ aLFP1.Append(aLFP2);
+ //==========
+ //
+ // 3 Process faces aLFP1
+ aNbFP=aLFP1.Extent();
+ aItFP.Initialize(aLFP1);
+ for (; aItFP.More(); aItFP.Next()) {
+ const TopoDS_Shape& aSP=aItFP.Value();
+ if (!aMFDone.Add(aSP)) {
+ continue;
+ }
+
+ //
+ // first face to process
+ aFP=TopoDS::Face(aSP);
+ bIsIN= GEOMAlgo_Tools3D::IsInternalFace(aFP, aSolidSp, aMEF, 1.e-14, aCtx);
+ aState=(bIsIN) ? TopAbs_IN : TopAbs_OUT;
+ //
+ // collect faces to process [ aFP is the first ]
+ aLFP.Clear();
+ aLFP.Append(aFP);
+ aItS.Initialize(aLFP1);
+ for (; aItS.More(); aItS.Next()) {
+ const TopoDS_Shape& aSk=aItS.Value();
+ if (!aMFDone.Contains(aSk)) {
+ aLFP.Append(aSk);
+ }
+ }
+ //
+ // Connexity Block that spreads from aFP the Bound
+ // or till the end of the block itself
+ aLCBF.Clear();
+ GEOMAlgo_Tools3D::MakeConnexityBlock(aLFP, aMS, aLCBF);
+ //
+ // fill states for the Connexity Block
+ aItS.Initialize(aLCBF);
+ for (; aItS.More(); aItS.Next()) {
+ const TopoDS_Shape& aSx=aItS.Value();
+ aMFDone.Add(aSx);
+ if (aState==TopAbs_IN) {
+ aMFIN.Add(aSx);
+ }
+ }
+ //
+ aNbFPx=aMFDone.Extent();
+ if (aNbFPx==aNbFP) {
+ break;
+ }
+ }//for (; aItFP.More(); aItFP.Next())
+ //
+ // faces Inside aSolid
+ aLFIN.Clear();
+ aNbFIN=aMFIN.Extent();
+ if (aNbFIN || aNbLIF) {
+ for (j=1; j<=aNbFIN; ++j) {
+ const TopoDS_Shape& aFIN=aMFIN(j);
+ aLFIN.Append(aFIN);
+ }
+ //
+ aItS.Initialize(aLIF);
+ for (; aItS.More(); aItS.Next()) {
+ const TopoDS_Shape& aFIN=aItS.Value();
+ aLFIN.Append(aFIN);
+ }
+ //
+ myInParts.Add(aSolid, aLFIN);
+ }
+ if (aNbFIN || bHasImage) {
+ myDraftSolids.Add(aSolid, aSolidSp);
+ }
+ }//for (i=1; i<=aNbSolids; ++i) { // next solid
+}
+//=======================================================================
+//function : BuildSplitSolids
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::BuildSplitSolids()
+{
+ myErrorStatus=0;
+ //
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ IntTools_Context& aCtx= pPF->ChangeContext();
+ //
+ Standard_Integer i, aNbS, iErr;
+ TopExp_Explorer aExp;
+ TopTools_ListOfShape aSFS, aLSEmpty;
+ TopTools_MapOfShape aMFence;
+ TopTools_ListIteratorOfListOfShape aIt;
+ GEOMAlgo_BuilderSolid aSB;
+ GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet aItSS;
+ GEOMAlgo_DataMapOfShapeShapeSet aMSS;
+ GEOMAlgo_ShapeSet aSSi;
+ //
+ aSB.SetContext(aCtx);
+ //
+ // 1. Build solids for interferred source solids
+ //
+ aNbS=myDraftSolids.Extent();
+ for (i=1; i<=aNbS; ++i) {
+ const TopoDS_Shape& aS =myDraftSolids.FindKey(i);
+ const TopoDS_Shape& aSD=myDraftSolids.FindFromIndex(i);
+ const TopTools_ListOfShape& aLFIN=
+ (myInParts.Contains(aS)) ? myInParts.FindFromKey(aS) : aLSEmpty;
+ //
+ // 1.1 Fill Shell Faces Set
+ aSFS.Clear();
+
+ aExp.Init(aSD, TopAbs_FACE);
+ for (; aExp.More(); aExp.Next()) {
+ const TopoDS_Shape& aF=aExp.Current();
+ aSFS.Append(aF);
+ }
+ //
+ aIt.Initialize(aLFIN);
+ for (; aIt.More(); aIt.Next()) {
+ TopoDS_Shape aF=aIt.Value();
+ //
+ aF.Orientation(TopAbs_FORWARD);
+ aSFS.Append(aF);
+ aF.Orientation(TopAbs_REVERSED);
+ aSFS.Append(aF);
+ }
+ //
+ Standard_Integer aNbSFS;
+ aNbSFS=aSFS.Extent();
+ //
+ // 1.2
+ // Check whether aSFS contains a subsets of faces
+ // of solids that have been already built.
+ // If yes, shrink aSFS by these subsets.
+ aSSi.Clear();
+ aSSi.Add(aSFS);
+ //
+ aItSS.Initialize(aMSS);
+ for (; aItSS.More(); aItSS.Next()) {
+ const TopoDS_Shape& aSR=aItSS.Key();
+ const GEOMAlgo_ShapeSet& aSSR=aItSS.Value();
+ if (aSSi.Contains(aSSR)) {
+ // the aSR is SD solid for aS
+ aSSi.Subtract(aSSR);
+ // update images
+ if(myImages.HasImage(aS)) {
+ myImages.Add(aS, aSR);
+ }
+ else {
+ myImages.Bind(aS, aSR);
+ }
+ //
+ // update SD Shapes
+ mySameDomainShapes.Add(aSR, aSR);
+ }
+ }
+ const TopTools_ListOfShape& aSFS1=aSSi.GetSet();
+ aNbSFS=aSFS1.Extent();
+ //
+ // 1.3 Build new solids
+ aSB.SetShapes(aSFS1);
+ aSB.Perform();
+ iErr=aSB.ErrorStatus();
+ if (iErr) {
+ myErrorStatus=30; // SolidBuilder failed
+ return;
+ }
+ //
+ const TopTools_ListOfShape& aLSR=aSB.Areas();
+ //
+ // 1.4 Collect resulting solids and theirs set of faces
+ aIt.Initialize(aLSR);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aSR=aIt.Value();
+ //
+ aSSi.Clear();
+ aExp.Init(aSR, TopAbs_FACE);
+ for (; aExp.More(); aExp.Next()) {
+ const TopoDS_Shape& aF=aExp.Current();
+ aSSi.Add(aF);
+ }
+ aMSS.Bind(aSR, aSSi);
+ }
+ //
+ // Update images
+ if (myImages.HasImage(aS)) {
+ myImages.Add(aS, aLSR);
+ }
+ else {
+ myImages.Bind(aS, aLSR);
+ }
+ } // for (i=1; i<=aNbS; ++i) {
+ //
+ // 2. Find same domain solids for non-interferred solids
+ aNbS=aDS.NumberOfShapesOfTheObject();
+ for (i=1; i<=aNbS; ++i) {
+ const TopoDS_Shape& aS=aDS.Shape(i);
+ if (aS.ShapeType()!=TopAbs_SOLID) {
+ continue;
+ }
+ if (!aMFence.Add(aS)) {
+ continue;
+ }
+ if(myImages.HasImage(aS)) {
+ continue;
+ }
+ //
+ aSSi.Clear();
+ aSSi.Add(aS, TopAbs_FACE);
+ //
+ aItSS.Initialize(aMSS);
+ for (; aItSS.More(); aItSS.Next()) {
+ const TopoDS_Shape& aSR=aItSS.Key();
+ const GEOMAlgo_ShapeSet& aSSR=aItSS.Value();
+ if (aSSi.Contains(aSSR)) {
+ myImages.Bind(aS, aSR);
+ break;
+ }
+ }
+ } //for (i=1; i<=aNbS; ++i)
+}
+//=======================================================================
+//function :FillInternalShapes
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::FillInternalShapes()
+{
+ myErrorStatus=0;
+ //
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ IntTools_Context& aCtx= pPF->ChangeContext();
+ //
+ //Standard_Boolean bHasImage;
+ Standard_Integer i, j, jT, aNbS, aNbSI, aNbSx, aNbSd;
+ TopAbs_ShapeEnum aType, aT[]={ TopAbs_VERTEX, TopAbs_EDGE };
+ TopAbs_State aState;
+ TopTools_ListIteratorOfListOfShape aIt, aIt1;
+ TopTools_IndexedDataMapOfShapeListOfShape aMSx;
+ TopTools_IndexedMapOfShape aMx;
+ TopTools_MapOfShape aMSI, aMFence, aMSOr;
+ TopTools_MapIteratorOfMapOfShape aItM;
+ TopTools_ListOfShape aLSI, aLSd;
+ TopoDS_Iterator aItS;
+ BRep_Builder aBB;
+ //
+ // 1. Shapes to process
+ //
+ // 1.1 Shapes from pure arguments aMSI
+ // 1.1.1 vertex, edge
+ for (i=0; i<2; ++i) {
+ jT=(Standard_Integer)aT[i];
+ const TopTools_ListOfShape &aLS=myShapes1[jT];
+ aIt.Initialize(aLS);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ if (aMFence.Add(aS)) {
+ aLSI.Append(aS);
+ }
+ }
+ }
+ // 1.1.2 wire
+ {
+ jT=(Standard_Integer)TopAbs_WIRE;
+ const TopTools_ListOfShape &aLW=myShapes1[jT];
+ aIt.Initialize(aLW);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aW=aIt.Value();
+ aItS.Initialize(aW);
+ for (; aItS.More(); aItS.Next()) {
+ const TopoDS_Shape& aE=aItS.Value();
+ if (aMFence.Add(aE)) {
+ aLSI.Append(aE);
+ }
+ }
+ }
+ }
+ // 1.1.3 theirs images/sources
+ aIt1.Initialize(aLSI);
+ for (; aIt1.More(); aIt1.Next()) {
+ const TopoDS_Shape& aS=aIt1.Value();
+ if (myImages.HasImage(aS)) {
+ const TopTools_ListOfShape &aLSp=myImages.Image(aS);
+ aIt.Initialize(aLSp);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aSI=aIt.Value();
+ aMSI.Add(aSI);
+ }
+ }
+ else {
+ aMSI.Add(aS);
+ }
+ }
+ aLSI.Clear();
+ aNbSI=aMSI.Extent();
+ //
+ // 2. Internal vertices, edges from source solids
+ aMFence.Clear();
+ aLSd.Clear();
+ //
+ aNbS=aDS.NumberOfShapesOfTheObject();
+ for (i=1; i<=aNbS; ++i) {
+ const TopoDS_Shape& aS=aDS.Shape(i);
+ aType=aS.ShapeType();
+ if (aType==TopAbs_SOLID) {
+ //
+ aMx.Clear();
+ OwnInternalShapes(aS, aMx);
+ //
+ aNbSx=aMx.Extent();
+ for (j=1; j<=aNbSx; ++j) {
+ const TopoDS_Shape& aSI=aMx(j);
+ if (myImages.HasImage(aSI)) {
+ const TopTools_ListOfShape &aLSp=myImages.Image(aSI);
+ aIt.Initialize(aLSp);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aSp=aIt.Value();
+ aMSI.Add(aSp);
+ }
+ }
+ else {
+ aMSI.Add(aSI);
+ }
+ }
+ //
+ // build aux map from splits of solids
+ if (myImages.HasImage(aS)) {
+ const TopTools_ListOfShape &aLSp=myImages.Image(aS);
+ aIt.Initialize(aLSp);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aSp=aIt.Value();
+ if (aMFence.Add(aSp)) {
+ TopExp::MapShapesAndAncestors(aSp, TopAbs_VERTEX, TopAbs_EDGE, aMSx);
+ TopExp::MapShapesAndAncestors(aSp, TopAbs_VERTEX, TopAbs_FACE, aMSx);
+ TopExp::MapShapesAndAncestors(aSp, TopAbs_EDGE , TopAbs_FACE, aMSx);
+ aLSd.Append(aSp);
+ }
+ }
+ }
+ else {
+ if (aMFence.Add(aS)) {
+ TopExp::MapShapesAndAncestors(aS, TopAbs_VERTEX, TopAbs_EDGE, aMSx);
+ TopExp::MapShapesAndAncestors(aS, TopAbs_VERTEX, TopAbs_FACE, aMSx);
+ TopExp::MapShapesAndAncestors(aS, TopAbs_EDGE , TopAbs_FACE, aMSx);
+ aLSd.Append(aS);
+ aMSOr.Add(aS);
+ }
+ }
+ }//if (aType==TopAbs_SOLID)
+ }
+ //
+ aNbSd=aLSd.Extent();
+ //
+ // 3. Some shapes of aMSI can be already tied with faces of
+ // split solids
+ aItM.Initialize(aMSI);
+ for (; aItM.More(); aItM.Next()) {
+ const TopoDS_Shape& aSI=aItM.Key();
+ if (aMSx.Contains(aSI)) {
+ const TopTools_ListOfShape &aLSx=aMSx.FindFromKey(aSI);
+ aNbSx=aLSx.Extent();
+ if (aNbSx) {
+ aMSI.Remove(aSI);
+ }
+ }
+ }
+ //
+ // 4. Just check it
+ aNbSI=aMSI.Extent();
+ if (!aNbSI) {
+ return;
+ }
+ //
+ // 5 Settle internal vertices and edges into solids
+ aMx.Clear();
+ aIt.Initialize(aLSd);
+ for (; aIt.More(); aIt.Next()) {
+ TopoDS_Solid aSd=TopoDS::Solid(aIt.Value());
+ //
+ aItM.Initialize(aMSI);
+ for (; aItM.More(); aItM.Next()) {
+ TopoDS_Shape aSI=aItM.Key();
+ aSI.Orientation(TopAbs_INTERNAL);
+ //
+ aState=GEOMAlgo_Tools3D::ComputeStateByOnePoint(aSI, aSd, 1.e-11, aCtx);
+ if (aState==TopAbs_IN) {
+ //
+ if(aMSOr.Contains(aSd)) {
+ //
+ TopoDS_Solid aSdx;
+ //
+ aBB.MakeSolid(aSdx);
+ aItS.Initialize(aSd);
+ for (; aItS.More(); aItS.Next()) {
+ const TopoDS_Shape& aSh=aItS.Value();
+ aBB.Add(aSdx, aSh);
+ }
+ //
+ aBB.Add(aSdx, aSI);
+ //
+ myImages.Bind(aSd, aSdx);
+ aMSOr.Remove(aSd);
+ aSd=aSdx;
+ }
+ else {
+ aBB.Add(aSd, aSI);
+ }
+ //
+ aMSI.Remove(aSI);
+ } //if (aState==TopAbs_IN) {
+ }// for (; aItM.More(); aItM.Next()) {
+ }//for (; aIt1.More(); aIt1.Next()) {
+}
+//=======================================================================
+//function : OwnInternalShapes
+//purpose :
+//=======================================================================
+ void OwnInternalShapes(const TopoDS_Shape& theS,
+ TopTools_IndexedMapOfShape& theMx)
+{
+ TopoDS_Iterator aIt;
+ //
+ aIt.Initialize(theS);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aSx=aIt.Value();
+ if (aSx.ShapeType()!=TopAbs_SHELL) {
+ theMx.Add(aSx);
+ }
+ }
+}
+//
+// ErrorStatus
+// 30 - SolidBuilder failed
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_Builder_4.cxx
+// Created:
+// Author: Peter KURNEV
+
+#include <GEOMAlgo_Builder.hxx>
+
+#include <TopoDS_Iterator.hxx>
+
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_MapIteratorOfMapOfShape.hxx>
+
+#include <IntTools_Context.hxx>
+
+#include <NMTDS_ShapesDataStructure.hxx>
+
+#include <NMTTools_PaveFiller.hxx>
+#include <NMTTools_DSFiller.hxx>
+
+#include <GEOMAlgo_Tools3D.hxx>
+
+
+static
+ void MapShapes(const TopoDS_Shape& aS,
+ TopTools_MapOfShape& aM);
+
+//=======================================================================
+//function : Generated
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_Builder::Generated(const TopoDS_Shape& theS)
+{
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ IntTools_Context& aCtx=pPF->ChangeContext();
+ //
+ Standard_Boolean bHasImage, bToReverse;
+ TopAbs_ShapeEnum aType;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ myHistShapes.Clear();
+ //
+ if (theS.IsNull()) {
+ return myHistShapes;
+ }
+ //
+ bHasImage=myImages.HasImage(theS);
+ if (!bHasImage) {
+ return myHistShapes;
+ }
+ //
+ aType=theS.ShapeType();
+ //
+ if (aType==TopAbs_EDGE || aType==TopAbs_FACE ||
+ aType==TopAbs_VERTEX || aType==TopAbs_SOLID) {
+ const TopTools_ListOfShape& aLSp=myImages.Image(theS);
+ aIt.Initialize(aLSp);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aSp=aIt.Value();
+ if (mySameDomainShapes.Contains(aSp)) {
+ if (myMapShape.Contains(aSp)) {
+ TopoDS_Shape aSpR=mySameDomainShapes.FindFromKey(aSp);
+ //
+ if (aType==TopAbs_VERTEX || aType==TopAbs_SOLID) {
+ aSpR.Orientation(theS.Orientation());
+ }
+ else {
+ bToReverse=GEOMAlgo_Tools3D::IsSplitToReverse(aSpR, theS, aCtx);
+ if (bToReverse) {
+ aSpR.Reverse();
+ }
+ }
+ //
+ myHistShapes.Append(aSpR);
+ }
+ }
+ }
+ }
+ //
+ return myHistShapes;
+}
+//=======================================================================
+//function : Modified
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_Builder::Modified(const TopoDS_Shape& theS)
+{
+ const NMTDS_ShapesDataStructure& aDS=myDSFiller->DS();
+ NMTTools_PaveFiller* pPF=(NMTTools_PaveFiller*)&(myDSFiller->PaveFiller());
+ IntTools_Context& aCtx=pPF->ChangeContext();
+ //
+ Standard_Boolean bHasImage, bToReverse;
+ TopAbs_ShapeEnum aType;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ myHistShapes.Clear();
+ //
+ if (theS.IsNull()) {
+ return myHistShapes;
+ }
+ //
+ bHasImage=myImages.HasImage(theS);
+ if (!bHasImage) {
+ return myHistShapes;
+ }
+ //
+ aType=theS.ShapeType();
+ //
+ if (aType==TopAbs_EDGE || aType==TopAbs_FACE ||
+ aType==TopAbs_VERTEX || aType==TopAbs_SOLID) {
+ const TopTools_ListOfShape& aLSp=myImages.Image(theS);
+ aIt.Initialize(aLSp);
+ for (; aIt.More(); aIt.Next()) {
+ TopoDS_Shape aSp=aIt.Value();
+ if (!mySameDomainShapes.Contains(aSp)) {
+ if (myMapShape.Contains(aSp)) {
+ //
+ if (aType==TopAbs_VERTEX || aType==TopAbs_SOLID) {
+ aSp.Orientation(theS.Orientation());
+ }
+ else {
+ bToReverse=GEOMAlgo_Tools3D::IsSplitToReverse(aSp, theS, aCtx);
+ if (bToReverse) {
+ aSp.Reverse();
+ }
+ }
+ //
+ myHistShapes.Append(aSp);
+ }
+ }
+ }
+ }
+ //
+ return myHistShapes;
+}
+//=======================================================================
+//function : IsDeleted
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_Builder::IsDeleted(const TopoDS_Shape& theS)
+{
+ Standard_Boolean bRet, bHasImage, bContains;
+ TopAbs_ShapeEnum aType;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ bRet=Standard_False;
+ //
+ if (theS.IsNull()) {
+ return !bRet; //true
+ }
+ //
+ bContains=myMapShape.Contains(theS);
+ if (bContains) {
+ return bRet; //false
+ }
+ //
+ bHasImage=myImages.HasImage(theS);
+ if (!bHasImage) {
+ return !bRet; //true
+ }
+ //
+ aType=theS.ShapeType();
+ if (aType==TopAbs_EDGE || aType==TopAbs_FACE ||
+ aType==TopAbs_VERTEX || aType==TopAbs_SOLID) {
+ const TopTools_ListOfShape& aLSp=myImages.Image(theS);
+ aIt.Initialize(aLSp);
+ for (; aIt.More(); aIt.Next()) {
+ TopoDS_Shape aSp=aIt.Value();
+ //
+ if (!mySameDomainShapes.Contains(aSp)) {
+ if (myMapShape.Contains(aSp)) {
+ return bRet; //false
+ }
+ }
+ else {
+ TopoDS_Shape aSpR=mySameDomainShapes.FindFromKey(aSp);
+ if (myMapShape.Contains(aSpR)) {
+ return bRet; //false
+ }
+ }
+ }
+ }
+ return !bRet; // true
+}
+//=======================================================================
+//function : PrepareHistory
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Builder::PrepareHistory()
+{
+ myHistShapes.Clear();
+ myMapShape.Clear();
+ myHasDeleted=Standard_False;
+ myHasGenerated=Standard_False;
+ myHasModified=Standard_False;
+ //
+ if(myShape.IsNull()) {
+ return;
+ }
+ //
+ MapShapes(myShape, myMapShape);
+ //
+ Standard_Boolean bHasImage, bContainsSD;
+ TopAbs_ShapeEnum aType;
+ TopTools_MapOfShape aMS;
+ TopTools_ListIteratorOfListOfShape aIt;
+ TopTools_MapIteratorOfMapOfShape aItM;
+ //
+ aIt.Initialize(myShapes);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ MapShapes(aS, aMS);
+ }
+ //
+ aItM.Initialize(aMS);
+ for (; aItM.More(); aItM.Next()) {
+ const TopoDS_Shape& aSx=aItM.Key();
+ aType=aSx.ShapeType();
+ //
+ if (!myHasDeleted) {
+ myHasDeleted=IsDeleted(aSx);//xx
+ }
+ //
+ if (!myHasGenerated || !myHasModified) {
+ if (aType==TopAbs_EDGE || aType==TopAbs_FACE ||
+ aType==TopAbs_VERTEX || aType==TopAbs_SOLID) {
+ bHasImage=myImages.HasImage(aSx);
+ if (bHasImage) {
+ const TopTools_ListOfShape& aLSp=myImages.Image(aSx);
+ aIt.Initialize(aLSp);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aSp=aIt.Value();
+ //
+ if (myMapShape.Contains(aSp)) {
+ bContainsSD=mySameDomainShapes.Contains(aSp);
+ //
+ if (!myHasGenerated) {
+ if (bContainsSD) {
+ myHasGenerated=Standard_True;
+ }
+ }
+ if (!myHasModified) {
+ if (!bContainsSD) {
+ myHasModified=Standard_True;
+ }
+ }
+ } // if (myMapShape.Contains(aSp))
+ }
+ }
+ }
+ }
+ }
+
+}
+//=======================================================================
+//function : MapShapes
+//purpose :
+//=======================================================================
+ void MapShapes(const TopoDS_Shape& theS,
+ TopTools_MapOfShape& theM)
+{
+ theM.Add(theS);
+ TopoDS_Iterator anIt;
+ anIt.Initialize(theS);
+ for (; anIt.More(); anIt.Next()) {
+ const TopoDS_Shape& aSx=anIt.Value();
+ MapShapes(aSx, theM);
+ }
+}
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_CoupleOfShapes.cdl
-- Created: Wed Dec 15 13:00:10 2004
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_CoupleOfShapes {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_CoupleOfShapes();
+
+
Standard_EXPORT void SetShapes(const TopoDS_Shape& aS1,const TopoDS_Shape& aS2) ;
+
+
Standard_EXPORT void SetShape1(const TopoDS_Shape& aS1) ;
+
+
Standard_EXPORT void SetShape2(const TopoDS_Shape& aS2) ;
+
+
Standard_EXPORT void Shapes(TopoDS_Shape& aS1,TopoDS_Shape& aS2) const;
+
+
Standard_EXPORT const TopoDS_Shape& Shape1() const;
+
+
Standard_EXPORT const TopoDS_Shape& Shape2() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopoDS_Shape_HeaderFile
#include <TopoDS_Shape.hxx>
#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_DataMapIteratorOfDataMapOfPassKeyInteger : public TCollection_BasicMapIterator {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_DataMapIteratorOfDataMapOfPassKeyInteger();
+
+
Standard_EXPORT GEOMAlgo_DataMapIteratorOfDataMapOfPassKeyInteger(const GEOMAlgo_DataMapOfPassKeyInteger& aMap);
+
+
Standard_EXPORT void Initialize(const GEOMAlgo_DataMapOfPassKeyInteger& aMap) ;
+
+
Standard_EXPORT const GEOMAlgo_PassKey& Key() const;
+
+
Standard_EXPORT const Standard_Integer& Value() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape_HeaderFile
+#define _GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape_HeaderFile
+
+#ifndef _TCollection_BasicMapIterator_HeaderFile
+#include <TCollection_BasicMapIterator.hxx>
+#endif
+#ifndef _Standard_Real_HeaderFile
+#include <Standard_Real.hxx>
+#endif
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_HeaderFile
+#include <Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+#endif
+class Standard_NoSuchObject;
+class TopTools_ListOfShape;
+class TColStd_MapRealHasher;
+class GEOMAlgo_DataMapOfRealListOfShape;
+class GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape : public TCollection_BasicMapIterator {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape();
+
+
+Standard_EXPORT GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape(const GEOMAlgo_DataMapOfRealListOfShape& aMap);
+
+
+Standard_EXPORT void Initialize(const GEOMAlgo_DataMapOfRealListOfShape& aMap) ;
+
+
+Standard_EXPORT const Standard_Real& Key() const;
+
+
+Standard_EXPORT const TopTools_ListOfShape& Value() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape.hxx>
+
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TColStd_MapRealHasher_HeaderFile
+#include <TColStd_MapRealHasher.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapOfRealListOfShape_HeaderFile
+#include <GEOMAlgo_DataMapOfRealListOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_HeaderFile
+#include <GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+#endif
+
+
+#define TheKey Standard_Real
+#define TheKey_hxx <Standard_Real.hxx>
+#define TheItem TopTools_ListOfShape
+#define TheItem_hxx <TopTools_ListOfShape.hxx>
+#define Hasher TColStd_MapRealHasher
+#define Hasher_hxx <TColStd_MapRealHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfRealListOfShape
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfRealListOfShape.hxx>
+#include <TCollection_DataMapIterator.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal_HeaderFile
+#define _GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal_HeaderFile
+
+#ifndef _TCollection_BasicMapIterator_HeaderFile
+#include <TCollection_BasicMapIterator.hxx>
+#endif
+#ifndef _Standard_Real_HeaderFile
+#include <Standard_Real.hxx>
+#endif
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_HeaderFile
+#include <Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+#endif
+class Standard_NoSuchObject;
+class TopoDS_Shape;
+class TopTools_ShapeMapHasher;
+class GEOMAlgo_DataMapOfShapeReal;
+class GEOMAlgo_DataMapNodeOfDataMapOfShapeReal;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal : public TCollection_BasicMapIterator {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal();
+
+
+Standard_EXPORT GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal(const GEOMAlgo_DataMapOfShapeReal& aMap);
+
+
+Standard_EXPORT void Initialize(const GEOMAlgo_DataMapOfShapeReal& aMap) ;
+
+
+Standard_EXPORT const TopoDS_Shape& Key() const;
+
+
+Standard_EXPORT const Standard_Real& Value() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal.hxx>
+
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _TopTools_ShapeMapHasher_HeaderFile
+#include <TopTools_ShapeMapHasher.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapOfShapeReal_HeaderFile
+#include <GEOMAlgo_DataMapOfShapeReal.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_HeaderFile
+#include <GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+#endif
+
+
+#define TheKey TopoDS_Shape
+#define TheKey_hxx <TopoDS_Shape.hxx>
+#define TheItem Standard_Real
+#define TheItem_hxx <Standard_Real.hxx>
+#define Hasher TopTools_ShapeMapHasher
+#define Hasher_hxx <TopTools_ShapeMapHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfShapeReal
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfShapeReal
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfShapeReal.hxx>
+#include <TCollection_DataMapIterator.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet_HeaderFile
+#define _GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet_HeaderFile
+
+#ifndef _TCollection_BasicMapIterator_HeaderFile
+#include <TCollection_BasicMapIterator.hxx>
+#endif
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_HeaderFile
+#include <Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+#endif
+class Standard_NoSuchObject;
+class TopoDS_Shape;
+class GEOMAlgo_ShapeSet;
+class TopTools_ShapeMapHasher;
+class GEOMAlgo_DataMapOfShapeShapeSet;
+class GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet : public TCollection_BasicMapIterator {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet();
+
+
+Standard_EXPORT GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet(const GEOMAlgo_DataMapOfShapeShapeSet& aMap);
+
+
+Standard_EXPORT void Initialize(const GEOMAlgo_DataMapOfShapeShapeSet& aMap) ;
+
+
+Standard_EXPORT const TopoDS_Shape& Key() const;
+
+
+Standard_EXPORT const GEOMAlgo_ShapeSet& Value() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet.hxx>
+
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _GEOMAlgo_ShapeSet_HeaderFile
+#include <GEOMAlgo_ShapeSet.hxx>
+#endif
+#ifndef _TopTools_ShapeMapHasher_HeaderFile
+#include <TopTools_ShapeMapHasher.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapOfShapeShapeSet_HeaderFile
+#include <GEOMAlgo_DataMapOfShapeShapeSet.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_HeaderFile
+#include <GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+#endif
+
+
+#define TheKey TopoDS_Shape
+#define TheKey_hxx <TopoDS_Shape.hxx>
+#define TheItem GEOMAlgo_ShapeSet
+#define TheItem_hxx <GEOMAlgo_ShapeSet.hxx>
+#define Hasher TopTools_ShapeMapHasher
+#define Hasher_hxx <TopTools_ShapeMapHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfShapeShapeSet
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfShapeShapeSet.hxx>
+#include <TCollection_DataMapIterator.gxx>
+
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class GEOMAlgo_DataMapIteratorOfDataMapOfPassKeyInteger;
+
class GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger(const GEOMAlgo_PassKey& K,const Standard_Integer& I,const TCollection_MapNodePtr& n);
+
GEOMAlgo_PassKey& Key() const;
+
Standard_Integer& Value() const;
-Standard_EXPORT ~GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger();
+//Standard_EXPORT ~GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfPassKeyInteger_HeaderFile
#include <GEOMAlgo_DataMapIteratorOfDataMapOfPassKeyInteger.hxx>
#endif
-GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger::~GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger() {}
+//GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger::~GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger) ;
}
-Standard_Boolean GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger::~Handle_GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger() {}
+//Standard_Boolean GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger::~Handle_GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger() {}
#define TheKey GEOMAlgo_PassKey
#define TheKey_hxx <GEOMAlgo_PassKey.hxx>
#define TheItem Standard_Integer
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_HeaderFile
+#define _GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_HeaderFile
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_HeaderFile
+#include <Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+#endif
+
+#ifndef _Standard_Real_HeaderFile
+#include <Standard_Real.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TCollection_MapNode_HeaderFile
+#include <TCollection_MapNode.hxx>
+#endif
+#ifndef _TCollection_MapNodePtr_HeaderFile
+#include <TCollection_MapNodePtr.hxx>
+#endif
+class TopTools_ListOfShape;
+class TColStd_MapRealHasher;
+class GEOMAlgo_DataMapOfRealListOfShape;
+class GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape;
+
+
+
+class GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape : public TCollection_MapNode {
+
+public:
+ // Methods PUBLIC
+ //
+
+GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape(const Standard_Real& K,const TopTools_ListOfShape& I,const TCollection_MapNodePtr& n);
+
+ Standard_Real& Key() const;
+
+ TopTools_ListOfShape& Value() const;
+//Standard_EXPORT ~GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape();
+
+
+
+
+ // Type management
+ //
+ Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+Standard_Real myKey;
+TopTools_ListOfShape myValue;
+
+
+};
+
+#define TheKey Standard_Real
+#define TheKey_hxx <Standard_Real.hxx>
+#define TheItem TopTools_ListOfShape
+#define TheItem_hxx <TopTools_ListOfShape.hxx>
+#define Hasher TColStd_MapRealHasher
+#define Hasher_hxx <TColStd_MapRealHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfRealListOfShape
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfRealListOfShape.hxx>
+
+#include <TCollection_DataMapNode.lxx>
+
+#undef TheKey
+#undef TheKey_hxx
+#undef TheItem
+#undef TheItem_hxx
+#undef Hasher
+#undef Hasher_hxx
+#undef TCollection_DataMapNode
+#undef TCollection_DataMapNode_hxx
+#undef TCollection_DataMapIterator
+#undef TCollection_DataMapIterator_hxx
+#undef Handle_TCollection_DataMapNode
+#undef TCollection_DataMapNode_Type_
+#undef TCollection_DataMap
+#undef TCollection_DataMap_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+
+#ifndef _Standard_TypeMismatch_HeaderFile
+#include <Standard_TypeMismatch.hxx>
+#endif
+
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TColStd_MapRealHasher_HeaderFile
+#include <TColStd_MapRealHasher.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapOfRealListOfShape_HeaderFile
+#include <GEOMAlgo_DataMapOfRealListOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape_HeaderFile
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape.hxx>
+#endif
+//GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape::~GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape() {}
+
+
+
+Standard_EXPORT Handle_Standard_Type& GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_Type_()
+{
+
+ static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
+ static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
+ static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
+
+
+ static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
+ static Handle_Standard_Type _aType = new Standard_Type("GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape",
+ sizeof(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape),
+ 1,
+ (Standard_Address)_Ancestors,
+ (Standard_Address)NULL);
+
+ return _aType;
+}
+
+
+// DownCast method
+// allow safe downcasting
+//
+const Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape) Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)::DownCast(const Handle(Standard_Transient)& AnObject)
+{
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape) _anOtherObject;
+
+ if (!AnObject.IsNull()) {
+ if (AnObject->IsKind(STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape))) {
+ _anOtherObject = Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)((Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)&)AnObject);
+ }
+ }
+
+ return _anOtherObject ;
+}
+const Handle(Standard_Type)& GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape::DynamicType() const
+{
+ return STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape) ;
+}
+//Standard_Boolean GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape::~Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape() {}
+#define TheKey Standard_Real
+#define TheKey_hxx <Standard_Real.hxx>
+#define TheItem TopTools_ListOfShape
+#define TheItem_hxx <TopTools_ListOfShape.hxx>
+#define Hasher TColStd_MapRealHasher
+#define Hasher_hxx <TColStd_MapRealHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfRealListOfShape
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfRealListOfShape.hxx>
+#include <TCollection_DataMapNode.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_HeaderFile
+#define _GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_HeaderFile
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_HeaderFile
+#include <Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+#endif
+
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _Standard_Real_HeaderFile
+#include <Standard_Real.hxx>
+#endif
+#ifndef _TCollection_MapNode_HeaderFile
+#include <TCollection_MapNode.hxx>
+#endif
+#ifndef _TCollection_MapNodePtr_HeaderFile
+#include <TCollection_MapNodePtr.hxx>
+#endif
+class TopoDS_Shape;
+class TopTools_ShapeMapHasher;
+class GEOMAlgo_DataMapOfShapeReal;
+class GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal;
+
+
+
+class GEOMAlgo_DataMapNodeOfDataMapOfShapeReal : public TCollection_MapNode {
+
+public:
+ // Methods PUBLIC
+ //
+
+GEOMAlgo_DataMapNodeOfDataMapOfShapeReal(const TopoDS_Shape& K,const Standard_Real& I,const TCollection_MapNodePtr& n);
+
+ TopoDS_Shape& Key() const;
+
+ Standard_Real& Value() const;
+//Standard_EXPORT ~GEOMAlgo_DataMapNodeOfDataMapOfShapeReal();
+
+
+
+
+ // Type management
+ //
+ Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+TopoDS_Shape myKey;
+Standard_Real myValue;
+
+
+};
+
+#define TheKey TopoDS_Shape
+#define TheKey_hxx <TopoDS_Shape.hxx>
+#define TheItem Standard_Real
+#define TheItem_hxx <Standard_Real.hxx>
+#define Hasher TopTools_ShapeMapHasher
+#define Hasher_hxx <TopTools_ShapeMapHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfShapeReal
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfShapeReal
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfShapeReal.hxx>
+
+#include <TCollection_DataMapNode.lxx>
+
+#undef TheKey
+#undef TheKey_hxx
+#undef TheItem
+#undef TheItem_hxx
+#undef Hasher
+#undef Hasher_hxx
+#undef TCollection_DataMapNode
+#undef TCollection_DataMapNode_hxx
+#undef TCollection_DataMapIterator
+#undef TCollection_DataMapIterator_hxx
+#undef Handle_TCollection_DataMapNode
+#undef TCollection_DataMapNode_Type_
+#undef TCollection_DataMap
+#undef TCollection_DataMap_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+
+#ifndef _Standard_TypeMismatch_HeaderFile
+#include <Standard_TypeMismatch.hxx>
+#endif
+
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _TopTools_ShapeMapHasher_HeaderFile
+#include <TopTools_ShapeMapHasher.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapOfShapeReal_HeaderFile
+#include <GEOMAlgo_DataMapOfShapeReal.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal_HeaderFile
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal.hxx>
+#endif
+//GEOMAlgo_DataMapNodeOfDataMapOfShapeReal::~GEOMAlgo_DataMapNodeOfDataMapOfShapeReal() {}
+
+
+
+Standard_EXPORT Handle_Standard_Type& GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_Type_()
+{
+
+ static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
+ static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
+ static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
+
+
+ static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
+ static Handle_Standard_Type _aType = new Standard_Type("GEOMAlgo_DataMapNodeOfDataMapOfShapeReal",
+ sizeof(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal),
+ 1,
+ (Standard_Address)_Ancestors,
+ (Standard_Address)NULL);
+
+ return _aType;
+}
+
+
+// DownCast method
+// allow safe downcasting
+//
+const Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal) Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)::DownCast(const Handle(Standard_Transient)& AnObject)
+{
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal) _anOtherObject;
+
+ if (!AnObject.IsNull()) {
+ if (AnObject->IsKind(STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal))) {
+ _anOtherObject = Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)((Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)&)AnObject);
+ }
+ }
+
+ return _anOtherObject ;
+}
+const Handle(Standard_Type)& GEOMAlgo_DataMapNodeOfDataMapOfShapeReal::DynamicType() const
+{
+ return STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal) ;
+}
+//Standard_Boolean GEOMAlgo_DataMapNodeOfDataMapOfShapeReal::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal::~Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal() {}
+#define TheKey TopoDS_Shape
+#define TheKey_hxx <TopoDS_Shape.hxx>
+#define TheItem Standard_Real
+#define TheItem_hxx <Standard_Real.hxx>
+#define Hasher TopTools_ShapeMapHasher
+#define Hasher_hxx <TopTools_ShapeMapHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfShapeReal
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfShapeReal
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfShapeReal.hxx>
+#include <TCollection_DataMapNode.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_HeaderFile
+#define _GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_HeaderFile
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_HeaderFile
+#include <Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+#endif
+
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _GEOMAlgo_ShapeSet_HeaderFile
+#include <GEOMAlgo_ShapeSet.hxx>
+#endif
+#ifndef _TCollection_MapNode_HeaderFile
+#include <TCollection_MapNode.hxx>
+#endif
+#ifndef _TCollection_MapNodePtr_HeaderFile
+#include <TCollection_MapNodePtr.hxx>
+#endif
+class TopoDS_Shape;
+class GEOMAlgo_ShapeSet;
+class TopTools_ShapeMapHasher;
+class GEOMAlgo_DataMapOfShapeShapeSet;
+class GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet;
+
+
+
+class GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet : public TCollection_MapNode {
+
+public:
+ // Methods PUBLIC
+ //
+
+GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet(const TopoDS_Shape& K,const GEOMAlgo_ShapeSet& I,const TCollection_MapNodePtr& n);
+
+ TopoDS_Shape& Key() const;
+
+ GEOMAlgo_ShapeSet& Value() const;
+//Standard_EXPORT ~GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet();
+
+
+
+
+ // Type management
+ //
+ Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+TopoDS_Shape myKey;
+GEOMAlgo_ShapeSet myValue;
+
+
+};
+
+#define TheKey TopoDS_Shape
+#define TheKey_hxx <TopoDS_Shape.hxx>
+#define TheItem GEOMAlgo_ShapeSet
+#define TheItem_hxx <GEOMAlgo_ShapeSet.hxx>
+#define Hasher TopTools_ShapeMapHasher
+#define Hasher_hxx <TopTools_ShapeMapHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfShapeShapeSet
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfShapeShapeSet.hxx>
+
+#include <TCollection_DataMapNode.lxx>
+
+#undef TheKey
+#undef TheKey_hxx
+#undef TheItem
+#undef TheItem_hxx
+#undef Hasher
+#undef Hasher_hxx
+#undef TCollection_DataMapNode
+#undef TCollection_DataMapNode_hxx
+#undef TCollection_DataMapIterator
+#undef TCollection_DataMapIterator_hxx
+#undef Handle_TCollection_DataMapNode
+#undef TCollection_DataMapNode_Type_
+#undef TCollection_DataMap
+#undef TCollection_DataMap_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+
+#ifndef _Standard_TypeMismatch_HeaderFile
+#include <Standard_TypeMismatch.hxx>
+#endif
+
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _GEOMAlgo_ShapeSet_HeaderFile
+#include <GEOMAlgo_ShapeSet.hxx>
+#endif
+#ifndef _TopTools_ShapeMapHasher_HeaderFile
+#include <TopTools_ShapeMapHasher.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapOfShapeShapeSet_HeaderFile
+#include <GEOMAlgo_DataMapOfShapeShapeSet.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet_HeaderFile
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet.hxx>
+#endif
+//GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet::~GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet() {}
+
+
+
+Standard_EXPORT Handle_Standard_Type& GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_Type_()
+{
+
+ static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
+ static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
+ static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
+
+
+ static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
+ static Handle_Standard_Type _aType = new Standard_Type("GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet",
+ sizeof(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet),
+ 1,
+ (Standard_Address)_Ancestors,
+ (Standard_Address)NULL);
+
+ return _aType;
+}
+
+
+// DownCast method
+// allow safe downcasting
+//
+const Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet) Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)::DownCast(const Handle(Standard_Transient)& AnObject)
+{
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet) _anOtherObject;
+
+ if (!AnObject.IsNull()) {
+ if (AnObject->IsKind(STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet))) {
+ _anOtherObject = Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)((Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)&)AnObject);
+ }
+ }
+
+ return _anOtherObject ;
+}
+const Handle(Standard_Type)& GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet::DynamicType() const
+{
+ return STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet) ;
+}
+//Standard_Boolean GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet::~Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet() {}
+#define TheKey TopoDS_Shape
+#define TheKey_hxx <TopoDS_Shape.hxx>
+#define TheItem GEOMAlgo_ShapeSet
+#define TheItem_hxx <GEOMAlgo_ShapeSet.hxx>
+#define Hasher TopTools_ShapeMapHasher
+#define Hasher_hxx <TopTools_ShapeMapHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfShapeShapeSet
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfShapeShapeSet.hxx>
+#include <TCollection_DataMapNode.gxx>
+
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_DataMapOfPassKeyInteger : public TCollection_BasicMap {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_DataMapOfPassKeyInteger(const Standard_Integer NbBuckets = 1);
+
+
Standard_EXPORT GEOMAlgo_DataMapOfPassKeyInteger& Assign(const GEOMAlgo_DataMapOfPassKeyInteger& Other) ;
GEOMAlgo_DataMapOfPassKeyInteger& operator =(const GEOMAlgo_DataMapOfPassKeyInteger& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
Standard_EXPORT void Clear() ;
~GEOMAlgo_DataMapOfPassKeyInteger()
{
Clear();
}
+
+
Standard_EXPORT Standard_Boolean Bind(const GEOMAlgo_PassKey& K,const Standard_Integer& I) ;
+
+
Standard_EXPORT Standard_Boolean IsBound(const GEOMAlgo_PassKey& K) const;
+
+
Standard_EXPORT Standard_Boolean UnBind(const GEOMAlgo_PassKey& K) ;
+
+
Standard_EXPORT const Standard_Integer& Find(const GEOMAlgo_PassKey& K) const;
const Standard_Integer& operator()(const GEOMAlgo_PassKey& K) const
{
return Find(K);
}
+
+
Standard_EXPORT Standard_Integer& ChangeFind(const GEOMAlgo_PassKey& K) ;
Standard_Integer& operator()(const GEOMAlgo_PassKey& K)
{
// Methods PRIVATE
//
+
+
Standard_EXPORT GEOMAlgo_DataMapOfPassKeyInteger(const GEOMAlgo_DataMapOfPassKeyInteger& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_DataMapOfRealListOfShape_HeaderFile
+#define _GEOMAlgo_DataMapOfRealListOfShape_HeaderFile
+
+#ifndef _TCollection_BasicMap_HeaderFile
+#include <TCollection_BasicMap.hxx>
+#endif
+#ifndef _Standard_Real_HeaderFile
+#include <Standard_Real.hxx>
+#endif
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_HeaderFile
+#include <Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class Standard_DomainError;
+class Standard_NoSuchObject;
+class TopTools_ListOfShape;
+class TColStd_MapRealHasher;
+class GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape;
+class GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class GEOMAlgo_DataMapOfRealListOfShape : public TCollection_BasicMap {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT GEOMAlgo_DataMapOfRealListOfShape(const Standard_Integer NbBuckets = 1);
+
+
+Standard_EXPORT GEOMAlgo_DataMapOfRealListOfShape& Assign(const GEOMAlgo_DataMapOfRealListOfShape& Other) ;
+ GEOMAlgo_DataMapOfRealListOfShape& operator =(const GEOMAlgo_DataMapOfRealListOfShape& Other)
+{
+ return Assign(Other);
+}
+
+
+
+Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
+Standard_EXPORT void Clear() ;
+~GEOMAlgo_DataMapOfRealListOfShape()
+{
+ Clear();
+}
+
+
+
+Standard_EXPORT Standard_Boolean Bind(const Standard_Real& K,const TopTools_ListOfShape& I) ;
+
+
+Standard_EXPORT Standard_Boolean IsBound(const Standard_Real& K) const;
+
+
+Standard_EXPORT Standard_Boolean UnBind(const Standard_Real& K) ;
+
+
+Standard_EXPORT const TopTools_ListOfShape& Find(const Standard_Real& K) const;
+ const TopTools_ListOfShape& operator()(const Standard_Real& K) const
+{
+ return Find(K);
+}
+
+
+
+Standard_EXPORT TopTools_ListOfShape& ChangeFind(const Standard_Real& K) ;
+ TopTools_ListOfShape& operator()(const Standard_Real& K)
+{
+ return ChangeFind(K);
+}
+
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+Standard_EXPORT GEOMAlgo_DataMapOfRealListOfShape(const GEOMAlgo_DataMapOfRealListOfShape& Other);
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_DataMapOfRealListOfShape.hxx>
+
+#ifndef _Standard_DomainError_HeaderFile
+#include <Standard_DomainError.hxx>
+#endif
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TColStd_MapRealHasher_HeaderFile
+#include <TColStd_MapRealHasher.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_HeaderFile
+#include <GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape_HeaderFile
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape.hxx>
+#endif
+
+
+#define TheKey Standard_Real
+#define TheKey_hxx <Standard_Real.hxx>
+#define TheItem TopTools_ListOfShape
+#define TheItem_hxx <TopTools_ListOfShape.hxx>
+#define Hasher TColStd_MapRealHasher
+#define Hasher_hxx <TColStd_MapRealHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfRealListOfShape
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfRealListOfShape.hxx>
+#include <TCollection_DataMap.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_DataMapOfShapeReal_HeaderFile
+#define _GEOMAlgo_DataMapOfShapeReal_HeaderFile
+
+#ifndef _TCollection_BasicMap_HeaderFile
+#include <TCollection_BasicMap.hxx>
+#endif
+#ifndef _Standard_Real_HeaderFile
+#include <Standard_Real.hxx>
+#endif
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_HeaderFile
+#include <Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class Standard_DomainError;
+class Standard_NoSuchObject;
+class TopoDS_Shape;
+class TopTools_ShapeMapHasher;
+class GEOMAlgo_DataMapNodeOfDataMapOfShapeReal;
+class GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class GEOMAlgo_DataMapOfShapeReal : public TCollection_BasicMap {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT GEOMAlgo_DataMapOfShapeReal(const Standard_Integer NbBuckets = 1);
+
+
+Standard_EXPORT GEOMAlgo_DataMapOfShapeReal& Assign(const GEOMAlgo_DataMapOfShapeReal& Other) ;
+ GEOMAlgo_DataMapOfShapeReal& operator =(const GEOMAlgo_DataMapOfShapeReal& Other)
+{
+ return Assign(Other);
+}
+
+
+
+Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
+Standard_EXPORT void Clear() ;
+~GEOMAlgo_DataMapOfShapeReal()
+{
+ Clear();
+}
+
+
+
+Standard_EXPORT Standard_Boolean Bind(const TopoDS_Shape& K,const Standard_Real& I) ;
+
+
+Standard_EXPORT Standard_Boolean IsBound(const TopoDS_Shape& K) const;
+
+
+Standard_EXPORT Standard_Boolean UnBind(const TopoDS_Shape& K) ;
+
+
+Standard_EXPORT const Standard_Real& Find(const TopoDS_Shape& K) const;
+ const Standard_Real& operator()(const TopoDS_Shape& K) const
+{
+ return Find(K);
+}
+
+
+
+Standard_EXPORT Standard_Real& ChangeFind(const TopoDS_Shape& K) ;
+ Standard_Real& operator()(const TopoDS_Shape& K)
+{
+ return ChangeFind(K);
+}
+
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+Standard_EXPORT GEOMAlgo_DataMapOfShapeReal(const GEOMAlgo_DataMapOfShapeReal& Other);
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_DataMapOfShapeReal.hxx>
+
+#ifndef _Standard_DomainError_HeaderFile
+#include <Standard_DomainError.hxx>
+#endif
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _TopTools_ShapeMapHasher_HeaderFile
+#include <TopTools_ShapeMapHasher.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_HeaderFile
+#include <GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal_HeaderFile
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal.hxx>
+#endif
+
+
+#define TheKey TopoDS_Shape
+#define TheKey_hxx <TopoDS_Shape.hxx>
+#define TheItem Standard_Real
+#define TheItem_hxx <Standard_Real.hxx>
+#define Hasher TopTools_ShapeMapHasher
+#define Hasher_hxx <TopTools_ShapeMapHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfShapeReal
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfShapeReal
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfShapeReal.hxx>
+#include <TCollection_DataMap.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_DataMapOfShapeShapeSet_HeaderFile
+#define _GEOMAlgo_DataMapOfShapeShapeSet_HeaderFile
+
+#ifndef _TCollection_BasicMap_HeaderFile
+#include <TCollection_BasicMap.hxx>
+#endif
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_HeaderFile
+#include <Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class Standard_DomainError;
+class Standard_NoSuchObject;
+class TopoDS_Shape;
+class GEOMAlgo_ShapeSet;
+class TopTools_ShapeMapHasher;
+class GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet;
+class GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class GEOMAlgo_DataMapOfShapeShapeSet : public TCollection_BasicMap {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT GEOMAlgo_DataMapOfShapeShapeSet(const Standard_Integer NbBuckets = 1);
+
+
+Standard_EXPORT GEOMAlgo_DataMapOfShapeShapeSet& Assign(const GEOMAlgo_DataMapOfShapeShapeSet& Other) ;
+ GEOMAlgo_DataMapOfShapeShapeSet& operator =(const GEOMAlgo_DataMapOfShapeShapeSet& Other)
+{
+ return Assign(Other);
+}
+
+
+
+Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
+Standard_EXPORT void Clear() ;
+~GEOMAlgo_DataMapOfShapeShapeSet()
+{
+ Clear();
+}
+
+
+
+Standard_EXPORT Standard_Boolean Bind(const TopoDS_Shape& K,const GEOMAlgo_ShapeSet& I) ;
+
+
+Standard_EXPORT Standard_Boolean IsBound(const TopoDS_Shape& K) const;
+
+
+Standard_EXPORT Standard_Boolean UnBind(const TopoDS_Shape& K) ;
+
+
+Standard_EXPORT const GEOMAlgo_ShapeSet& Find(const TopoDS_Shape& K) const;
+ const GEOMAlgo_ShapeSet& operator()(const TopoDS_Shape& K) const
+{
+ return Find(K);
+}
+
+
+
+Standard_EXPORT GEOMAlgo_ShapeSet& ChangeFind(const TopoDS_Shape& K) ;
+ GEOMAlgo_ShapeSet& operator()(const TopoDS_Shape& K)
+{
+ return ChangeFind(K);
+}
+
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+Standard_EXPORT GEOMAlgo_DataMapOfShapeShapeSet(const GEOMAlgo_DataMapOfShapeShapeSet& Other);
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_DataMapOfShapeShapeSet.hxx>
+
+#ifndef _Standard_DomainError_HeaderFile
+#include <Standard_DomainError.hxx>
+#endif
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _GEOMAlgo_ShapeSet_HeaderFile
+#include <GEOMAlgo_ShapeSet.hxx>
+#endif
+#ifndef _TopTools_ShapeMapHasher_HeaderFile
+#include <TopTools_ShapeMapHasher.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_HeaderFile
+#include <GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+#endif
+#ifndef _GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet_HeaderFile
+#include <GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet.hxx>
+#endif
+
+
+#define TheKey TopoDS_Shape
+#define TheKey_hxx <TopoDS_Shape.hxx>
+#define TheItem GEOMAlgo_ShapeSet
+#define TheItem_hxx <GEOMAlgo_ShapeSet.hxx>
+#define Hasher TopTools_ShapeMapHasher
+#define Hasher_hxx <TopTools_ShapeMapHasher.hxx>
+#define TCollection_DataMapNode GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet
+#define TCollection_DataMapNode_hxx <GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx>
+#define TCollection_DataMapIterator GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet
+#define TCollection_DataMapIterator_hxx <GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet.hxx>
+#define Handle_TCollection_DataMapNode Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet
+#define TCollection_DataMapNode_Type_() GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_Type_()
+#define TCollection_DataMap GEOMAlgo_DataMapOfShapeShapeSet
+#define TCollection_DataMap_hxx <GEOMAlgo_DataMapOfShapeShapeSet.hxx>
+#include <TCollection_DataMap.gxx>
+
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_FinderShapeOn.cdl
-- Created: Tue Jan 11 14:35:52 2005
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_FinderShapeOn : public GEOMAlgo_ShapeAlgo {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_FinderShapeOn();
Standard_EXPORT virtual ~GEOMAlgo_FinderShapeOn();
+
+
Standard_EXPORT virtual void Perform() ;
+
+
Standard_EXPORT void SetSurface(const Handle(Geom_Surface)& aS) ;
+
+
Standard_EXPORT void SetShapeType(const TopAbs_ShapeEnum aST) ;
+
+
Standard_EXPORT void SetState(const GEOMAlgo_State aSF) ;
+
+
Standard_EXPORT const Handle_Geom_Surface& Surface() const;
+
+
Standard_EXPORT TopAbs_ShapeEnum ShapeType() const;
+
+
Standard_EXPORT GEOMAlgo_State State() const;
+
+
Standard_EXPORT const TopTools_ListOfShape& Shapes() const;
+
+
Standard_EXPORT static void CopySource(const TopoDS_Shape& aS,TopTools_DataMapOfShapeShape& aImages,TopTools_DataMapOfShapeShape& aOriginals,TopoDS_Shape& aSC) ;
// Methods PROTECTED
//
+
+
Standard_EXPORT virtual void CheckData() ;
+
+
Standard_EXPORT void MakeArgument1() ;
+
+
Standard_EXPORT void MakeArgument2() ;
+
+
Standard_EXPORT void Find() ;
+
+
Standard_EXPORT void Find(const TopoDS_Shape& aS) ;
+
+
Standard_EXPORT void FindVertices() ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _Geom_Surface_HeaderFile
#include <Geom_Surface.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_FinderShapeOn1.cdl
-- Created: Fri Mar 4 10:26:54 2005
-- Author: Peter KURNEV
---Purpose:
-uses
+uses
+ Pnt from gp,--
Surface from Geom,
Surface from GeomAdaptor,
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _GEOMAlgo_ShapeAlgo_HeaderFile
#include <GEOMAlgo_ShapeAlgo.hxx>
#endif
+#ifndef _TopAbs_State_HeaderFile
+#include <TopAbs_State.hxx>
+#endif
class Geom_Surface;
class TopTools_ListOfShape;
class TopoDS_Face;
class GEOMAlgo_ListOfPnt;
class TopoDS_Edge;
class GEOMAlgo_IndexedDataMapOfShapeState;
+class gp_Pnt;
#ifndef _Standard_HeaderFile
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_FinderShapeOn1 : public GEOMAlgo_ShapeAlgo {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_FinderShapeOn1();
Standard_EXPORT virtual ~GEOMAlgo_FinderShapeOn1();
+
+
Standard_EXPORT void SetSurface(const Handle(Geom_Surface)& aS) ;
+
+
Standard_EXPORT void SetShapeType(const TopAbs_ShapeEnum aST) ;
+
+
Standard_EXPORT void SetState(const GEOMAlgo_State aSF) ;
+
+
Standard_EXPORT void SetNbPntsMin(const Standard_Integer aNb) ;
+
+
Standard_EXPORT Standard_Integer NbPntsMin() const;
+
+
Standard_EXPORT void SetNbPntsMax(const Standard_Integer aNb) ;
+
+
Standard_EXPORT Standard_Integer NbPntsMax() const;
+
+
Standard_EXPORT const Handle_Geom_Surface& Surface() const;
+
+
Standard_EXPORT TopAbs_ShapeEnum ShapeType() const;
+
+
Standard_EXPORT GEOMAlgo_State State() const;
+
+
Standard_EXPORT virtual void Perform() ;
+
+
Standard_EXPORT const TopTools_ListOfShape& Shapes() const;
+
+
Standard_EXPORT const GEOMAlgo_IndexedDataMapOfShapeState& MSS() const;
// Methods PROTECTED
//
+
+
Standard_EXPORT virtual void CheckData() ;
+
+
Standard_EXPORT void ProcessVertices() ;
+
+
Standard_EXPORT void ProcessEdges() ;
+
+
Standard_EXPORT void ProcessFaces() ;
+
+
Standard_EXPORT void ProcessSolids() ;
+
+
Standard_EXPORT void InnerPoints(const TopoDS_Face& aF,GEOMAlgo_ListOfPnt& aLP) ;
+
+
Standard_EXPORT void InnerPoints(const TopoDS_Edge& aE,GEOMAlgo_ListOfPnt& aLP) ;
+
+
Standard_EXPORT void InnerPoints(const TopoDS_Edge& aE,const Standard_Integer aNbPnts,GEOMAlgo_ListOfPnt& aLP) ;
-Standard_EXPORT virtual TopAbs_State GetPointState(const gp_Pnt& aP) ;
+
+
+Standard_EXPORT virtual TopAbs_State GetPointState(const gp_Pnt& aP) ;
// Fields PROTECTED
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _Geom_Surface_HeaderFile
#include <Geom_Surface.hxx>
#endif
#ifndef _GEOMAlgo_IndexedDataMapOfShapeState_HeaderFile
#include <GEOMAlgo_IndexedDataMapOfShapeState.hxx>
#endif
+#ifndef _gp_Pnt_HeaderFile
+#include <gp_Pnt.hxx>
+#endif
#ifndef _GEOMAlgo_FinderShapeOn1_HeaderFile
#include <GEOMAlgo_FinderShapeOn1.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_GlueAnalyser.cdl
-- Created: Wed Dec 15 11:03:03 2004
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_GlueAnalyser : public GEOMAlgo_Gluer {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_GlueAnalyser();
Standard_EXPORT virtual ~GEOMAlgo_GlueAnalyser();
+
+
Standard_EXPORT virtual void Perform() ;
+
+
Standard_EXPORT Standard_Boolean HasSolidsToGlue() const;
+
+
Standard_EXPORT const GEOMAlgo_ListOfCoupleOfShapes& SolidsToGlue() const;
+
+
Standard_EXPORT Standard_Boolean HasSolidsAlone() const;
+
+
Standard_EXPORT const TopTools_ListOfShape& SolidsAlone() const;
// Methods PROTECTED
//
+
+
Standard_EXPORT void DetectVertices() ;
+
+
Standard_EXPORT void DetectEdges() ;
+
+
Standard_EXPORT void DetectFaces() ;
+
+
Standard_EXPORT void DetectShapes(const TopAbs_ShapeEnum aType) ;
+
+
Standard_EXPORT void DetectSolids() ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _GEOMAlgo_ListOfCoupleOfShapes_HeaderFile
#include <GEOMAlgo_ListOfCoupleOfShapes.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_Gluer.cdl
-- Created: Sat Dec 04 12:41:32 2004
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_Gluer : public GEOMAlgo_ShapeAlgo {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_Gluer();
Standard_EXPORT virtual ~GEOMAlgo_Gluer();
+
+
Standard_EXPORT void SetCheckGeometry(const Standard_Boolean aFlag) ;
+
+
Standard_EXPORT Standard_Boolean CheckGeometry() const;
+
+
Standard_EXPORT virtual void Perform() ;
+
+
Standard_EXPORT Standard_Integer AloneShapes() const;
+
+
Standard_EXPORT const TopTools_ListOfShape& Modified(const TopoDS_Shape& S) ;
+
+
Standard_EXPORT const TopTools_ListOfShape& Generated(const TopoDS_Shape& S) ;
+
+
Standard_EXPORT Standard_Boolean IsDeleted(const TopoDS_Shape& S) ;
+
+
Standard_EXPORT const TopTools_DataMapOfShapeListOfShape& Images() const;
+
+
Standard_EXPORT const TopTools_DataMapOfShapeShape& Origins() const;
// Methods PROTECTED
//
+
+
Standard_EXPORT virtual void CheckData() ;
+
+
Standard_EXPORT virtual void CheckResult() ;
+
+
Standard_EXPORT void MakeVertices() ;
+
+
Standard_EXPORT void MakeEdges() ;
+
+
Standard_EXPORT void MakeFaces() ;
+
+
Standard_EXPORT void MakeShapes(const TopAbs_ShapeEnum aType) ;
+
+
Standard_EXPORT void MakeShells() ;
+
+
Standard_EXPORT void MakeSolids() ;
+
+
Standard_EXPORT void InnerTolerance() ;
+
+
Standard_EXPORT void EdgePassKey(const TopoDS_Edge& aE,GEOMAlgo_PassKeyShape& aPK) ;
+
+
Standard_EXPORT void FacePassKey(const TopoDS_Face& aF,GEOMAlgo_PassKeyShape& aPK) ;
+
+
Standard_EXPORT void MakeVertex(const TopTools_ListOfShape& aLV,TopoDS_Vertex& aNewV) ;
+
+
Standard_EXPORT void MakeEdge(const TopoDS_Edge& aEdge,TopoDS_Edge& aNewEdge) ;
+
+
Standard_EXPORT void MakeFace(const TopoDS_Face& aFace,TopoDS_Face& aNewEdge) ;
+
+
Standard_EXPORT Standard_Boolean IsToReverse(const TopoDS_Face& aFR,const TopoDS_Face& aF) ;
+
+
Standard_EXPORT Standard_Boolean HasNewSubShape(const TopoDS_Shape& aS) const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopTools_ListOfShape_HeaderFile
#include <TopTools_ListOfShape.hxx>
#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class GEOMAlgo_IndexedDataMapOfIntegerShape;
+
class GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape(const Standard_Integer& K1,const Standard_Integer K2,const TopoDS_Shape& I,const TCollection_MapNodePtr& n1,const TCollection_MapNodePtr& n2);
+
Standard_Integer& Key1() const;
+
Standard_Integer& Key2() const;
+
TCollection_MapNodePtr& Next2() const;
+
TopoDS_Shape& Value() const;
-Standard_EXPORT ~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape();
+//Standard_EXPORT ~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _GEOMAlgo_IndexedDataMapOfIntegerShape_HeaderFile
#include <GEOMAlgo_IndexedDataMapOfIntegerShape.hxx>
#endif
-GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape::~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape() {}
+//GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape::~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape) ;
}
-Standard_Boolean GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape::~Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape() {}
+//Standard_Boolean GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape::~Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape() {}
#define TheKey Standard_Integer
#define TheKey_hxx <Standard_Integer.hxx>
#define TheItem TopoDS_Shape
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape;
+
class GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape(const GEOMAlgo_PassKeyShape& K1,const Standard_Integer K2,const TopTools_ListOfShape& I,const TCollection_MapNodePtr& n1,const TCollection_MapNodePtr& n2);
+
GEOMAlgo_PassKeyShape& Key1() const;
+
Standard_Integer& Key2() const;
+
TCollection_MapNodePtr& Next2() const;
+
TopTools_ListOfShape& Value() const;
-Standard_EXPORT ~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape();
+//Standard_EXPORT ~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape_HeaderFile
#include <GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape.hxx>
#endif
-GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape::~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape() {}
+//GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape::~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape) ;
}
-Standard_Boolean GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape::~Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape() {}
+//Standard_Boolean GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape::~Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape() {}
#define TheKey GEOMAlgo_PassKeyShape
#define TheKey_hxx <GEOMAlgo_PassKeyShape.hxx>
#define TheItem TopTools_ListOfShape
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class GEOMAlgo_IndexedDataMapOfShapeBox;
+
class GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox(const TopoDS_Shape& K1,const Standard_Integer K2,const Bnd_Box& I,const TCollection_MapNodePtr& n1,const TCollection_MapNodePtr& n2);
+
TopoDS_Shape& Key1() const;
+
Standard_Integer& Key2() const;
+
TCollection_MapNodePtr& Next2() const;
+
Bnd_Box& Value() const;
-Standard_EXPORT ~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox();
+//Standard_EXPORT ~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _GEOMAlgo_IndexedDataMapOfShapeBox_HeaderFile
#include <GEOMAlgo_IndexedDataMapOfShapeBox.hxx>
#endif
-GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox::~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox() {}
+//GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox::~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox) ;
}
-Standard_Boolean GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox::~Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox() {}
+//Standard_Boolean GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox::~Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox() {}
#define TheKey TopoDS_Shape
#define TheKey_hxx <TopoDS_Shape.hxx>
#define TheItem Bnd_Box
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class GEOMAlgo_IndexedDataMapOfShapeState;
+
class GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState(const TopoDS_Shape& K1,const Standard_Integer K2,const TopAbs_State& I,const TCollection_MapNodePtr& n1,const TCollection_MapNodePtr& n2);
+
TopoDS_Shape& Key1() const;
+
Standard_Integer& Key2() const;
+
TCollection_MapNodePtr& Next2() const;
+
TopAbs_State& Value() const;
-Standard_EXPORT ~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState();
+//Standard_EXPORT ~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _GEOMAlgo_IndexedDataMapOfShapeState_HeaderFile
#include <GEOMAlgo_IndexedDataMapOfShapeState.hxx>
#endif
-GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState::~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState() {}
+//GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState::~GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState) ;
}
-Standard_Boolean GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState::~Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState() {}
+//Standard_Boolean GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState::~Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState() {}
#define TheKey TopoDS_Shape
#define TheKey_hxx <TopoDS_Shape.hxx>
#define TheItem TopAbs_State
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_IndexedDataMapOfIntegerShape : public TCollection_BasicMap {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfIntegerShape(const Standard_Integer NbBuckets = 1);
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfIntegerShape& Assign(const GEOMAlgo_IndexedDataMapOfIntegerShape& Other) ;
GEOMAlgo_IndexedDataMapOfIntegerShape& operator =(const GEOMAlgo_IndexedDataMapOfIntegerShape& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
Standard_EXPORT void Clear() ;
~GEOMAlgo_IndexedDataMapOfIntegerShape()
{
Clear();
}
+
+
Standard_EXPORT Standard_Integer Add(const Standard_Integer& K,const TopoDS_Shape& I) ;
+
+
Standard_EXPORT void Substitute(const Standard_Integer I,const Standard_Integer& K,const TopoDS_Shape& T) ;
+
+
Standard_EXPORT void RemoveLast() ;
+
+
Standard_EXPORT Standard_Boolean Contains(const Standard_Integer& K) const;
+
+
Standard_EXPORT const Standard_Integer& FindKey(const Standard_Integer I) const;
+
+
Standard_EXPORT const TopoDS_Shape& FindFromIndex(const Standard_Integer I) const;
const TopoDS_Shape& operator ()(const Standard_Integer I) const
{
return FindFromIndex(I);
}
+
+
Standard_EXPORT TopoDS_Shape& ChangeFromIndex(const Standard_Integer I) ;
TopoDS_Shape& operator ()(const Standard_Integer I)
{
return ChangeFromIndex(I);
}
+
+
Standard_EXPORT Standard_Integer FindIndex(const Standard_Integer& K) const;
+
+
Standard_EXPORT const TopoDS_Shape& FindFromKey(const Standard_Integer& K) const;
+
+
Standard_EXPORT TopoDS_Shape& ChangeFromKey(const Standard_Integer& K) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfIntegerShape(const GEOMAlgo_IndexedDataMapOfIntegerShape& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape : public TCollection_BasicMap {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape(const Standard_Integer NbBuckets = 1);
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape& Assign(const GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape& Other) ;
GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape& operator =(const GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
Standard_EXPORT void Clear() ;
~GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape()
{
Clear();
}
+
+
Standard_EXPORT Standard_Integer Add(const GEOMAlgo_PassKeyShape& K,const TopTools_ListOfShape& I) ;
+
+
Standard_EXPORT void Substitute(const Standard_Integer I,const GEOMAlgo_PassKeyShape& K,const TopTools_ListOfShape& T) ;
+
+
Standard_EXPORT void RemoveLast() ;
+
+
Standard_EXPORT Standard_Boolean Contains(const GEOMAlgo_PassKeyShape& K) const;
+
+
Standard_EXPORT const GEOMAlgo_PassKeyShape& FindKey(const Standard_Integer I) const;
+
+
Standard_EXPORT const TopTools_ListOfShape& FindFromIndex(const Standard_Integer I) const;
const TopTools_ListOfShape& operator ()(const Standard_Integer I) const
{
return FindFromIndex(I);
}
+
+
Standard_EXPORT TopTools_ListOfShape& ChangeFromIndex(const Standard_Integer I) ;
TopTools_ListOfShape& operator ()(const Standard_Integer I)
{
return ChangeFromIndex(I);
}
+
+
Standard_EXPORT Standard_Integer FindIndex(const GEOMAlgo_PassKeyShape& K) const;
+
+
Standard_EXPORT const TopTools_ListOfShape& FindFromKey(const GEOMAlgo_PassKeyShape& K) const;
+
+
Standard_EXPORT TopTools_ListOfShape& ChangeFromKey(const GEOMAlgo_PassKeyShape& K) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape(const GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_IndexedDataMapOfShapeBox : public TCollection_BasicMap {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfShapeBox(const Standard_Integer NbBuckets = 1);
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfShapeBox& Assign(const GEOMAlgo_IndexedDataMapOfShapeBox& Other) ;
GEOMAlgo_IndexedDataMapOfShapeBox& operator =(const GEOMAlgo_IndexedDataMapOfShapeBox& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
Standard_EXPORT void Clear() ;
~GEOMAlgo_IndexedDataMapOfShapeBox()
{
Clear();
}
+
+
Standard_EXPORT Standard_Integer Add(const TopoDS_Shape& K,const Bnd_Box& I) ;
+
+
Standard_EXPORT void Substitute(const Standard_Integer I,const TopoDS_Shape& K,const Bnd_Box& T) ;
+
+
Standard_EXPORT void RemoveLast() ;
+
+
Standard_EXPORT Standard_Boolean Contains(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT const TopoDS_Shape& FindKey(const Standard_Integer I) const;
+
+
Standard_EXPORT const Bnd_Box& FindFromIndex(const Standard_Integer I) const;
const Bnd_Box& operator ()(const Standard_Integer I) const
{
return FindFromIndex(I);
}
+
+
Standard_EXPORT Bnd_Box& ChangeFromIndex(const Standard_Integer I) ;
Bnd_Box& operator ()(const Standard_Integer I)
{
return ChangeFromIndex(I);
}
+
+
Standard_EXPORT Standard_Integer FindIndex(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT const Bnd_Box& FindFromKey(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT Bnd_Box& ChangeFromKey(const TopoDS_Shape& K) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfShapeBox(const GEOMAlgo_IndexedDataMapOfShapeBox& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_IndexedDataMapOfShapeState : public TCollection_BasicMap {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfShapeState(const Standard_Integer NbBuckets = 1);
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfShapeState& Assign(const GEOMAlgo_IndexedDataMapOfShapeState& Other) ;
GEOMAlgo_IndexedDataMapOfShapeState& operator =(const GEOMAlgo_IndexedDataMapOfShapeState& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
Standard_EXPORT void Clear() ;
~GEOMAlgo_IndexedDataMapOfShapeState()
{
Clear();
}
+
+
Standard_EXPORT Standard_Integer Add(const TopoDS_Shape& K,const TopAbs_State& I) ;
+
+
Standard_EXPORT void Substitute(const Standard_Integer I,const TopoDS_Shape& K,const TopAbs_State& T) ;
+
+
Standard_EXPORT void RemoveLast() ;
+
+
Standard_EXPORT Standard_Boolean Contains(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT const TopoDS_Shape& FindKey(const Standard_Integer I) const;
+
+
Standard_EXPORT const TopAbs_State& FindFromIndex(const Standard_Integer I) const;
const TopAbs_State& operator ()(const Standard_Integer I) const
{
return FindFromIndex(I);
}
+
+
Standard_EXPORT TopAbs_State& ChangeFromIndex(const Standard_Integer I) ;
TopAbs_State& operator ()(const Standard_Integer I)
{
return ChangeFromIndex(I);
}
+
+
Standard_EXPORT Standard_Integer FindIndex(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT const TopAbs_State& FindFromKey(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT TopAbs_State& ChangeFromKey(const TopoDS_Shape& K) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT GEOMAlgo_IndexedDataMapOfShapeState(const GEOMAlgo_IndexedDataMapOfShapeState& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_ListIteratorOfListOfCoupleOfShapes {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_ListIteratorOfListOfCoupleOfShapes();
+
+
Standard_EXPORT GEOMAlgo_ListIteratorOfListOfCoupleOfShapes(const GEOMAlgo_ListOfCoupleOfShapes& L);
+
+
Standard_EXPORT void Initialize(const GEOMAlgo_ListOfCoupleOfShapes& L) ;
+
Standard_Boolean More() const;
+
+
Standard_EXPORT void Next() ;
+
+
Standard_EXPORT GEOMAlgo_CoupleOfShapes& Value() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_ListIteratorOfListOfPnt {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_ListIteratorOfListOfPnt();
+
+
Standard_EXPORT GEOMAlgo_ListIteratorOfListOfPnt(const GEOMAlgo_ListOfPnt& L);
+
+
Standard_EXPORT void Initialize(const GEOMAlgo_ListOfPnt& L) ;
+
Standard_Boolean More() const;
+
+
Standard_EXPORT void Next() ;
+
+
Standard_EXPORT gp_Pnt& Value() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class GEOMAlgo_ListIteratorOfListOfCoupleOfShapes;
+
class GEOMAlgo_ListNodeOfListOfCoupleOfShapes : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
GEOMAlgo_ListNodeOfListOfCoupleOfShapes(const GEOMAlgo_CoupleOfShapes& I,const TCollection_MapNodePtr& n);
+
GEOMAlgo_CoupleOfShapes& Value() const;
-Standard_EXPORT ~GEOMAlgo_ListNodeOfListOfCoupleOfShapes();
+//Standard_EXPORT ~GEOMAlgo_ListNodeOfListOfCoupleOfShapes();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& GEOMAlgo_ListNodeOfListOfCoupleOfShapes_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _GEOMAlgo_ListIteratorOfListOfCoupleOfShapes_HeaderFile
#include <GEOMAlgo_ListIteratorOfListOfCoupleOfShapes.hxx>
#endif
-GEOMAlgo_ListNodeOfListOfCoupleOfShapes::~GEOMAlgo_ListNodeOfListOfCoupleOfShapes() {}
+//GEOMAlgo_ListNodeOfListOfCoupleOfShapes::~GEOMAlgo_ListNodeOfListOfCoupleOfShapes() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(GEOMAlgo_ListNodeOfListOfCoupleOfShapes) ;
}
-Standard_Boolean GEOMAlgo_ListNodeOfListOfCoupleOfShapes::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(GEOMAlgo_ListNodeOfListOfCoupleOfShapes) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_GEOMAlgo_ListNodeOfListOfCoupleOfShapes::~Handle_GEOMAlgo_ListNodeOfListOfCoupleOfShapes() {}
+//Standard_Boolean GEOMAlgo_ListNodeOfListOfCoupleOfShapes::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_ListNodeOfListOfCoupleOfShapes) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_ListNodeOfListOfCoupleOfShapes::~Handle_GEOMAlgo_ListNodeOfListOfCoupleOfShapes() {}
#define Item GEOMAlgo_CoupleOfShapes
#define Item_hxx <GEOMAlgo_CoupleOfShapes.hxx>
#define TCollection_ListNode GEOMAlgo_ListNodeOfListOfCoupleOfShapes
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class GEOMAlgo_ListIteratorOfListOfPnt;
+
class GEOMAlgo_ListNodeOfListOfPnt : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
GEOMAlgo_ListNodeOfListOfPnt(const gp_Pnt& I,const TCollection_MapNodePtr& n);
+
gp_Pnt& Value() const;
-Standard_EXPORT ~GEOMAlgo_ListNodeOfListOfPnt();
+//Standard_EXPORT ~GEOMAlgo_ListNodeOfListOfPnt();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& GEOMAlgo_ListNodeOfListOfPnt_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _GEOMAlgo_ListIteratorOfListOfPnt_HeaderFile
#include <GEOMAlgo_ListIteratorOfListOfPnt.hxx>
#endif
-GEOMAlgo_ListNodeOfListOfPnt::~GEOMAlgo_ListNodeOfListOfPnt() {}
+//GEOMAlgo_ListNodeOfListOfPnt::~GEOMAlgo_ListNodeOfListOfPnt() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(GEOMAlgo_ListNodeOfListOfPnt) ;
}
-Standard_Boolean GEOMAlgo_ListNodeOfListOfPnt::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(GEOMAlgo_ListNodeOfListOfPnt) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_GEOMAlgo_ListNodeOfListOfPnt::~Handle_GEOMAlgo_ListNodeOfListOfPnt() {}
+//Standard_Boolean GEOMAlgo_ListNodeOfListOfPnt::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(GEOMAlgo_ListNodeOfListOfPnt) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_GEOMAlgo_ListNodeOfListOfPnt::~Handle_GEOMAlgo_ListNodeOfListOfPnt() {}
#define Item gp_Pnt
#define Item_hxx <gp_Pnt.hxx>
#define TCollection_ListNode GEOMAlgo_ListNodeOfListOfPnt
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_ListOfCoupleOfShapes {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_ListOfCoupleOfShapes();
+
+
Standard_EXPORT void Assign(const GEOMAlgo_ListOfCoupleOfShapes& Other) ;
void operator=(const GEOMAlgo_ListOfCoupleOfShapes& Other)
{
Assign(Other);
}
+
+
Standard_EXPORT Standard_Integer Extent() const;
+
+
Standard_EXPORT void Clear() ;
~GEOMAlgo_ListOfCoupleOfShapes()
{
Clear();
}
+
Standard_Boolean IsEmpty() const;
+
+
Standard_EXPORT void Prepend(const GEOMAlgo_CoupleOfShapes& I) ;
+
+
Standard_EXPORT void Prepend(const GEOMAlgo_CoupleOfShapes& I,GEOMAlgo_ListIteratorOfListOfCoupleOfShapes& theIt) ;
+
+
Standard_EXPORT void Prepend(GEOMAlgo_ListOfCoupleOfShapes& Other) ;
+
+
Standard_EXPORT void Append(const GEOMAlgo_CoupleOfShapes& I) ;
+
+
Standard_EXPORT void Append(const GEOMAlgo_CoupleOfShapes& I,GEOMAlgo_ListIteratorOfListOfCoupleOfShapes& theIt) ;
+
+
Standard_EXPORT void Append(GEOMAlgo_ListOfCoupleOfShapes& Other) ;
+
+
Standard_EXPORT GEOMAlgo_CoupleOfShapes& First() const;
+
+
Standard_EXPORT GEOMAlgo_CoupleOfShapes& Last() const;
+
+
Standard_EXPORT void RemoveFirst() ;
+
+
Standard_EXPORT void Remove(GEOMAlgo_ListIteratorOfListOfCoupleOfShapes& It) ;
+
+
Standard_EXPORT void InsertBefore(const GEOMAlgo_CoupleOfShapes& I,GEOMAlgo_ListIteratorOfListOfCoupleOfShapes& It) ;
+
+
Standard_EXPORT void InsertBefore(GEOMAlgo_ListOfCoupleOfShapes& Other,GEOMAlgo_ListIteratorOfListOfCoupleOfShapes& It) ;
+
+
Standard_EXPORT void InsertAfter(const GEOMAlgo_CoupleOfShapes& I,GEOMAlgo_ListIteratorOfListOfCoupleOfShapes& It) ;
+
+
Standard_EXPORT void InsertAfter(GEOMAlgo_ListOfCoupleOfShapes& Other,GEOMAlgo_ListIteratorOfListOfCoupleOfShapes& It) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT GEOMAlgo_ListOfCoupleOfShapes(const GEOMAlgo_ListOfCoupleOfShapes& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_ListOfPnt {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_ListOfPnt();
+
+
Standard_EXPORT void Assign(const GEOMAlgo_ListOfPnt& Other) ;
void operator=(const GEOMAlgo_ListOfPnt& Other)
{
Assign(Other);
}
+
+
Standard_EXPORT Standard_Integer Extent() const;
+
+
Standard_EXPORT void Clear() ;
~GEOMAlgo_ListOfPnt()
{
Clear();
}
+
Standard_Boolean IsEmpty() const;
+
+
Standard_EXPORT void Prepend(const gp_Pnt& I) ;
+
+
Standard_EXPORT void Prepend(const gp_Pnt& I,GEOMAlgo_ListIteratorOfListOfPnt& theIt) ;
+
+
Standard_EXPORT void Prepend(GEOMAlgo_ListOfPnt& Other) ;
+
+
Standard_EXPORT void Append(const gp_Pnt& I) ;
+
+
Standard_EXPORT void Append(const gp_Pnt& I,GEOMAlgo_ListIteratorOfListOfPnt& theIt) ;
+
+
Standard_EXPORT void Append(GEOMAlgo_ListOfPnt& Other) ;
+
+
Standard_EXPORT gp_Pnt& First() const;
+
+
Standard_EXPORT gp_Pnt& Last() const;
+
+
Standard_EXPORT void RemoveFirst() ;
+
+
Standard_EXPORT void Remove(GEOMAlgo_ListIteratorOfListOfPnt& It) ;
+
+
Standard_EXPORT void InsertBefore(const gp_Pnt& I,GEOMAlgo_ListIteratorOfListOfPnt& It) ;
+
+
Standard_EXPORT void InsertBefore(GEOMAlgo_ListOfPnt& Other,GEOMAlgo_ListIteratorOfListOfPnt& It) ;
+
+
Standard_EXPORT void InsertAfter(const gp_Pnt& I,GEOMAlgo_ListIteratorOfListOfPnt& It) ;
+
+
Standard_EXPORT void InsertAfter(GEOMAlgo_ListOfPnt& Other,GEOMAlgo_ListIteratorOfListOfPnt& It) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT GEOMAlgo_ListOfPnt(const GEOMAlgo_ListOfPnt& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_PWireEdgeSet_HeaderFile
+#define _GEOMAlgo_PWireEdgeSet_HeaderFile
+
+class GEOMAlgo_WireEdgeSet;
+
+typedef GEOMAlgo_WireEdgeSet* GEOMAlgo_PWireEdgeSet;
+
+#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_PassKey.cdl
-- Created:
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_PassKey {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_PassKey();
+
+
Standard_EXPORT GEOMAlgo_PassKey& Assign(const GEOMAlgo_PassKey& Other) ;
GEOMAlgo_PassKey& operator =(const GEOMAlgo_PassKey& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void SetIds(const Standard_Integer aI1) ;
+
+
Standard_EXPORT void SetIds(const Standard_Integer aI1,const Standard_Integer aI2) ;
+
+
Standard_EXPORT void SetIds(const Standard_Integer aI1,const Standard_Integer aI2,const Standard_Integer aI3) ;
+
+
Standard_EXPORT void SetIds(const Standard_Integer aI1,const Standard_Integer aI2,const Standard_Integer aI3,const Standard_Integer aI4) ;
+
+
Standard_EXPORT void SetIds(const TColStd_ListOfInteger& aLS) ;
+
+
Standard_EXPORT Standard_Integer NbMax() const;
+
+
Standard_EXPORT void Clear() ;
+
+
Standard_EXPORT void Compute() ;
+
+
Standard_EXPORT Standard_Boolean IsEqual(const GEOMAlgo_PassKey& aOther) const;
+
+
Standard_EXPORT Standard_Address Key() const;
+
+
Standard_EXPORT Standard_Integer HashCode(const Standard_Integer Upper) const;
+
+
Standard_EXPORT Standard_Integer Id(const Standard_Integer aIndex) const;
+
+
Standard_EXPORT void Dump() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TColStd_ListOfInteger_HeaderFile
#include <TColStd_ListOfInteger.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_PassKeyMapHasher.cdl
-- Created:
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_PassKeyMapHasher {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT static Standard_Integer HashCode(const GEOMAlgo_PassKey& aPKey,const Standard_Integer Upper) ;
+
+
Standard_EXPORT static Standard_Boolean IsEqual(const GEOMAlgo_PassKey& aPKey1,const GEOMAlgo_PassKey& aPKey2) ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _GEOMAlgo_PassKey_HeaderFile
#include <GEOMAlgo_PassKey.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_PassKeyShape.cdl
-- Created:
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_PassKeyShape : public GEOMAlgo_PassKey {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_PassKeyShape();
+
+
Standard_EXPORT void SetIds(const TopoDS_Shape& aS) ;
+
+
Standard_EXPORT void SetIds(const TopoDS_Shape& aS1,const TopoDS_Shape& aS2) ;
+
+
Standard_EXPORT void SetIds(const TopoDS_Shape& aS1,const TopoDS_Shape& aS2,const TopoDS_Shape& aS3) ;
+
+
Standard_EXPORT void SetIds(const TopoDS_Shape& aS1,const TopoDS_Shape& aS2,const TopoDS_Shape& aS3,const TopoDS_Shape& aS4) ;
+
+
Standard_EXPORT void SetIds(const TopTools_ListOfShape& aLS) ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopoDS_Shape_HeaderFile
#include <TopoDS_Shape.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_ShapeAlgo.cdl
-- Created: Tue Dec 7 12:05:19 2004
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_ShapeAlgo : public GEOMAlgo_Algo {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT void SetShape(const TopoDS_Shape& aS) ;
+
+
Standard_EXPORT void SetTolerance(const Standard_Real aT) ;
+
+
Standard_EXPORT const TopoDS_Shape& Shape() const;
+
+
Standard_EXPORT Standard_Real Tolerance() const;
+
+
Standard_EXPORT const TopoDS_Shape& Result() const;
// Methods PROTECTED
//
+
+
Standard_EXPORT GEOMAlgo_ShapeAlgo();
Standard_EXPORT virtual ~GEOMAlgo_ShapeAlgo();
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopoDS_Shape_HeaderFile
#include <TopoDS_Shape.hxx>
#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_ShapeSet.cdl
+-- Created:
+-- Author: Peter KURNEV
+
+class ShapeSet from GEOMAlgo
+
+ ---Purpose: Implementation some formal
+ -- opereations with Set of shapes
+
+uses
+ Shape from TopoDS,
+ MapOfOrientedShape from TopTools,
+ ListOfShape from TopTools,
+ ShapeEnum from TopAbs
+
+--raises
+
+is
+ Create
+ ---Purpose: Empty constructor
+ returns ShapeSet from GEOMAlgo;
+
+ Add(me:out;
+ theLS:ListOfShape from TopTools);
+ ---Purpose: Adds shapes from the list theLS to the Set
+
+ Add(me:out;
+ theShape:Shape from TopoDS);
+ ---Purpose: Adds shape theShape to the Set
+
+ Add(me:out;
+ theShape:Shape from TopoDS;
+ theType :ShapeEnum from TopAbs);
+ ---Purpose: Adds sub-shapes of shape theShape,
+ -- that have type theType to the Set
+
+ Subtract(me:out;
+ theSet:ShapeSet from GEOMAlgo);
+ ---Purpose: Removes shapes of theSet from the Set
+
+ Clear(me:out);
+ ---Purpose: Clears internal fields
+
+ Contains(me;
+ theSet:ShapeSet from GEOMAlgo)
+ ---Purpose: Returns True if the Set contains
+ -- all shapes of theSet
+ returns Boolean from Standard;
+
+ GetSet(me)
+ ---Purpose: Returns the Set
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+fields
+ myMap : MapOfOrientedShape from TopTools is protected;
+ myList : ListOfShape from TopTools is protected;
+
+end ShapeSet;
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_ShapeSet.cxx
+// Created:
+// Author: Peter KURNEV
+
+
+
+#include <GEOMAlgo_ShapeSet.ixx>
+
+#include <TopExp_Explorer.hxx>
+
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_MapIteratorOfMapOfOrientedShape.hxx>
+
+//=======================================================================
+//function :
+//purpose :
+//=======================================================================
+ GEOMAlgo_ShapeSet::GEOMAlgo_ShapeSet()
+{
+}
+//=======================================================================
+//function : Clear
+//purpose :
+//=======================================================================
+ void GEOMAlgo_ShapeSet::Clear()
+{
+ myMap.Clear();
+ myList.Clear();
+}
+//=======================================================================
+//function : Add
+//purpose :
+//=======================================================================
+ void GEOMAlgo_ShapeSet::Add(const TopoDS_Shape& theShape)
+{
+ myMap.Add(theShape);
+}
+//=======================================================================
+//function : Add
+//purpose :
+//=======================================================================
+ void GEOMAlgo_ShapeSet::Add(const TopoDS_Shape& theShape,
+ const TopAbs_ShapeEnum theType)
+{
+ TopExp_Explorer aExp;
+ //
+ aExp.Init(theShape, theType);
+ for (; aExp.More(); aExp.Next()) {
+ const TopoDS_Shape& aS=aExp.Current();
+ myMap.Add(aS);
+ }
+}
+//=======================================================================
+//function : Add
+//purpose :
+//=======================================================================
+ void GEOMAlgo_ShapeSet::Add(const TopTools_ListOfShape& theLS)
+{
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ aIt.Initialize(theLS);
+ for (; aIt.More(); aIt.Next()) {
+ myMap.Add(aIt.Value());
+ }
+}
+//=======================================================================
+//function :GetSet
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_ShapeSet::GetSet()const
+{
+ TopTools_ListOfShape *pL;
+ TopTools_MapIteratorOfMapOfOrientedShape aIt;
+ //
+ pL=(TopTools_ListOfShape *)&myList;
+ pL->Clear();
+ aIt.Initialize(myMap);
+ for (; aIt.More(); aIt.Next()) {
+ pL->Append(aIt.Key());
+ }
+ return myList;
+}
+//=======================================================================
+//function : Contains
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_ShapeSet::Contains(const GEOMAlgo_ShapeSet& theOther)const
+{
+ Standard_Boolean bRet;
+ TopAbs_Orientation aOr;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ bRet=Standard_True;
+ const TopTools_ListOfShape& aLS=theOther.GetSet();
+ aIt.Initialize(aLS);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ aOr=aF.Orientation();
+ if (aOr==TopAbs_FORWARD||aOr==TopAbs_REVERSED) {
+ bRet=myMap.Contains(aF);
+ if (!bRet) {
+ break;
+ }
+ }
+ }
+ return bRet;
+}
+//=======================================================================
+//function : Subtract
+//purpose :
+//=======================================================================
+ void GEOMAlgo_ShapeSet::Subtract(const GEOMAlgo_ShapeSet& theOther)
+{
+ TopTools_MapIteratorOfMapOfOrientedShape aIt;
+ //
+ aIt.Initialize(theOther.myMap);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Key();
+ myMap.Remove(aS);
+ }
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_ShapeSet_HeaderFile
+#define _GEOMAlgo_ShapeSet_HeaderFile
+
+#ifndef _TopTools_MapOfOrientedShape_HeaderFile
+#include <TopTools_MapOfOrientedShape.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TopAbs_ShapeEnum_HeaderFile
+#include <TopAbs_ShapeEnum.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class TopTools_ListOfShape;
+class TopoDS_Shape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+//! Implementation some formal <br>
+//! opereations with Set of shapes <br>
+class GEOMAlgo_ShapeSet {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+//! Empty constructor <br>
+Standard_EXPORT GEOMAlgo_ShapeSet();
+
+//! Adds shapes from the list theLS to the Set <br>
+Standard_EXPORT void Add(const TopTools_ListOfShape& theLS) ;
+
+//! Adds shape theShape to the Set <br>
+Standard_EXPORT void Add(const TopoDS_Shape& theShape) ;
+
+//! Adds sub-shapes of shape theShape, <br>
+//! that have type theType to the Set <br>
+Standard_EXPORT void Add(const TopoDS_Shape& theShape,const TopAbs_ShapeEnum theType) ;
+
+//! Removes shapes of theSet from the Set <br>
+Standard_EXPORT void Subtract(const GEOMAlgo_ShapeSet& theSet) ;
+
+//! Clears internal fields <br>
+Standard_EXPORT void Clear() ;
+
+//! Returns True if the Set contains <br>
+//! all shapes of theSet <br>
+Standard_EXPORT Standard_Boolean Contains(const GEOMAlgo_ShapeSet& theSet) const;
+
+//! Returns the Set <br>
+Standard_EXPORT const TopTools_ListOfShape& GetSet() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+TopTools_MapOfOrientedShape myMap;
+TopTools_ListOfShape myList;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_ShapeSet.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _GEOMAlgo_ShapeSet_HeaderFile
+#include <GEOMAlgo_ShapeSet.hxx>
+#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_ShapeSolid.cdl
-- Created: Thu Jan 13 12:44:07 2005
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_ShapeSolid : public GEOMAlgo_Algo {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT void SetFiller(const BOPTools_DSFiller& aDSF) ;
Standard_EXPORT virtual ~GEOMAlgo_ShapeSolid();
+
+
Standard_EXPORT const TopTools_ListOfShape& Shapes(const TopAbs_State aState) const;
// Methods PROTECTED
//
+
+
Standard_EXPORT GEOMAlgo_ShapeSolid();
+
+
Standard_EXPORT virtual void BuildResult() = 0;
+
+
Standard_EXPORT virtual void Prepare() = 0;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _BOPTools_DSFiller_HeaderFile
#include <BOPTools_DSFiller.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_ShellSolid.cdl
-- Created: Wed Jan 12 12:45:20 2005
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_ShellSolid : public GEOMAlgo_ShapeSolid {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_ShellSolid();
Standard_EXPORT virtual ~GEOMAlgo_ShellSolid();
+
+
Standard_EXPORT virtual void Perform() ;
// Methods PROTECTED
//
+
+
Standard_EXPORT virtual void Prepare() ;
+
+
Standard_EXPORT virtual void BuildResult() ;
+
+
Standard_EXPORT void DetectSDFaces() ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _GEOMAlgo_ShellSolid_HeaderFile
#include <GEOMAlgo_ShellSolid.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_SolidSolid.cdl
-- Created: Wed Jan 26 12:05:14 2005
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_SolidSolid : public GEOMAlgo_ShellSolid {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_SolidSolid();
Standard_EXPORT virtual ~GEOMAlgo_SolidSolid();
+
+
Standard_EXPORT virtual void Perform() ;
+
+
Standard_EXPORT void SetShape2(const TopoDS_Shape& aS) ;
+
+
Standard_EXPORT const TopoDS_Shape& Shape2() const;
// Methods PROTECTED
//
+
+
Standard_EXPORT virtual void BuildResult() ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopoDS_Shape_HeaderFile
#include <TopoDS_Shape.hxx>
#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_Splitter.cdl
+-- Created:
+-- Author: Peter KURNEV
+-- <pkv@irinox>
+-- Copyright:
+
+class Splitter from GEOMAlgo
+ inherits Builder from GEOMAlgo
+
+ ---Purpose: Implementation of Gluing Operation Algorithm (GA)
+
+uses
+
+ ShapeEnum from TopAbs,
+ Shape from TopoDS,
+ ListOfShape from TopTools,
+ MapOfShape from TopTools
+
+--raises
+
+is
+
+ Create
+ ---Purpose: Empty constructor
+ returns Splitter from GEOMAlgo;
+ ---C++: alias "Standard_EXPORT virtual ~GEOMAlgo_Splitter();"
+
+ Clear(me:out)
+ ---Purpose: Clears internal fields and arguments
+ is redefined;
+
+ AddTool (me:out;
+ theShape: Shape from TopoDS)
+ ---Purpose: Adds Tool argument theShape of the operation
+ is virtual;
+
+ Tools(me)
+ ---Purpose: Returns the arguments of the operation
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+ SetLimit(me:out;
+ aLimit:ShapeEnum from TopAbs);
+
+ Limit(me)
+ returns ShapeEnum from TopAbs;
+ --
+ -- Protected methods
+ --
+ BuildResult(me:out;
+ theType: ShapeEnum from TopAbs)
+ ---Purpose: Build the resulting shapes of type theType
+ is redefined protected;
+
+ PostTreat(me:out)
+ ---Purpose: Provides post-tratment actions
+ is redefined protected;
+
+ -- =====================================================
+ --
+ -- Debug methods
+ --
+ AddToolCompound (me:out;
+ theShape: Shape from TopoDS);
+ ---Purpose: Adds Tool arguments of the operation as
+ -- shapes of upper level of container shape theShape
+ -- =====================================================
+
+fields
+ myTools : ListOfShape from TopTools is protected;
+ myMapTools : MapOfShape from TopTools is protected;
+ myLimit : ShapeEnum from TopAbs is protected;
+end Splitter;
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_Splitter.cxx
+// Created:
+// Author: Peter KURNEV
+// <pkv@irinox>
+
+#include <GEOMAlgo_Splitter.ixx>
+
+#include <TopAbs_ShapeEnum.hxx>
+
+#include <TopoDS_Shape.hxx>
+#include <TopoDS_Compound.hxx>
+#include <TopoDS_Iterator.hxx>
+
+#include <TopExp.hxx>
+
+#include <BRep_Builder.hxx>
+#include <BRepLib.hxx>
+
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+
+#include <BOP_CorrectTolerances.hxx>
+
+#include <NMTTools_DSFiller.hxx>
+
+//=======================================================================
+//function :
+//purpose :
+//=======================================================================
+ GEOMAlgo_Splitter::GEOMAlgo_Splitter()
+:
+ GEOMAlgo_Builder()
+{
+ myLimit=TopAbs_SHAPE;
+}
+//=======================================================================
+//function : ~
+//purpose :
+//=======================================================================
+ GEOMAlgo_Splitter::~GEOMAlgo_Splitter()
+{
+}
+//=======================================================================
+//function : AddToolCompound
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Splitter::AddToolCompound(const TopoDS_Shape& theShape)
+{
+ TopoDS_Iterator aIt;
+ //
+ aIt.Initialize(theShape);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ AddTool(aS);
+ }
+}
+//=======================================================================
+//function : AddTool
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Splitter::AddTool(const TopoDS_Shape& theShape)
+{
+ if (myMapTools.Add(theShape)) {
+ myTools.Append(theShape);
+ //
+ AddShape(theShape);
+ }
+}
+//=======================================================================
+//function : Tools
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_Splitter::Tools()const
+{
+ return myTools;
+}
+//=======================================================================
+//function : SetLimit
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Splitter::SetLimit(const TopAbs_ShapeEnum aLimit)
+{
+ myLimit=aLimit;
+}
+//=======================================================================
+//function : Limit
+//purpose :
+//=======================================================================
+ TopAbs_ShapeEnum GEOMAlgo_Splitter::Limit()const
+{
+ return myLimit;
+}
+//=======================================================================
+//function : Clear
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Splitter::Clear()
+{
+ myTools.Clear();
+ myMapTools.Clear();
+ myLimit=TopAbs_SHAPE;
+ GEOMAlgo_Builder::Clear();
+}
+//=======================================================================
+//function : BuildResult
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Splitter::BuildResult(const TopAbs_ShapeEnum theType)
+{
+ myErrorStatus=0;
+ //
+ TopAbs_ShapeEnum aType;
+ BRep_Builder aBB;
+ TopTools_MapOfShape aM;
+ TopTools_ListIteratorOfListOfShape aIt, aItIm;
+ //
+ aIt.Initialize(myShapes);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aS=aIt.Value();
+ aType=aS.ShapeType();
+ if (aType==theType && !myMapTools.Contains(aS)) {
+ if (myImages.HasImage(aS)) {
+ const TopTools_ListOfShape& aLSIm=myImages.Image(aS);
+ aItIm.Initialize(aLSIm);
+ for (; aItIm.More(); aItIm.Next()) {
+ const TopoDS_Shape& aSIm=aItIm.Value();
+ if (aM.Add(aSIm)) {
+ aBB.Add(myShape, aSIm);
+ }
+ }
+ }
+ else {
+ if (aM.Add(aS)) {
+ aBB.Add(myShape, aS);
+ }
+ }
+ }
+ }
+}
+//=======================================================================
+//function : PostTreat
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Splitter::PostTreat()
+{
+ if (myLimit!=TopAbs_SHAPE) {
+ Standard_Integer i, aNbS;
+ BRep_Builder aBB;
+ TopoDS_Compound aC;
+ TopTools_IndexedMapOfShape aM;
+ //
+ aBB.MakeCompound(aC);
+ //
+ TopExp::MapShapes(myShape, myLimit, aM);
+ aNbS=aM.Extent();
+ for (i=1; i<=aNbS; ++i) {
+ const TopoDS_Shape& aS=aM(i);
+ aBB.Add(aC, aS);
+ }
+ myShape=aC;
+ }
+ //
+ GEOMAlgo_Builder::PostTreat();
+ //
+}
+//
+// myErrorStatus
+//
+// 0 - Ok
+// 1 - The object is just initialized
+// 2 - DSFiller is failed
+// 10 - No shapes to process
+// 30 - SolidBuilder failed
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_Splitter_HeaderFile
+#define _GEOMAlgo_Splitter_HeaderFile
+
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TopTools_MapOfShape_HeaderFile
+#include <TopTools_MapOfShape.hxx>
+#endif
+#ifndef _TopAbs_ShapeEnum_HeaderFile
+#include <TopAbs_ShapeEnum.hxx>
+#endif
+#ifndef _GEOMAlgo_Builder_HeaderFile
+#include <GEOMAlgo_Builder.hxx>
+#endif
+class TopoDS_Shape;
+class TopTools_ListOfShape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+//! Implementation of Gluing Operation Algorithm (GA) <br>
+class GEOMAlgo_Splitter : public GEOMAlgo_Builder {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+//! Empty constructor <br>
+Standard_EXPORT GEOMAlgo_Splitter();
+Standard_EXPORT virtual ~GEOMAlgo_Splitter();
+
+//! Clears internal fields and arguments <br>
+Standard_EXPORT virtual void Clear() ;
+
+//! Adds Tool argument theShape of the operation <br>
+Standard_EXPORT virtual void AddTool(const TopoDS_Shape& theShape) ;
+
+//! Returns the arguments of the operation <br>
+Standard_EXPORT const TopTools_ListOfShape& Tools() const;
+
+
+Standard_EXPORT void SetLimit(const TopAbs_ShapeEnum aLimit) ;
+
+
+Standard_EXPORT TopAbs_ShapeEnum Limit() const;
+
+//! Adds Tool arguments of the operation as <br>
+//! shapes of upper level of container shape theShape <br>
+//! ===================================================== <br>
+Standard_EXPORT void AddToolCompound(const TopoDS_Shape& theShape) ;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+//! Build the resulting shapes of type theType <br>
+Standard_EXPORT virtual void BuildResult(const TopAbs_ShapeEnum theType) ;
+
+//! Provides post-tratment actions <br>
+Standard_EXPORT virtual void PostTreat() ;
+
+
+ // Fields PROTECTED
+ //
+TopTools_ListOfShape myTools;
+TopTools_MapOfShape myMapTools;
+TopAbs_ShapeEnum myLimit;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_Splitter.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_Splitter_HeaderFile
+#include <GEOMAlgo_Splitter.hxx>
+#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _GEOMAlgo_State_HeaderFile
#define _GEOMAlgo_State_HeaderFile
+
enum GEOMAlgo_State {
GEOMAlgo_ST_UNKNOWN,
GEOMAlgo_ST_IN,
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_StateCollector.cdl
-- Created: Thu Mar 10 09:39:25 2005
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_StateCollector {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_StateCollector();
+
+
Standard_EXPORT Standard_Boolean AppendState(const TopAbs_State aSt) ;
+
+
Standard_EXPORT TopAbs_State State() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _GEOMAlgo_StateCollector_HeaderFile
#include <GEOMAlgo_StateCollector.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_SurfaceTools.cdl
-- Created: Thu Jan 27 11:03:49 2005
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_SurfaceTools {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT static Standard_Boolean IsAnalytic(const Handle(Geom_Surface)& aS) ;
+
+
Standard_EXPORT static Standard_Boolean IsCoaxial(const gp_Pnt& aP1,const gp_Pnt& aP2,const gp_Cylinder& aCyl,const Standard_Real aTol) ;
+
+
Standard_EXPORT static Standard_Boolean IsConformState(const TopAbs_State aST1,const GEOMAlgo_State aST2) ;
+
+
Standard_EXPORT static Standard_Integer GetState(const gp_Pnt& aP,const GeomAdaptor_Surface& aS,const Standard_Real aTol,TopAbs_State& aSt) ;
+
+
Standard_EXPORT static Standard_Integer GetState(const gp_Pnt& aP,const Handle(Geom_Surface)& aS,const Standard_Real aTol,TopAbs_State& aSt) ;
+
+
Standard_EXPORT static Standard_Real Distance(const gp_Pnt& aP,const gp_Pln& aPln) ;
+
+
Standard_EXPORT static Standard_Real Distance(const gp_Pnt& aP,const gp_Cylinder& aCyl) ;
+
+
Standard_EXPORT static Standard_Real Distance(const gp_Pnt& aP,const gp_Sphere& aSph) ;
+
+
Standard_EXPORT static TopAbs_State ReverseState(const TopAbs_State aSt) ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _Geom_Surface_HeaderFile
#include <Geom_Surface.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_Tools.cdl
-- Created: Mon Dec 6 11:26:02 2004
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_Tools {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT static Standard_Boolean IsCompositeShape(const TopoDS_Shape& aS) ;
+
+
Standard_EXPORT static Standard_Integer RefineSDShapes(GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape& aMSD,const Standard_Real aTol,IntTools_Context& aCtx) ;
+
+
Standard_EXPORT static Standard_Integer FindSDShapes(const TopTools_ListOfShape& aLE,const Standard_Real aTol,TopTools_IndexedDataMapOfShapeListOfShape& aMEE,IntTools_Context& aCtx) ;
+
+
Standard_EXPORT static Standard_Integer FindSDShapes(const TopoDS_Shape& aE1,const TopTools_ListOfShape& aLE,const Standard_Real aTol,TopTools_ListOfShape& aLESD,IntTools_Context& aCtx) ;
+
+
Standard_EXPORT static Standard_Boolean ProjectPointOnShape(const gp_Pnt& aP1,const TopoDS_Shape& aS,gp_Pnt& aP2,IntTools_Context& aCtx) ;
+
+
Standard_EXPORT static void PointOnShape(const TopoDS_Shape& aS,gp_Pnt& aP3D) ;
+
+
Standard_EXPORT static void PointOnEdge(const TopoDS_Edge& aE,gp_Pnt& aP3D) ;
+
+
Standard_EXPORT static void PointOnEdge(const TopoDS_Edge& aE,const Standard_Real aT,gp_Pnt& aP3D) ;
+
+
Standard_EXPORT static void PointOnFace(const TopoDS_Face& aF,gp_Pnt& aP3D) ;
+
+
Standard_EXPORT static void PointOnFace(const TopoDS_Face& aF,const Standard_Real aU,const Standard_Real aV,gp_Pnt& aP3D) ;
+
+
Standard_EXPORT static void RefinePCurveForEdgeOnFace(const TopoDS_Edge& aE,const TopoDS_Face& aF,const Standard_Real aU1,const Standard_Real aU2) ;
+
+
Standard_EXPORT static Standard_Boolean IsUPeriodic(const Handle(Geom_Surface)& aS) ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopoDS_Shape_HeaderFile
#include <TopoDS_Shape.hxx>
#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_Tools3D.cdl
+-- Created:
+-- Author: Peter KURNEV
+
+class Tools3D from GEOMAlgo
+
+ ---Purpose: Auxiliary tools for Algorithms
+
+uses
+ State from TopAbs,
+ ShapeEnum from TopAbs,
+ Pnt from gp,
+ Shape from TopoDS,
+ Vertex from TopoDS,
+ Edge from TopoDS,
+ Face from TopoDS,
+ Solid from TopoDS,
+
+ ListOfShape from TopTools,
+ IndexedMapOfShape from TopTools,
+ IndexedDataMapOfShapeListOfShape from TopTools,
+ Context from IntTools,
+ ListOfCoupleOfShape from NMTTools
+
+--raises
+
+is
+ IsSplitToReverse(myclass;
+ theSplit : Shape from TopoDS;
+ theShape : Shape from TopoDS;
+ theContext:out Context from IntTools)
+ ---Purpose: Returns True if the shape theSplit has opposite
+ -- direction than theShape
+ -- theContext - cashed geometrical tools
+ returns Boolean from Standard;
+
+ IsSplitToReverse(myclass;
+ theSplit : Face from TopoDS;
+ theShape : Face from TopoDS;
+ theContext:out Context from IntTools)
+ ---Purpose: Returns True if normal direction of the face
+ -- theShape is not the same as for the face
+ -- theSplit
+ -- theContext - cashed geometrical tools
+ returns Boolean from Standard;
+
+ IsSplitToReverse(myclass;
+ theEdge : Edge from TopoDS;
+ theSplit : Edge from TopoDS;
+ theContext:out Context from IntTools)
+ ---Purpose: Returns True if tangent direction of the edge
+ -- theEdge is not the same as for the edge
+ -- theSplit
+ -- theContext - cashed geometrical tools
+ returns Boolean from Standard;
+
+ Sense (myclass;
+ theF1: Face from TopoDS;
+ theF2: Face from TopoDS)
+ ---Purpose: For the couple of faces theF1, theF2
+ -- computes sense value
+ -- Returns 0 if the faces are not sensible
+ -- Returns 1 if the faces have same sense
+ -- Returns 2 if the faces have opposite sense
+ returns Integer from Standard;
+
+ CopyFace(myclass;
+ theF1: Face from TopoDS;
+ theF2:out Face from TopoDS);
+ ---Purpose: Makes new face theF2 from surface and wires
+ -- of the face theF1
+
+ MakeContainer(myclass;
+ theType:ShapeEnum from TopAbs;
+ theShape:out Shape from TopoDS);
+ ---Purpose: Makes empty shape theShape of the type theType
+
+
+ MakeConnexityBlock(myclass;
+ theLS :ListOfShape from TopTools;
+ theMapAvoid:IndexedMapOfShape from TopTools;
+ theLSCB :out ListOfShape from TopTools);
+ ---Purpose: For the list of faces theLS build block
+ -- theLSCB in terms of connexity by edges
+ -- theMapAvoid - set of edges to avoid for
+ -- the treatment
+
+ ComputeStateByOnePoint(myclass;
+ theShape :Shape from TopoDS;
+ theSolid :Solid from TopoDS;
+ theTol :Real from Standard;
+ theContext:out Context from IntTools)
+ ---Purpose: Computes the 3-D state of the shape theShape
+ -- toward solid theSolid.
+ -- theTol - value of precision of computation
+ -- theContext- cahed geometrical tools
+ -- Returns 3-D state.
+ returns State from TopAbs;
+
+ ComputeState(myclass;
+ thePoint :Pnt from gp;
+ theSolid :Solid from TopoDS;
+ theTol :Real from Standard;
+ theContext:out Context from IntTools)
+ ---Purpose: Computes the 3-D state of the point thePoint
+ -- toward solid theSolid.
+ -- theTol - value of precision of computation
+ -- theContext- cahed geometrical tools
+ -- Returns 3-D state.
+ returns State from TopAbs;
+
+ ComputeState(myclass;
+ theVertex:Vertex from TopoDS;
+ theSolid :Solid from TopoDS;
+ theTol :Real from Standard;
+ theContext:out Context from IntTools)
+ ---Purpose: Computes the 3-D state of the vertex theVertex
+ -- toward solid theSolid.
+ -- theTol - value of precision of computation
+ -- theContext- cahed geometrical tools
+ -- Returns 3-D state.
+ returns State from TopAbs;
+
+ ComputeState(myclass;
+ theEdge :Edge from TopoDS;
+ theSolid :Solid from TopoDS;
+ theTol :Real from Standard;
+ theContext:out Context from IntTools)
+ ---Purpose: Computes the 3-D state of the edge theEdge
+ -- toward solid theSolid.
+ -- theTol - value of precision of computation
+ -- theContext- cahed geometrical tools
+ -- Returns 3-D state.
+ returns State from TopAbs;
+
+ ComputeState(myclass;
+ theFace :Face from TopoDS;
+ theSolid :Solid from TopoDS;
+ theTol :Real from Standard;
+ theBounds:IndexedMapOfShape from TopTools;
+ theContext:out Context from IntTools)
+ ---Purpose: Computes the 3-D state of the face theFace
+ -- toward solid theSolid.
+ -- theTol - value of precision of computation
+ -- theBounds - set of edges of theFace to avoid
+ -- theContext- cahed geometrical tools
+ -- Returns 3-D state.
+ returns State from TopAbs;
+
+ IsInternalFace(myclass;
+ theFace :Face from TopoDS;
+ theEdge :Edge from TopoDS;
+ theFace1 :Face from TopoDS;
+ theFace2 :Face from TopoDS)
+ ---Purpose: Returns True if the face theFace is inside of the
+ -- couple of faces theFace1, theFace2.
+ -- The faces theFace, theFace1, theFace2 must
+ -- share the edge theEdge
+ returns Boolean from Standard;
+
+ IsInternalFace(myclass;
+ theFace :Face from TopoDS;
+ theEdge :Edge from TopoDS;
+ theLF :ListOfShape from TopTools)
+ ---Purpose: Returns True if the face theFace is inside of the
+ -- appropriate couple of faces (from the set theLF) .
+ -- The faces of the set theLF and theFace must
+ -- share the edge theEdge
+ returns Boolean from Standard;
+
+ IsInternalFace(myclass;
+ theFace :Face from TopoDS;
+ theSolid :Solid from TopoDS;
+ theMEF :IndexedDataMapOfShapeListOfShape from TopTools;
+ theTol :Real from Standard;
+ theContext:out Context from IntTools)
+ ---Purpose: Returns True if the face theFace is inside the
+ -- solid theSolid.
+ -- theMEF - Map Edge/Faces for theSolid
+ -- theTol - value of precision of computation
+ -- theContext- cahed geometrical tools
+ returns Boolean from Standard;
+
+
+ GetFaceOff(myclass;
+ theEdge :Edge from TopoDS;
+ theFace :Face from TopoDS;
+ theLCEF :ListOfCoupleOfShape from NMTTools;
+ theFaceOff :out Face from TopoDS);
+ ---Purpose: For the face theFace and its edge theEdge
+ -- finds the face suitable to produce shell.
+ -- theLCEF - set of faces to search. All faces
+ -- from theLCEF must share edge theEdge
+
+ GetEdgeOnFace (myclass;
+ theEdge :Edge from TopoDS;
+ theFace :Face from TopoDS;
+ theEdgeOnF :out Edge from TopoDS)
+ ---Purpose: For the face theFace gets the edge theEdgeOnF
+ -- that is the same as theEdge
+ -- Returns True if such edge exists
+ -- Returns False if there is no such edge
+ returns Boolean from Standard;
+
+ GetEdgeOff (myclass;
+ theEdge :Edge from TopoDS;
+ theFace :Face from TopoDS;
+ theEdgeOff :out Edge from TopoDS)
+ ---Purpose: Returns True if the face theFace contains
+ -- the edge theEdge but with opposite orientation.
+ -- If the method returns True theEdgeOff is the
+ -- edge founded
+ returns Boolean from Standard;
+
+--fields
+end Tools3D;
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_Tools3D.cxx
+// Created:
+// Author: Peter KURNEV
+
+#include <GEOMAlgo_Tools3D.ixx>
+
+#include <Precision.hxx>
+
+#include <gp_Vec.hxx>
+#include <gp_Pnt.hxx>
+#include <gp_Dir.hxx>
+#include <gp_Pnt2d.hxx>
+#include <gp_Pln.hxx>
+#include <gp_XYZ.hxx>
+
+#include <Geom_Curve.hxx>
+#include <Geom_Surface.hxx>
+#include <Geom2d_Curve.hxx>
+#include <GeomAPI_ProjectPointOnSurf.hxx>
+
+#include <TopAbs_ShapeEnum.hxx>
+#include <TopAbs_State.hxx>
+
+#include <TopLoc_Location.hxx>
+
+#include <TopoDS.hxx>
+#include <TopoDS_Edge.hxx>
+#include <TopoDS_CompSolid.hxx>
+#include <TopoDS_Wire.hxx>
+#include <TopoDS_Compound.hxx>
+#include <TopoDS_Face.hxx>
+#include <TopoDS_Vertex.hxx>
+#include <TopoDS_Solid.hxx>
+#include <TopoDS_Shell.hxx>
+#include <TopoDS_Iterator.hxx>
+
+#include <TopExp.hxx>
+#include <TopExp_Explorer.hxx>
+
+#include <BRep_Builder.hxx>
+#include <BRep_Tool.hxx>
+//
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_MapOfShape.hxx>
+
+#include <BRepClass3d_SolidClassifier.hxx>
+
+#include <IntTools_Context.hxx>
+#include <IntTools_Tools.hxx>
+
+#include <BOPTools_Tools3D.hxx>
+#include <BOPTools_Tools2D.hxx>
+#include <BOPTools_Tools.hxx>
+
+#include <NMTTools_ListOfCoupleOfShape.hxx>
+#include <NMTTools_ListIteratorOfListOfCoupleOfShape.hxx>
+#include <NMTTools_CoupleOfShape.hxx>
+//
+
+static
+ Standard_Boolean FindFacePairs (const TopoDS_Edge& ,
+ const TopTools_ListOfShape& ,
+ NMTTools_ListOfCoupleOfShape& );
+
+static
+ void Path(const TopoDS_Shape& ,
+ const TopoDS_Shape& ,
+ const TopTools_IndexedDataMapOfShapeListOfShape& ,
+ const TopTools_IndexedMapOfShape& ,
+ TopTools_IndexedMapOfShape& );
+static
+ Standard_Real AngleWithRef(const gp_Dir& ,
+ const gp_Dir& ,
+ const gp_Dir& );
+
+//=======================================================================
+//function : IsInternalFace
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_Tools3D::IsInternalFace(const TopoDS_Face& theFace,
+ const TopoDS_Solid& theSolid,
+ const TopTools_IndexedDataMapOfShapeListOfShape& theMEF,
+ const Standard_Real theTol,
+ IntTools_Context& theContext)
+{
+ Standard_Boolean bRet;
+ Standard_Integer aNbF;
+ TopoDS_Edge aEL;
+ TopExp_Explorer aExp;
+ TopTools_ListIteratorOfListOfShape aItF;
+ //
+ bRet=Standard_False;
+ //
+ // 1 Try to find an edge from theFace in theMEF
+ aExp.Init(theFace, TopAbs_EDGE);
+ for(; aExp.More(); aExp.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(aExp.Current());
+ if (!theMEF.Contains(aE)) {
+ continue;
+ }
+ //
+ const TopTools_ListOfShape& aLF=theMEF.FindFromKey(aE);
+ aNbF=aLF.Extent();
+ if (!aNbF) {
+ return bRet; // it can not be so
+ }
+ else if (aNbF==1) {
+ // aE is internal edge on aLF.First()
+ const TopoDS_Face& aF1=TopoDS::Face(aLF.First());
+ bRet=GEOMAlgo_Tools3D::IsInternalFace(theFace, aE, aF1, aF1);
+ return bRet;
+ }
+ else if (aNbF==2) {
+ const TopoDS_Face& aF1=TopoDS::Face(aLF.First());
+ const TopoDS_Face& aF2=TopoDS::Face(aLF.Last());
+ //
+ if (aF2.IsSame(aF1) && BRep_Tool::IsClosed(aE, aF1)) {
+ // treat as it was for 1 face
+ bRet=GEOMAlgo_Tools3D::IsInternalFace(theFace, aE, aF1, aF2);
+ return bRet;
+ }
+ }
+ if (aNbF%2) {
+ return bRet; // it can not be so
+ }
+ else { // aNbF=2,4,6,8,...
+ bRet=GEOMAlgo_Tools3D::IsInternalFace(theFace, aE, aLF);
+ return bRet;
+ }
+ }//for(; aExp.More(); aExp.Next()) {
+ //
+ //========================================
+ // 2. Classify face using classifier
+ //
+ TopAbs_State aState;
+ TopTools_IndexedMapOfShape aBounds;
+ //
+ aState=GEOMAlgo_Tools3D::ComputeState(theFace, theSolid, theTol, aBounds, theContext);
+ bRet=(aState==TopAbs_IN);
+ //
+ return bRet;
+}
+//=======================================================================
+//function : IsInternalFace
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_Tools3D::IsInternalFace(const TopoDS_Face& theFace,
+ const TopoDS_Edge& theEdge,
+ const TopTools_ListOfShape& theLF)
+{
+ Standard_Boolean bRet;
+ Standard_Boolean aNbF;
+ //
+ bRet=Standard_False;
+ //
+ aNbF=theLF.Extent();
+ if (aNbF==2) {
+ const TopoDS_Face& aF1=TopoDS::Face(theLF.First());
+ const TopoDS_Face& aF2=TopoDS::Face(theLF.Last());
+ bRet=GEOMAlgo_Tools3D::IsInternalFace(theFace, theEdge, aF1, aF2);
+ return bRet;
+ }
+ //
+ else {
+ NMTTools_ListOfCoupleOfShape aLCFF;
+ NMTTools_ListIteratorOfListOfCoupleOfShape aIt;
+ //
+ FindFacePairs(theEdge, theLF, aLCFF);
+ //
+ aIt.Initialize(aLCFF);
+ for (; aIt.More(); aIt.Next()) {
+ const NMTTools_CoupleOfShape& aCSFF=aIt.Value();
+ //
+ const TopoDS_Face& aF1=TopoDS::Face(aCSFF.Shape1());
+ const TopoDS_Face& aF2=TopoDS::Face(aCSFF.Shape2());
+ bRet=GEOMAlgo_Tools3D::IsInternalFace(theFace, theEdge, aF1, aF2);
+ if (bRet) {
+ return bRet;
+ }
+ }
+ }
+ return bRet;
+}
+//=======================================================================
+//function : IsInternalFace
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_Tools3D::IsInternalFace(const TopoDS_Face& theFace,
+ const TopoDS_Edge& theEdge,
+ const TopoDS_Face& theFace1,
+ const TopoDS_Face& theFace2)
+{
+ Standard_Boolean bRet;
+ Standard_Real aT1, aT2, aT, aDt2D, aD1, aD2, aDt2Dx;
+ gp_Pnt aPx, aPF, aPF1, aPF2;
+ gp_Pnt2d aP2D, aPF2D;
+ gp_Dir aDNF1, aDNF2;
+ TopoDS_Edge aE1, aE2;
+ Handle(Geom_Curve)aC3D;
+ //
+ aC3D =BRep_Tool::Curve(theEdge, aT1, aT2);
+ aT=BOPTools_Tools2D::IntermediatePoint(aT1, aT2);
+ aC3D->D0(aT, aPx);
+ //
+ // 1. PF
+ aDt2D=BOPTools_Tools3D::MinStepIn2d();
+ aDt2Dx=10.*aDt2D;
+ BOPTools_Tools3D::PointNearEdge (theEdge, theFace, aT, aDt2Dx, aPF2D, aPF);
+ //
+ // 2. E1, E2
+ GEOMAlgo_Tools3D::GetEdgeOnFace(theEdge, theFace1, aE1);
+ if (aE1.Orientation()==TopAbs_INTERNAL) {
+ aE2=aE1;
+ aE1.Orientation(TopAbs_FORWARD);
+ aE2.Orientation(TopAbs_REVERSED);
+ }
+ else if (theFace1==theFace2) {
+ aE2=aE1;
+ aE1.Orientation(TopAbs_FORWARD);
+ aE2.Orientation(TopAbs_REVERSED);
+ }
+ else {
+ GEOMAlgo_Tools3D::GetEdgeOnFace(theEdge, theFace2, aE2);
+ }
+ //
+ // 3
+ bRet=Standard_False;
+ //
+ BOPTools_Tools3D::GetApproxNormalToFaceOnEdge (aE1, theFace1, aT, aPF1, aDNF1);
+ gp_Pln aPlnF1(aPx, aDNF1);
+ //
+ aD1=BOPTools_Tools3D::SignDistance(aPF, aPlnF1);
+ if (aD1<=0.) {
+ BOPTools_Tools3D::GetApproxNormalToFaceOnEdge (aE2, theFace2, aT, aPF2, aDNF2);
+ gp_Pln aPlnF2(aPx, aDNF2);
+ //
+ aD2=BOPTools_Tools3D::SignDistance(aPF, aPlnF2);
+ if (aD2<=0.) {
+ bRet=!bRet; //TopAbs_IN;
+ }
+ }
+ return bRet;
+}
+//=======================================================================
+//function : GetFaceOff
+//purpose :
+//=======================================================================
+ void GEOMAlgo_Tools3D::GetFaceOff(const TopoDS_Edge& theE1,
+ const TopoDS_Face& theF1,
+ const NMTTools_ListOfCoupleOfShape& theLCSOff,
+ TopoDS_Face& theFOff)
+{
+ Standard_Real aT, aT1, aT2, aAngle, aTwoPI, aAngleMin;
+ gp_Pnt aPn1, aPn2;
+ gp_Vec aVTgt;
+ gp_Dir aDN1, aDN2;
+ NMTTools_ListIteratorOfListOfCoupleOfShape aIt;
+ //
+ aAngleMin=100.;
+ aTwoPI=PI+PI;
+ BRep_Tool::Range(theE1, aT1, aT2);
+ aT=BOPTools_Tools2D::IntermediatePoint(aT1, aT2);
+ // Ref
+ BOPTools_Tools2D::EdgeTangent(theE1, aT, aVTgt);
+ gp_Dir aDTtgt(aVTgt);
+ aDTtgt.Reverse();
+ // N1
+ BOPTools_Tools3D::GetApproxNormalToFaceOnEdge(theE1, theF1, aT, aPn1, aDN1);
+ //
+ aIt.Initialize(theLCSOff);
+ for (; aIt.More(); aIt.Next()) {
+ const NMTTools_CoupleOfShape& aCS=aIt.Value();
+ const TopoDS_Edge& aE2=TopoDS::Edge(aCS.Shape1());
+ const TopoDS_Face& aF2=TopoDS::Face(aCS.Shape2());
+ //
+ if (aF2==theF1) {
+ aAngle=PI;
+ }
+ else if (aF2.IsSame(theF1)) {
+ aAngle=aTwoPI;
+ }
+ else {
+ BOPTools_Tools3D::GetApproxNormalToFaceOnEdge (aE2, aF2, aT, aPn2, aDN2);
+ aDN2.Reverse();
+ // Angle
+ //
+ //aAngle=aDN1.AngleWithRef(aDN2, aDTtgt);
+ aAngle=AngleWithRef(aDN1, aDN2, aDTtgt);
+ //
+ if(aAngle<0.) {
+ aAngle=aTwoPI+aAngle;
+ }
+ }
+
+ if (aAngle<aAngleMin){
+ aAngleMin=aAngle;
+ theFOff=aF2;
+ }
+ }
+}
+//=======================================================================
+//function : GetEdgeOnFace
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_Tools3D::GetEdgeOnFace(const TopoDS_Edge& theE1,
+ const TopoDS_Face& theF2,
+ TopoDS_Edge& theE2)
+{
+ Standard_Boolean bFound;
+ TopoDS_Iterator aItF, aItW;
+ //
+ bFound=Standard_False;
+ //
+ aItF.Initialize(theF2);
+ for (; aItF.More(); aItF.Next()) {
+ const TopoDS_Shape& aW=aItF.Value();
+ aItW.Initialize(aW);
+ for (; aItW.More(); aItW.Next()) {
+ const TopoDS_Shape& aE=aItW.Value();
+ if (aE.IsSame(theE1)) {
+ theE2=TopoDS::Edge(aE);
+ bFound=!bFound;
+ return bFound;
+ }
+ }
+ }
+ return bFound;
+}
+//=======================================================================
+//function : GetEdgeOff
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_Tools3D::GetEdgeOff(const TopoDS_Edge& theE1,
+ const TopoDS_Face& theF2,
+ TopoDS_Edge& theE2)
+
+{
+ Standard_Boolean bFound;
+ TopAbs_Orientation aOr1, aOr1C, aOr2;
+ TopExp_Explorer anExp;
+ //
+ bFound=Standard_False;
+ aOr1=theE1.Orientation();
+ aOr1C=TopAbs::Reverse(aOr1);
+ //
+ anExp.Init(theF2, TopAbs_EDGE);
+ for (; anExp.More(); anExp.Next()) {
+ const TopoDS_Edge& aEF2=TopoDS::Edge(anExp.Current());
+ if (aEF2.IsSame(theE1)) {
+ aOr2=aEF2.Orientation();
+ if (aOr2==aOr1C) {
+ theE2=aEF2;
+ bFound=!bFound;
+ return bFound;
+ }
+ }
+ }
+ return bFound;
+}
+//=======================================================================
+// function: ComputeState
+// purpose:
+//=======================================================================
+ TopAbs_State GEOMAlgo_Tools3D::ComputeState(const TopoDS_Face& theF,
+ const TopoDS_Solid& theRef,
+ const Standard_Real theTol,
+ const TopTools_IndexedMapOfShape& theBounds,
+ IntTools_Context& theCtx)
+{
+ TopAbs_State aState;
+ TopExp_Explorer aExp;
+ TopoDS_Edge aE1;
+ gp_Pnt2d aP2D;
+ gp_Pnt aP3D;
+ //
+ aState=TopAbs_UNKNOWN;
+ //
+ aExp.Init(theF, TopAbs_EDGE);
+ for (; aExp.More(); aExp.Next()) {
+ const TopoDS_Edge& aSE=TopoDS::Edge(aExp.Current());
+ if (BRep_Tool::Degenerated(aSE)) {
+ continue;
+ }
+ //
+ if (!theBounds.Contains(aSE)) {
+ const TopoDS_Edge& aE=TopoDS::Edge(aSE);
+ aState= GEOMAlgo_Tools3D::ComputeState(aE, theRef, theTol, theCtx);
+ return aState;
+ }
+ if (aE1.IsNull()) {
+ aE1=TopoDS::Edge(aSE);
+ }
+ }
+ // !!<- process edges that are all on theRef
+ if (!aE1.IsNull()) {
+ BOPTools_Tools3D::PointNearEdge(aE1, theF, aP2D, aP3D);
+ aState=GEOMAlgo_Tools3D::ComputeState(aP3D, theRef, theTol, theCtx);
+ }
+ //
+ return aState;
+}
+//=======================================================================
+// function: ComputeStateByOnePoint
+// purpose:
+//=======================================================================
+ TopAbs_State GEOMAlgo_Tools3D::ComputeStateByOnePoint(const TopoDS_Shape& theS,
+ const TopoDS_Solid& theRef,
+ const Standard_Real theTol,
+ IntTools_Context& theCtx)
+{
+ TopAbs_State aState;
+ TopAbs_ShapeEnum aType;
+ //
+ aState=TopAbs_UNKNOWN;
+ aType=theS.ShapeType();
+ if (aType==TopAbs_VERTEX) {
+ const TopoDS_Vertex& aV=TopoDS::Vertex(theS);
+ aState=GEOMAlgo_Tools3D::ComputeState(aV, theRef, theTol, theCtx);
+ }
+ else if (aType==TopAbs_EDGE) {
+ const TopoDS_Edge& aE=TopoDS::Edge(theS);
+ aState=GEOMAlgo_Tools3D::ComputeState(aE, theRef, theTol, theCtx);
+ }
+ return aState;
+}
+//=======================================================================
+// function: ComputeState
+// purpose:
+//=======================================================================
+ TopAbs_State GEOMAlgo_Tools3D::ComputeState(const TopoDS_Vertex& theV,
+ const TopoDS_Solid& theRef,
+ const Standard_Real theTol,
+ IntTools_Context& theCtx)
+{
+ TopAbs_State aState;
+ gp_Pnt aP3D;
+ //
+ aP3D=BRep_Tool::Pnt(theV);
+ aState=GEOMAlgo_Tools3D::ComputeState(aP3D, theRef, theTol, theCtx);
+ return aState;
+}
+//=======================================================================
+// function: ComputeState
+// purpose:
+//=======================================================================
+ TopAbs_State GEOMAlgo_Tools3D::ComputeState(const TopoDS_Edge& theE,
+ const TopoDS_Solid& theRef,
+ const Standard_Real theTol,
+ IntTools_Context& theCtx)
+{
+ Standard_Real aT1, aT2, aT = 0.;
+ TopAbs_State aState;
+ Handle(Geom_Curve) aC3D;
+ gp_Pnt aP3D;
+ //
+ aC3D = BRep_Tool::Curve(theE, aT1, aT2);
+ //
+ if(aC3D.IsNull()) {
+ //it means that we are in degenerated edge
+ const TopoDS_Vertex& aV = TopExp::FirstVertex(theE);
+ if(aV.IsNull()){
+ return TopAbs_UNKNOWN;
+ }
+ aP3D=BRep_Tool::Pnt(aV);
+ }
+ else {//usual case
+ Standard_Boolean bF2Inf, bL2Inf;
+ Standard_Real dT=10.;
+ //
+ bF2Inf = Precision::IsNegativeInfinite(aT1);
+ bL2Inf = Precision::IsPositiveInfinite(aT2);
+ //
+ if (bF2Inf && !bL2Inf) {
+ aT=aT2-dT;
+ }
+ else if (!bF2Inf && bL2Inf) {
+ aT=aT1+dT;
+ }
+ else if (bF2Inf && bL2Inf) {
+ aT=0.;
+ }
+ else {
+ aT=IntTools_Tools::IntermediatePoint(aT1, aT2);
+ }
+ aC3D->D0(aT, aP3D);
+ }
+ //
+ aState=GEOMAlgo_Tools3D::ComputeState(aP3D, theRef, theTol, theCtx);
+ //
+ return aState;
+}
+//=======================================================================
+// function: ComputeState
+// purpose:
+//=======================================================================
+ TopAbs_State GEOMAlgo_Tools3D::ComputeState(const gp_Pnt& theP,
+ const TopoDS_Solid& theRef,
+ const Standard_Real theTol,
+ IntTools_Context& theCtx)
+{
+ TopAbs_State aState;
+ //
+ BRepClass3d_SolidClassifier& aSC=theCtx.SolidClassifier(theRef);
+ aSC.Perform(theP, theTol);
+ //
+ aState=aSC.State();
+ //
+ return aState;
+}
+//=======================================================================
+// function: IsSplitToReverse
+// purpose:
+//=======================================================================
+ Standard_Boolean GEOMAlgo_Tools3D::IsSplitToReverse(const TopoDS_Shape& theSp,
+ const TopoDS_Shape& theSr,
+ IntTools_Context& theCtx)
+{
+ Standard_Boolean bRet;
+ TopAbs_ShapeEnum aType;
+ //
+ bRet=Standard_False;
+ //
+ aType=theSp.ShapeType();
+ switch (aType) {
+ case TopAbs_EDGE: {
+ const TopoDS_Edge& aESp=TopoDS::Edge(theSp);
+ const TopoDS_Edge& aESr=TopoDS::Edge(theSr);
+ bRet=GEOMAlgo_Tools3D::IsSplitToReverse(aESp, aESr, theCtx);
+ }
+ break;
+ //
+ case TopAbs_FACE: {
+ const TopoDS_Face& aFSp=TopoDS::Face(theSp);
+ const TopoDS_Face& aFSr=TopoDS::Face(theSr);
+ bRet=GEOMAlgo_Tools3D::IsSplitToReverse(aFSp, aFSr, theCtx);
+ }
+ break;
+ //
+ default:
+ break;
+ }
+ return bRet;
+}
+//=======================================================================
+//function :IsSplitToReverse
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_Tools3D::IsSplitToReverse(const TopoDS_Face& theFSp,
+ const TopoDS_Face& theFSr,
+ IntTools_Context& theContext)
+{
+ Standard_Boolean bRet, bFound, bInFace;
+ Standard_Real aT1, aT2, aT, aU, aV, aScPr;
+ gp_Pnt aPFSp, aPFSr;
+ gp_Dir aDNFSp;
+ gp_Vec aD1U, aD1V;
+ Handle(Geom_Surface) aSr, aSp;
+ TopAbs_Orientation aOrSr, aOrSp;
+ TopExp_Explorer anExp;
+ TopoDS_Edge aESp;
+ //
+ bRet=Standard_False;
+ //
+ aSr=BRep_Tool::Surface(theFSr);
+ aSp=BRep_Tool::Surface(theFSp);
+ if (aSr==aSp) {
+ aOrSr=theFSr.Orientation();
+ aOrSp=theFSp.Orientation();
+ bRet=(aOrSr!=aOrSp);
+ return bRet;
+ }
+ //
+ bFound=Standard_False;
+ anExp.Init(theFSp, TopAbs_EDGE);
+ for (; anExp.More(); anExp.Next()) {
+ aESp=TopoDS::Edge(anExp.Current());
+ if (!BRep_Tool::Degenerated(aESp)) {
+ if (!BRep_Tool::IsClosed(aESp, theFSp)) {
+ bFound=!bFound;
+ break;
+ }
+ }
+ }
+ if (!bFound) {
+ return bRet;
+ }
+ //
+ BRep_Tool::Range(aESp, aT1, aT2);
+ aT=BOPTools_Tools2D::IntermediatePoint(aT1, aT2);
+ BOPTools_Tools3D::GetApproxNormalToFaceOnEdge(aESp, theFSp, aT, aPFSp, aDNFSp);
+ //
+ // Parts of theContext.ComputeVS(..)
+ GeomAPI_ProjectPointOnSurf& aProjector=theContext.ProjPS(theFSr);
+ aProjector.Perform(aPFSp);
+ if (!aProjector.IsDone()) {
+ return bRet;
+ }
+ //
+ aProjector.LowerDistanceParameters(aU, aV);
+ gp_Pnt2d aP2D(aU, aV);
+ bInFace=theContext.IsPointInFace (theFSr, aP2D);
+ if (!bInFace) {
+ return bRet;
+ }
+ //
+ aSr->D1(aU, aV, aPFSr, aD1U, aD1V);
+ gp_Dir aDD1U(aD1U);
+ gp_Dir aDD1V(aD1V);
+ gp_Dir aDNFSr=aDD1U^aDD1V;
+ if (theFSr.Orientation()==TopAbs_REVERSED){
+ aDNFSr.Reverse();
+ }
+ //
+ aScPr=aDNFSp*aDNFSr;
+ bRet=(aScPr<0.);
+ //
+ return bRet;
+}
+//=======================================================================
+//function :IsSplitToReverse
+//purpose :
+//=======================================================================
+ Standard_Boolean GEOMAlgo_Tools3D::IsSplitToReverse(const TopoDS_Edge& theSplit,
+ const TopoDS_Edge& theEdge,
+ IntTools_Context& theContext)
+{
+ Standard_Boolean bRet, aFlag, bIsDegenerated;
+ Standard_Real aTE, aTS, aScPr, aTa, aTb, aT1, aT2;
+ TopAbs_Orientation aOrSr, aOrSp;
+ Handle(Geom_Curve) aCEdge, aCSplit;
+ gp_Vec aVE, aVS;
+ gp_Pnt aP;
+ //
+ bRet=Standard_False;
+ //
+ bIsDegenerated=(BRep_Tool::Degenerated(theSplit) ||
+ BRep_Tool::Degenerated(theEdge));
+ if (bIsDegenerated) {
+ return bRet;
+ }
+ //
+ aCEdge =BRep_Tool::Curve(theEdge , aT1, aT2);
+ aCSplit=BRep_Tool::Curve(theSplit, aTa, aTb);
+ //
+ if (aCEdge==aCSplit) {
+ aOrSr=theEdge.Orientation();
+ aOrSp=theSplit.Orientation();
+ bRet=(aOrSr!=aOrSp);
+ return bRet;
+ }
+ //
+ aTS=BOPTools_Tools2D::IntermediatePoint(aTa, aTb);
+ aCSplit->D0(aTS, aP);
+ aFlag=BOPTools_Tools2D::EdgeTangent(theSplit, aTS, aVS);
+ gp_Dir aDTS(aVS);
+ //
+ aFlag=theContext.ProjectPointOnEdge(aP, theEdge, aTE);
+ aFlag=BOPTools_Tools2D::EdgeTangent(theEdge, aTE, aVE);
+ gp_Dir aDTE(aVE);
+ //
+ aScPr=aDTS*aDTE;
+ bRet=(aScPr<0.);
+ //
+ return bRet;
+}
+
+//=======================================================================
+// function: Sense
+// purpose:
+//=======================================================================
+ Standard_Integer GEOMAlgo_Tools3D::Sense (const TopoDS_Face& theF1,
+ const TopoDS_Face& theF2)
+{
+ Standard_Integer iSense=0;
+ gp_Dir aDNF1, aDNF2;
+ TopoDS_Edge aE1, aE2;
+ TopExp_Explorer anExp;
+ //
+ anExp.Init(theF1, TopAbs_EDGE);
+ for (; anExp.More(); anExp.Next()) {
+ aE1=TopoDS::Edge(anExp.Current());
+ if (!BRep_Tool::Degenerated(aE1)) {
+ if (!BRep_Tool::IsClosed(aE1, theF1)) {
+ break;
+ }
+ }
+ }
+ //
+ anExp.Init(theF2, TopAbs_EDGE);
+ for (; anExp.More(); anExp.Next()) {
+ aE2=TopoDS::Edge(anExp.Current());
+ if (!BRep_Tool::Degenerated(aE2)) {
+ if (!BRep_Tool::IsClosed(aE2, theF2)) {
+ if (aE2.IsSame(aE1)) {
+ iSense=1;
+ break;
+ }
+ }
+ }
+ }
+ //
+ if (!iSense) {
+ return iSense;
+ }
+ //
+ BOPTools_Tools3D::GetNormalToFaceOnEdge(aE1, theF1, aDNF1);
+ BOPTools_Tools3D::GetNormalToFaceOnEdge(aE2, theF2, aDNF2);
+ //
+ iSense=BOPTools_Tools3D::SenseFlag(aDNF1, aDNF2);
+ //
+ return iSense;
+}
+//=======================================================================
+// function: CopyFace
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Tools3D::CopyFace (const TopoDS_Face& theF1,
+ TopoDS_Face& theF2)
+{
+ Standard_Real aTol;
+ TopLoc_Location aLoc;
+ TopAbs_Orientation aOr;
+ TopoDS_Iterator aIt;
+ BRep_Builder aBB;
+ //
+ Handle(Geom_Surface) aSurface=BRep_Tool::Surface(theF1, aLoc);
+ aTol=BRep_Tool::Tolerance(theF1);
+ aOr=theF1.Orientation();
+ //
+ aBB.MakeFace (theF2, aSurface, aLoc, aTol);
+ theF2.Orientation(aOr);
+ //
+ aIt.Initialize(theF1);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aW=aIt.Value();
+ aBB.Add(theF2, aW);
+ }
+}
+//=======================================================================
+// function: MakeContainer
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Tools3D::MakeContainer(const TopAbs_ShapeEnum theType,
+ TopoDS_Shape& theC)
+{
+ BRep_Builder aBB;
+ //
+ switch(theType) {
+ case TopAbs_COMPOUND:{
+ TopoDS_Compound aC;
+ aBB.MakeCompound(aC);
+ theC=aC;
+ }
+ break;
+ //
+ case TopAbs_COMPSOLID:{
+ TopoDS_CompSolid aCS;
+ aBB.MakeCompSolid(aCS);
+ theC=aCS;
+ }
+ break;
+ //
+ case TopAbs_SOLID:{
+ TopoDS_Solid aSolid;
+ aBB.MakeSolid(aSolid);
+ theC=aSolid;
+ }
+ break;
+ //
+ //
+ case TopAbs_SHELL:{
+ TopoDS_Shell aShell;
+ aBB.MakeShell(aShell);
+ theC=aShell;
+ }
+ break;
+ //
+ case TopAbs_WIRE: {
+ TopoDS_Wire aWire;
+ aBB.MakeWire(aWire);
+ theC=aWire;
+ }
+ break;
+ //
+ default:
+ break;
+ }
+}
+//=======================================================================
+// function: MakeConnexityBlock.
+// purpose:
+//=======================================================================
+ void GEOMAlgo_Tools3D::MakeConnexityBlock (const TopTools_ListOfShape& theLFIn,
+ const TopTools_IndexedMapOfShape& theMEAvoid,
+ TopTools_ListOfShape& theLCB)
+{
+ Standard_Integer j, aNbF;
+ TopTools_IndexedDataMapOfShapeListOfShape aEFMap;
+ TopTools_IndexedMapOfShape aMFP, aCBMap;
+ TopTools_ListIteratorOfListOfShape aIt;
+ TopExp_Explorer aExp;
+ TopAbs_ShapeEnum aType;
+ //
+ aIt.Initialize(theLFIn);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ aType=aF.ShapeType();
+ TopExp::MapShapesAndAncestors(aF, TopAbs_EDGE, TopAbs_FACE, aEFMap);
+ }
+ //
+ aCBMap.Clear();
+ const TopoDS_Shape& aF=theLFIn.First();
+ //
+ aCBMap.Add(aF);
+ //
+ aExp.Init(aF, TopAbs_EDGE);
+ for (; aExp.More(); aExp.Next()){
+ const TopoDS_Shape& aE=aExp.Current();
+ if (theMEAvoid.Contains(aE)){
+ continue;
+ }
+ //
+ const TopTools_ListOfShape& aLF=aEFMap.FindFromKey(aE);
+ aIt.Initialize(aLF);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF1=aIt.Value();
+ if (!aF1.IsSame(aF)) {
+ Path (aE, aF1, aEFMap, theMEAvoid, aCBMap);
+ }
+ }
+ }
+ //
+ aNbF=aCBMap.Extent();
+ for (j=1; j<=aNbF; ++j) {
+ const TopoDS_Shape& aFx=aCBMap(j);
+ theLCB.Append(aFx);
+ }
+}
+//=======================================================================
+// function: Path
+// purpose:
+//=======================================================================
+void Path(const TopoDS_Shape& theE1,
+ const TopoDS_Shape& theF1,
+ const TopTools_IndexedDataMapOfShapeListOfShape& theEFMap,
+ const TopTools_IndexedMapOfShape& theMEAvoid,
+ TopTools_IndexedMapOfShape& theCBMap)
+{
+ TopTools_ListIteratorOfListOfShape aIt;
+ TopExp_Explorer aExp;
+ //
+ if (theCBMap.Contains(theF1)){
+ return;
+ }
+ theCBMap.Add(theF1);
+ //
+ aExp.Init(theF1, TopAbs_EDGE);
+ for (; aExp.More(); aExp.Next()){
+ const TopoDS_Shape& aE=aExp.Current();
+ if (!aE.IsSame(theE1)){
+ if (theMEAvoid.Contains(aE)) {
+ continue;
+ }
+ //
+ const TopTools_ListOfShape& aLF=theEFMap.FindFromKey(aE);
+ aIt.Initialize(aLF);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aF=aIt.Value();
+ Path (aE, aF, theEFMap, theMEAvoid, theCBMap);
+ }
+ }
+ }
+}
+//=======================================================================
+//function : FindFacePairs
+//purpose :
+//=======================================================================
+Standard_Boolean FindFacePairs (const TopoDS_Edge& theE,
+ const TopTools_ListOfShape& thLF,
+ NMTTools_ListOfCoupleOfShape& theLCFF)
+{
+ Standard_Boolean bFound;
+ Standard_Integer i, aNbCEF;
+ TopAbs_Orientation aOr, aOrC;
+ TopTools_MapOfShape aMFP;
+ TopoDS_Face aF1, aF2;
+ TopoDS_Edge aEL, aE1;
+ TopTools_ListIteratorOfListOfShape aItLF;
+ NMTTools_CoupleOfShape aCEF, aCFF;
+ NMTTools_ListOfCoupleOfShape aLCEF, aLCEFx;
+ NMTTools_ListIteratorOfListOfCoupleOfShape aIt;
+ //
+ bFound=Standard_True;
+ //
+ // Preface aLCEF
+ aItLF.Initialize(thLF);
+ for (; aItLF.More(); aItLF.Next()) {
+ const TopoDS_Face& aFL=TopoDS::Face(aItLF.Value());
+ //
+ bFound=GEOMAlgo_Tools3D::GetEdgeOnFace(theE, aFL, aEL);
+ if (!bFound) {
+ return bFound; // it can not be so
+ }
+ //
+ aCEF.SetShape1(aEL);
+ aCEF.SetShape2(aFL);
+ aLCEF.Append(aCEF);
+ }
+ //
+ aNbCEF=aLCEF.Extent();
+ while(aNbCEF) {
+ //
+ // aLCEFx
+ aLCEFx.Clear();
+ aIt.Initialize(aLCEF);
+ for (i=0; aIt.More(); aIt.Next(), ++i) {
+ const NMTTools_CoupleOfShape& aCSx=aIt.Value();
+ const TopoDS_Shape& aEx=aCSx.Shape1();
+ const TopoDS_Shape& aFx=aCSx.Shape2();
+ //
+ aOr=aEx.Orientation();
+ //
+ if (!i) {
+ aOrC=TopAbs::Reverse(aOr);
+ aE1=TopoDS::Edge(aEx);
+ aF1=TopoDS::Face(aFx);
+ aMFP.Add(aFx);
+ continue;
+ }
+ //
+ if (aOr==aOrC) {
+ aLCEFx.Append(aCSx);
+ aMFP.Add(aFx);
+ }
+ }
+ //
+ // F2
+ GEOMAlgo_Tools3D::GetFaceOff(aE1, aF1, aLCEFx, aF2);
+ //
+ aCFF.SetShape1(aF1);
+ aCFF.SetShape2(aF2);
+ theLCFF.Append(aCFF);
+ //
+ aMFP.Add(aF1);
+ aMFP.Add(aF2);
+ //
+ // refine aLCEF
+ aLCEFx.Clear();
+ aLCEFx=aLCEF;
+ aLCEF.Clear();
+ aIt.Initialize(aLCEFx);
+ for (; aIt.More(); aIt.Next()) {
+ const NMTTools_CoupleOfShape& aCSx=aIt.Value();
+ const TopoDS_Shape& aFx=aCSx.Shape2();
+ if (!aMFP.Contains(aFx)) {
+ aLCEF.Append(aCSx);
+ }
+ }
+ //
+ aNbCEF=aLCEF.Extent();
+ }//while(aNbCEF) {
+ //
+ return bFound;
+}
+//
+//=======================================================================
+//function : AngleWithRef
+//purpose :
+//=======================================================================
+Standard_Real AngleWithRef(const gp_Dir& theD1,
+ const gp_Dir& theD2,
+ const gp_Dir& theDRef)
+{
+ Standard_Real aCosinus, aSinus, aBeta, aHalfPI, aScPr;
+ gp_XYZ aXYZ;
+ //
+ aHalfPI=0.5*PI;
+ //
+ const gp_XYZ& aXYZ1=theD1.XYZ();
+ const gp_XYZ& aXYZ2=theD2.XYZ();
+ aXYZ=aXYZ1.Crossed(aXYZ2);
+ aSinus=aXYZ.Modulus();
+ aCosinus=theD1*theD2;
+ //
+ aBeta=0.;
+ if (aSinus>=0.) {
+ aBeta=aHalfPI*(1.-aCosinus);
+ }
+ else {
+ aBeta=2.*PI-aHalfPI*(3.+aCosinus);
+ }
+ //
+ aScPr=aXYZ.Dot(theDRef.XYZ());
+ if (aScPr<0.) {
+ aBeta=-aBeta;
+ }
+ return aBeta;
+}
+//
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_Tools3D_HeaderFile
+#define _GEOMAlgo_Tools3D_HeaderFile
+
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _TopAbs_ShapeEnum_HeaderFile
+#include <TopAbs_ShapeEnum.hxx>
+#endif
+#ifndef _TopAbs_State_HeaderFile
+#include <TopAbs_State.hxx>
+#endif
+#ifndef _Standard_Real_HeaderFile
+#include <Standard_Real.hxx>
+#endif
+class TopoDS_Shape;
+class IntTools_Context;
+class TopoDS_Face;
+class TopoDS_Edge;
+class TopTools_ListOfShape;
+class TopTools_IndexedMapOfShape;
+class TopoDS_Solid;
+class gp_Pnt;
+class TopoDS_Vertex;
+class TopTools_IndexedDataMapOfShapeListOfShape;
+class NMTTools_ListOfCoupleOfShape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+//! Auxiliary tools for Algorithms <br>
+class GEOMAlgo_Tools3D {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+//! Returns True if the shape theSplit has opposite <br>
+//! direction than theShape <br>
+//! theContext - cashed geometrical tools <br>
+Standard_EXPORT static Standard_Boolean IsSplitToReverse(const TopoDS_Shape& theSplit,const TopoDS_Shape& theShape,IntTools_Context& theContext) ;
+
+//! Returns True if normal direction of the face <br>
+//! theShape is not the same as for the face <br>
+//! theSplit <br>
+//! theContext - cashed geometrical tools <br>
+Standard_EXPORT static Standard_Boolean IsSplitToReverse(const TopoDS_Face& theSplit,const TopoDS_Face& theShape,IntTools_Context& theContext) ;
+
+//! Returns True if tangent direction of the edge <br>
+//! theEdge is not the same as for the edge <br>
+//! theSplit <br>
+//! theContext - cashed geometrical tools <br>
+Standard_EXPORT static Standard_Boolean IsSplitToReverse(const TopoDS_Edge& theEdge,const TopoDS_Edge& theSplit,IntTools_Context& theContext) ;
+
+//! For the couple of faces theF1, theF2 <br>
+//! computes sense value <br>
+//! Returns 0 if the faces are not sensible <br>
+//! Returns 1 if the faces have same sense <br>
+//! Returns 2 if the faces have opposite sense <br>
+Standard_EXPORT static Standard_Integer Sense(const TopoDS_Face& theF1,const TopoDS_Face& theF2) ;
+
+//! Makes new face theF2 from surface and wires <br>
+//! of the face theF1 <br>
+Standard_EXPORT static void CopyFace(const TopoDS_Face& theF1,TopoDS_Face& theF2) ;
+
+//! Makes empty shape theShape of the type theType <br>
+Standard_EXPORT static void MakeContainer(const TopAbs_ShapeEnum theType,TopoDS_Shape& theShape) ;
+
+//! For the list of faces theLS build block <br>
+//! theLSCB in terms of connexity by edges <br>
+//! theMapAvoid - set of edges to avoid for <br>
+//! the treatment <br>
+Standard_EXPORT static void MakeConnexityBlock(const TopTools_ListOfShape& theLS,const TopTools_IndexedMapOfShape& theMapAvoid,TopTools_ListOfShape& theLSCB) ;
+
+//! Computes the 3-D state of the shape theShape <br>
+//! toward solid theSolid. <br>
+//! theTol - value of precision of computation <br>
+//! theContext- cahed geometrical tools <br>
+//! Returns 3-D state. <br>
+Standard_EXPORT static TopAbs_State ComputeStateByOnePoint(const TopoDS_Shape& theShape,const TopoDS_Solid& theSolid,const Standard_Real theTol,IntTools_Context& theContext) ;
+
+//! Computes the 3-D state of the point thePoint <br>
+//! toward solid theSolid. <br>
+//! theTol - value of precision of computation <br>
+//! theContext- cahed geometrical tools <br>
+//! Returns 3-D state. <br>
+Standard_EXPORT static TopAbs_State ComputeState(const gp_Pnt& thePoint,const TopoDS_Solid& theSolid,const Standard_Real theTol,IntTools_Context& theContext) ;
+
+//! Computes the 3-D state of the vertex theVertex <br>
+//! toward solid theSolid. <br>
+//! theTol - value of precision of computation <br>
+//! theContext- cahed geometrical tools <br>
+//! Returns 3-D state. <br>
+Standard_EXPORT static TopAbs_State ComputeState(const TopoDS_Vertex& theVertex,const TopoDS_Solid& theSolid,const Standard_Real theTol,IntTools_Context& theContext) ;
+
+//! Computes the 3-D state of the edge theEdge <br>
+//! toward solid theSolid. <br>
+//! theTol - value of precision of computation <br>
+//! theContext- cahed geometrical tools <br>
+//! Returns 3-D state. <br>
+Standard_EXPORT static TopAbs_State ComputeState(const TopoDS_Edge& theEdge,const TopoDS_Solid& theSolid,const Standard_Real theTol,IntTools_Context& theContext) ;
+
+//! Computes the 3-D state of the face theFace <br>
+//! toward solid theSolid. <br>
+//! theTol - value of precision of computation <br>
+//! theBounds - set of edges of theFace to avoid <br>
+//! theContext- cahed geometrical tools <br>
+//! Returns 3-D state. <br>
+Standard_EXPORT static TopAbs_State ComputeState(const TopoDS_Face& theFace,const TopoDS_Solid& theSolid,const Standard_Real theTol,const TopTools_IndexedMapOfShape& theBounds,IntTools_Context& theContext) ;
+
+//! Returns True if the face theFace is inside of the <br>
+//! couple of faces theFace1, theFace2. <br>
+//! The faces theFace, theFace1, theFace2 must <br>
+//! share the edge theEdge <br>
+Standard_EXPORT static Standard_Boolean IsInternalFace(const TopoDS_Face& theFace,const TopoDS_Edge& theEdge,const TopoDS_Face& theFace1,const TopoDS_Face& theFace2) ;
+
+//! Returns True if the face theFace is inside of the <br>
+//! appropriate couple of faces (from the set theLF) . <br>
+//! The faces of the set theLF and theFace must <br>
+//! share the edge theEdge <br>
+Standard_EXPORT static Standard_Boolean IsInternalFace(const TopoDS_Face& theFace,const TopoDS_Edge& theEdge,const TopTools_ListOfShape& theLF) ;
+
+//! Returns True if the face theFace is inside the <br>
+//! solid theSolid. <br>
+//! theMEF - Map Edge/Faces for theSolid <br>
+//! theTol - value of precision of computation <br>
+//! theContext- cahed geometrical tools <br>
+Standard_EXPORT static Standard_Boolean IsInternalFace(const TopoDS_Face& theFace,const TopoDS_Solid& theSolid,const TopTools_IndexedDataMapOfShapeListOfShape& theMEF,const Standard_Real theTol,IntTools_Context& theContext) ;
+
+//! For the face theFace and its edge theEdge <br>
+//! finds the face suitable to produce shell. <br>
+//! theLCEF - set of faces to search. All faces <br>
+//! from theLCEF must share edge theEdge <br>
+Standard_EXPORT static void GetFaceOff(const TopoDS_Edge& theEdge,const TopoDS_Face& theFace,const NMTTools_ListOfCoupleOfShape& theLCEF,TopoDS_Face& theFaceOff) ;
+
+//! For the face theFace gets the edge theEdgeOnF <br>
+//! that is the same as theEdge <br>
+//! Returns True if such edge exists <br>
+//! Returns False if there is no such edge <br>
+Standard_EXPORT static Standard_Boolean GetEdgeOnFace(const TopoDS_Edge& theEdge,const TopoDS_Face& theFace,TopoDS_Edge& theEdgeOnF) ;
+
+//! Returns True if the face theFace contains <br>
+//! the edge theEdge but with opposite orientation. <br>
+//! If the method returns True theEdgeOff is the <br>
+//! edge founded <br>
+Standard_EXPORT static Standard_Boolean GetEdgeOff(const TopoDS_Edge& theEdge,const TopoDS_Face& theFace,TopoDS_Edge& theEdgeOff) ;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_Tools3D.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _IntTools_Context_HeaderFile
+#include <IntTools_Context.hxx>
+#endif
+#ifndef _TopoDS_Face_HeaderFile
+#include <TopoDS_Face.hxx>
+#endif
+#ifndef _TopoDS_Edge_HeaderFile
+#include <TopoDS_Edge.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TopTools_IndexedMapOfShape_HeaderFile
+#include <TopTools_IndexedMapOfShape.hxx>
+#endif
+#ifndef _TopoDS_Solid_HeaderFile
+#include <TopoDS_Solid.hxx>
+#endif
+#ifndef _gp_Pnt_HeaderFile
+#include <gp_Pnt.hxx>
+#endif
+#ifndef _TopoDS_Vertex_HeaderFile
+#include <TopoDS_Vertex.hxx>
+#endif
+#ifndef _TopTools_IndexedDataMapOfShapeListOfShape_HeaderFile
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
+#endif
+#ifndef _NMTTools_ListOfCoupleOfShape_HeaderFile
+#include <NMTTools_ListOfCoupleOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_Tools3D_HeaderFile
+#include <GEOMAlgo_Tools3D.hxx>
+#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_VertexSolid.cdl
-- Created: Wed Jan 12 16:34:53 2005
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_VertexSolid : public GEOMAlgo_ShapeSolid {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_VertexSolid();
Standard_EXPORT virtual ~GEOMAlgo_VertexSolid();
+
+
Standard_EXPORT virtual void Perform() ;
// Methods PROTECTED
//
+
+
Standard_EXPORT virtual void Prepare() ;
+
+
Standard_EXPORT virtual void BuildResult() ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _GEOMAlgo_VertexSolid_HeaderFile
#include <GEOMAlgo_VertexSolid.hxx>
#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_WESCorrector.cdl
+-- Created:
+-- Author: Peter KURNEV
+
+
+class WESCorrector from GEOMAlgo
+ inherits Algo from GEOMAlgo
+
+ ---Purpose:
+ --- The algorithm to change the Wire Edges Set (WES) contents.
+ -- The NewWES will contain only wires instead of wires and edges.
+ --
+uses
+ WireEdgeSet from GEOMAlgo,
+ PWireEdgeSet from GEOMAlgo,
+ ListOfConnexityBlock from BOP
+
+is
+ Create
+ returns WESCorrector from GEOMAlgo;
+ ---C++: alias "Standard_EXPORT virtual ~GEOMAlgo_WESCorrector();"
+ ---Purpose:
+ -- Empty constructor;
+ --
+
+ SetWES (me:out;
+ aWES: WireEdgeSet from GEOMAlgo);
+ ---Purpose:
+ -- Modifier
+ --
+ Perform (me:out)
+ is redefined;
+ ---Purpose:
+ --- Performs the algorithm that consists of two steps
+ --- 1. Make conexity blocks ( DoConnexityBlocks() )
+ --- 2. Make corrections ( DoCorrections() )
+ ---
+
+ WES (me:out)
+ returns WireEdgeSet from GEOMAlgo;
+ ---C++: return &
+ ---Purpose:
+ --- Selector
+ ---
+ NewWES (me:out)
+ returns WireEdgeSet from GEOMAlgo;
+ ---C++: return &
+ ---Purpose:
+ --- Selector
+ ---
+ DoConnexityBlocks(me:out)
+ is protected;
+
+ DoCorrections(me:out)
+ is protected;
+
+fields
+
+ myWES : PWireEdgeSet from GEOMAlgo is protected;
+ myNewWES : WireEdgeSet from GEOMAlgo is protected;
+ myConnexityBlocks : ListOfConnexityBlock from BOP is protected;
+
+end WESCorrector;
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: NMTAlgo_WESCorrector.cxx
+// Created:
+// Author: Peter KURNEV
+// <pkv@irinox>
+
+
+#include <GEOMAlgo_WESCorrector.ixx>
+
+#include <TopoDS.hxx>
+#include <TopoDS_Shape.hxx>
+#include <TopoDS_Wire.hxx>
+#include <TopoDS_Face.hxx>
+#include <TopoDS_Edge.hxx>
+
+#include <BRep_Builder.hxx>
+#include <BRep_Tool.hxx>
+
+#include <TopTools_IndexedMapOfOrientedShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+
+#include <BOP_ConnexityBlock.hxx>
+#include <BOP_ListIteratorOfListOfConnexityBlock.hxx>
+
+#include <BOPTColStd_ListOfListOfShape.hxx>
+#include <BOPTColStd_ListIteratorOfListOfListOfShape.hxx>
+
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
+#include <NMTTools_IndexedDataMapOfShapeIndexedMapOfShape.hxx>
+#include <TopExp.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_MapIteratorOfMapOfShape.hxx>
+#include <TopoDS_Iterator.hxx>
+#include <GEOMAlgo_WireSplitter.hxx>
+
+
+static
+ void Path(const TopoDS_Shape& aV1,
+ const TopTools_IndexedDataMapOfShapeListOfShape& aMVE,
+ TopTools_MapOfShape& aMVP,
+ TopTools_MapOfShape& aMEP,
+ TopTools_MapOfShape& aMEC);
+static
+ void MakeWire(const TopTools_ListOfShape& aLE,
+ TopoDS_Wire& newWire);
+
+//=======================================================================
+// function:
+// purpose:
+//=======================================================================
+ GEOMAlgo_WESCorrector::GEOMAlgo_WESCorrector()
+:
+ GEOMAlgo_Algo()
+{
+}
+//=======================================================================
+// function: ~
+// purpose:
+//=======================================================================
+ GEOMAlgo_WESCorrector::~GEOMAlgo_WESCorrector()
+{
+}
+//=======================================================================
+// function: SetWES
+// purpose:
+//=======================================================================
+ void GEOMAlgo_WESCorrector::SetWES (const GEOMAlgo_WireEdgeSet& aWES)
+{
+ GEOMAlgo_WireEdgeSet* pWES=(GEOMAlgo_WireEdgeSet*) &aWES;
+ myWES=pWES;
+}
+//=======================================================================
+// function: WES
+// purpose:
+//=======================================================================
+ GEOMAlgo_WireEdgeSet& GEOMAlgo_WESCorrector::WES ()
+{
+ return *myWES;
+}
+//=======================================================================
+// function: NewWES
+// purpose:
+//=======================================================================
+ GEOMAlgo_WireEdgeSet& GEOMAlgo_WESCorrector::NewWES ()
+{
+ return myNewWES;
+}
+//=======================================================================
+// function: Perform
+// purpose:
+//=======================================================================
+ void GEOMAlgo_WESCorrector::Perform()
+{
+ myErrorStatus=0;
+ //
+ DoConnexityBlocks();
+ DoCorrections();
+}
+//=======================================================================
+// function: DoConnexityBlocks
+// purpose:
+//=======================================================================
+ void GEOMAlgo_WESCorrector::DoConnexityBlocks()
+{
+ Standard_Boolean bRegular;
+ Standard_Integer i, aNbV;
+ TopTools_ListIteratorOfListOfShape aIt;
+ TopoDS_Iterator aItE;
+ TopoDS_Shape aER;
+ TopTools_MapOfShape aMER, aMEP, aMEC, aMVP;
+ TopTools_MapIteratorOfMapOfShape aItM;
+ TopTools_IndexedDataMapOfShapeListOfShape aMVE;
+ //
+ // 1. aMVE;
+ const TopTools_ListOfShape& aLE=myWES->StartElements();
+ aIt.Initialize(aLE);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aE=aIt.Value();
+ if (aMEP.Add(aE)) {
+ TopExp::MapShapesAndAncestors(aE, TopAbs_VERTEX, TopAbs_EDGE, aMVE);
+ }
+ else {
+ aMER.Add(aE);
+ }
+ }
+ //
+ aMEP.Clear();
+ //
+ // 2.
+ aNbV=aMVE.Extent();
+ for (i=1; i<=aNbV; ++i) {
+ const TopoDS_Shape& aV=aMVE.FindKey(i);
+ if (aMVP.Contains(aV)) {
+ continue;
+ }
+ aMVP.Add(aV);
+ //
+ const TopTools_ListOfShape& aLEi=aMVE(i);
+ aIt.Initialize(aLEi);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aE=aIt.Value();
+ if (aMEP.Contains(aE)) {
+ continue;
+ }
+ //
+ aMEP.Add(aE);
+ aMEC.Add(aE);
+ aItE.Initialize(aE);
+ for (; aItE.More(); aItE.Next()) {
+ const TopoDS_Shape& aVE=aItE.Value();
+ Path(aVE, aMVE, aMVP, aMEP, aMEC);
+ }
+ }//for (; aIt.More(); aIt.Next()) {
+ //
+ BOP_ConnexityBlock aCB;
+ TopTools_ListOfShape aLEC;
+ TopTools_IndexedDataMapOfShapeListOfShape aMVER;
+ //
+ bRegular=Standard_True;
+ aItM.Initialize(aMEC);
+ for (; aItM.More(); aItM.Next()) {
+ aER=aItM.Key();
+ //
+ if (aMER.Contains(aER)) {
+ Standard_Boolean bClosed;
+ //
+ aER.Orientation(TopAbs_FORWARD);
+ aLEC.Append(aER);
+ aER.Orientation(TopAbs_REVERSED);
+ aLEC.Append(aER);
+ //
+ bClosed=BRep_Tool::IsClosed(TopoDS::Edge(aER), myWES->Face());
+ if (!bClosed) {
+ bRegular=Standard_False;
+ }
+ }
+ else {
+ aLEC.Append(aER);
+ }
+ //
+ if (bRegular) {
+ TopExp::MapShapesAndAncestors(aER, TopAbs_VERTEX, TopAbs_EDGE, aMVER);
+ }
+ }
+ //
+ if (bRegular) {
+ Standard_Integer j, aNbVR, aNbER;
+ //
+ aNbVR=aMVER.Extent();
+ for (j=1; j<=aNbVR; ++j) {
+ const TopTools_ListOfShape& aLER=aMVE(j);
+ aNbER=aLER.Extent();
+ if (aNbER==1) {
+ const TopoDS_Edge& aEx=TopoDS::Edge(aER);
+ if (!BRep_Tool::IsClosed(aEx, myWES->Face())) {
+ bRegular=!bRegular;
+ break;
+ }
+ }
+ if (aNbER>2) {
+ bRegular=!bRegular;
+ break;
+ }
+ }
+ }
+ //
+ aCB.SetShapes(aLEC);
+ aCB.SetRegularity(bRegular);
+ myConnexityBlocks.Append(aCB);
+ aMEC.Clear();
+ }//for (i=1; i<=aNbV; ++i) {
+}
+//=======================================================================
+// function: Path
+// purpose:
+//=======================================================================
+void Path(const TopoDS_Shape& aV1,
+ const TopTools_IndexedDataMapOfShapeListOfShape& aMVE,
+ TopTools_MapOfShape& aMVP,
+ TopTools_MapOfShape& aMEP,
+ TopTools_MapOfShape& aMEC)
+{
+ TopoDS_Iterator aItE;
+ TopTools_ListIteratorOfListOfShape aIt;
+ //
+ if (aMVP.Contains(aV1)) {
+ return;
+ }
+ aMVP.Add(aV1);
+ //
+ const TopTools_ListOfShape& aLE=aMVE.FindFromKey(aV1);
+ aIt.Initialize(aLE);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aE=aIt.Value();
+ if (aMEP.Contains(aE)) {
+ continue;
+ }
+ aMEP.Add(aE);
+ aMEC.Add(aE);
+ //
+ aItE.Initialize(aE);
+ for (; aItE.More(); aItE.Next()) {
+ const TopoDS_Shape& aVE=aItE.Value();
+ Path(aVE, aMVE, aMVP, aMEP, aMEC);
+ }
+ }
+}
+//=======================================================================
+// function: DoCorrections
+// purpose:
+//=======================================================================
+ void GEOMAlgo_WESCorrector::DoCorrections()
+{
+ Standard_Boolean bIsRegular, bIsNothingToDo;
+ Standard_Integer iErr;
+ TopoDS_Wire aW;
+ BOP_ListIteratorOfListOfConnexityBlock aCBIt;
+ //
+ const TopoDS_Face& aF=myWES->Face();
+ //
+ myNewWES.SetFace(aF);
+ aCBIt.Initialize(myConnexityBlocks);
+ for (; aCBIt.More(); aCBIt.Next()) {
+ const BOP_ConnexityBlock& aCB=aCBIt.Value();
+ const TopTools_ListOfShape& aLE=aCB.Shapes();
+
+ bIsRegular=aCB.IsRegular();
+
+ if (bIsRegular) {
+ MakeWire(aLE, aW);
+ myNewWES.AddShape (aW);
+ continue;
+ }
+ //
+ GEOMAlgo_WireSplitter aWS;
+ //
+ aWS.SetFace(aF);
+ aWS.SetEdges(aLE);
+ //
+ aWS.Perform();
+ iErr=aWS.ErrorStatus();
+ if (iErr) {
+ continue;
+ }
+ bIsNothingToDo=aWS.IsNothingToDo();
+ if (bIsNothingToDo) {
+ MakeWire(aLE, aW);
+ myNewWES.AddShape (aW);
+ continue;
+ }
+ //
+ const BOPTColStd_ListOfListOfShape& aSSS=aWS.Shapes();
+
+ BOPTColStd_ListIteratorOfListOfListOfShape aWireIt(aSSS);
+ for (; aWireIt.More(); aWireIt.Next()) {
+ const TopTools_ListOfShape& aLEx=aWireIt.Value();
+ //
+ MakeWire(aLEx, aW);
+ myNewWES.AddShape (aW);
+ }
+ }
+}
+//=======================================================================
+// function: MakeWire
+// purpose:
+//=======================================================================
+ void MakeWire(const TopTools_ListOfShape& aLE,
+ TopoDS_Wire& newWire)
+{
+ BRep_Builder aBB;
+ aBB.MakeWire(newWire);
+
+ TopTools_ListIteratorOfListOfShape anIt(aLE);
+ for (; anIt.More(); anIt.Next()){
+ const TopoDS_Edge& aE=TopoDS::Edge(anIt.Value());
+ aBB.Add(newWire, aE);
+ }
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_WESCorrector_HeaderFile
+#define _GEOMAlgo_WESCorrector_HeaderFile
+
+#ifndef _GEOMAlgo_PWireEdgeSet_HeaderFile
+#include <GEOMAlgo_PWireEdgeSet.hxx>
+#endif
+#ifndef _GEOMAlgo_WireEdgeSet_HeaderFile
+#include <GEOMAlgo_WireEdgeSet.hxx>
+#endif
+#ifndef _BOP_ListOfConnexityBlock_HeaderFile
+#include <BOP_ListOfConnexityBlock.hxx>
+#endif
+#ifndef _GEOMAlgo_Algo_HeaderFile
+#include <GEOMAlgo_Algo.hxx>
+#endif
+class GEOMAlgo_WireEdgeSet;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+//! The algorithm to change the Wire Edges Set (WES) contents. <br>
+//! The NewWES will contain only wires instead of wires and edges. <br>
+class GEOMAlgo_WESCorrector : public GEOMAlgo_Algo {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+//! Empty constructor; <br>
+//! <br>
+Standard_EXPORT GEOMAlgo_WESCorrector();
+Standard_EXPORT virtual ~GEOMAlgo_WESCorrector();
+
+
+//! Modifier <br>
+Standard_EXPORT void SetWES(const GEOMAlgo_WireEdgeSet& aWES) ;
+
+
+//! Performs the algorithm that consists of two steps <br>
+//! 1. Make conexity blocks ( DoConnexityBlocks() ) <br>
+//! 2. Make corrections ( DoCorrections() ) <br>
+Standard_EXPORT virtual void Perform() ;
+
+
+//! Selector <br>
+Standard_EXPORT GEOMAlgo_WireEdgeSet& WES() ;
+
+
+//! Selector <br>
+Standard_EXPORT GEOMAlgo_WireEdgeSet& NewWES() ;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+Standard_EXPORT void DoConnexityBlocks() ;
+
+
+Standard_EXPORT void DoCorrections() ;
+
+
+ // Fields PROTECTED
+ //
+GEOMAlgo_PWireEdgeSet myWES;
+GEOMAlgo_WireEdgeSet myNewWES;
+BOP_ListOfConnexityBlock myConnexityBlocks;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_WESCorrector.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_WireEdgeSet_HeaderFile
+#include <GEOMAlgo_WireEdgeSet.hxx>
+#endif
+#ifndef _GEOMAlgo_WESCorrector_HeaderFile
+#include <GEOMAlgo_WESCorrector.hxx>
+#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_WireEdgeSet.cdl
+-- Created:
+-- Author: Peter KURNEV
+-- <pkv@irinox>
+
+
+class WireEdgeSet from GEOMAlgo
+
+ ---Purpose:
+
+uses
+ Face from TopoDS,
+ Shape from TopoDS,
+ ListOfShape from TopTools
+--raises
+
+is
+ Create
+ returns WireEdgeSet from GEOMAlgo;
+
+ Clear(me:out);
+
+ SetFace(me:out;
+ aF:Face from TopoDS);
+
+ Face(me)
+ returns Face from TopoDS;
+ ---C++: return const &
+
+ AddStartElement(me:out;
+ sS: Shape from TopoDS);
+
+ StartElements(me)
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+ AddShape(me:out;
+ sS:Shape from TopoDS);
+
+ Shapes(me)
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+fields
+ myFace : Face from TopoDS is protected;
+ myStartShapes : ListOfShape from TopTools is protected;
+ myShapes : ListOfShape from TopTools is protected;
+
+end WireEdgeSet;
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_WireEdgeSet.cxx
+// Created:
+// Author: Peter KURNEV
+// <pkv@irinox>
+
+#include <GEOMAlgo_WireEdgeSet.ixx>
+
+//=======================================================================
+//function :
+//purpose :
+//=======================================================================
+ GEOMAlgo_WireEdgeSet::GEOMAlgo_WireEdgeSet()
+{
+ Clear();
+}
+
+//=======================================================================
+//function : Clear
+//purpose :
+//=======================================================================
+ void GEOMAlgo_WireEdgeSet::Clear()
+{
+ myStartShapes.Clear();
+ myShapes.Clear();
+}
+//=======================================================================
+//function : SetFace
+//purpose :
+//=======================================================================
+ void GEOMAlgo_WireEdgeSet::SetFace(const TopoDS_Face& aF)
+{
+ myFace=aF;
+}
+//=======================================================================
+//function : Face
+//purpose :
+//=======================================================================
+ const TopoDS_Face& GEOMAlgo_WireEdgeSet::Face()const
+{
+ return myFace;
+}
+//=======================================================================
+//function : AddStartElement
+//purpose :
+//=======================================================================
+ void GEOMAlgo_WireEdgeSet::AddStartElement(const TopoDS_Shape& aE)
+{
+ myStartShapes.Append(aE);
+}
+//=======================================================================
+//function : StartElements
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_WireEdgeSet::StartElements()const
+{
+ return myStartShapes;
+}
+//=======================================================================
+//function : AddShape
+//purpose :
+//=======================================================================
+ void GEOMAlgo_WireEdgeSet::AddShape(const TopoDS_Shape& aW)
+{
+ myShapes.Append(aW);
+}
+//=======================================================================
+//function : Shapes
+//purpose :
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_WireEdgeSet::Shapes()const
+{
+ return myShapes;
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_WireEdgeSet_HeaderFile
+#define _GEOMAlgo_WireEdgeSet_HeaderFile
+
+#ifndef _TopoDS_Face_HeaderFile
+#include <TopoDS_Face.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+class TopoDS_Face;
+class TopoDS_Shape;
+class TopTools_ListOfShape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class GEOMAlgo_WireEdgeSet {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT GEOMAlgo_WireEdgeSet();
+
+
+Standard_EXPORT void Clear() ;
+
+
+Standard_EXPORT void SetFace(const TopoDS_Face& aF) ;
+
+
+Standard_EXPORT const TopoDS_Face& Face() const;
+
+
+Standard_EXPORT void AddStartElement(const TopoDS_Shape& sS) ;
+
+
+Standard_EXPORT const TopTools_ListOfShape& StartElements() const;
+
+
+Standard_EXPORT void AddShape(const TopoDS_Shape& sS) ;
+
+
+Standard_EXPORT const TopTools_ListOfShape& Shapes() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+TopoDS_Face myFace;
+TopTools_ListOfShape myStartShapes;
+TopTools_ListOfShape myShapes;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_WireEdgeSet.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _TopoDS_Face_HeaderFile
+#include <TopoDS_Face.hxx>
+#endif
+#ifndef _TopoDS_Shape_HeaderFile
+#include <TopoDS_Shape.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_WireEdgeSet_HeaderFile
+#include <GEOMAlgo_WireEdgeSet.hxx>
+#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
--- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http:--www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
-- File: GEOMAlgo_WireSolid.cdl
-- Created: Wed Jan 12 10:17:00 2005
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class GEOMAlgo_WireSolid : public GEOMAlgo_ShapeSolid {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT GEOMAlgo_WireSolid();
Standard_EXPORT virtual ~GEOMAlgo_WireSolid();
+
+
Standard_EXPORT virtual void Perform() ;
// Methods PROTECTED
//
+
+
Standard_EXPORT virtual void Prepare() ;
+
+
Standard_EXPORT virtual void BuildResult() ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _GEOMAlgo_WireSolid_HeaderFile
#include <GEOMAlgo_WireSolid.hxx>
#endif
--- /dev/null
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: GEOMAlgo_WireSplitter.cdl
+-- Created:
+-- Author: Peter KURNEV
+-- <pkv@irinox>
+
+
+class WireSplitter from GEOMAlgo
+ inherits Algo from GEOMAlgo
+
+ ---Purpose:
+ --- the algorithm to split multiconnexed set of edges
+ --- wires on a face onto simple connexed wires
+ --- .
+uses
+ Face from TopoDS,
+ Vertex from TopoDS,
+ Edge from TopoDS,
+
+ SequenceOfPnt2d from TColgp,
+ SequenceOfShape from TopTools,
+ ListOfShape from TopTools,
+
+ ListOfListOfShape from BOPTColStd,
+
+ EdgeInfo from BOP,
+ IndexedDataMapOfVertexListEdgeInfo from BOP
+
+--raises
+
+is
+ Create
+ returns WireSplitter from GEOMAlgo;
+ ---C++: alias "Standard_EXPORT virtual ~GEOMAlgo_WireSplitter();"
+
+ SetFace (me:out;
+ aF: Face from TopoDS);
+
+ SetEdges (me:out;
+ aLE:ListOfShape from TopTools);
+
+ Edges (me)
+ returns ListOfShape from TopTools;
+ ---C++: return const &
+
+ Perform (me:out)
+ is redefined;
+
+ IsNothingToDo (me)
+ returns Boolean from Standard;
+
+ Face (me)
+ returns Face from TopoDS;
+ ---C++: return const &
+
+ Shapes (me)
+ returns ListOfListOfShape from BOPTColStd;
+ ---C++: return const &
+
+fields
+ myFace : Face from TopoDS is protected;
+ myIsDone : Boolean from Standard is protected;
+ myNothingToDo: Boolean from Standard is protected;
+ myShapes : ListOfListOfShape from BOPTColStd is protected;
+ mySmartMap : IndexedDataMapOfVertexListEdgeInfo from BOP is protected;
+ myEdges : ListOfShape from TopTools is protected;
+
+end WireSplitter;
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: GEOMAlgo_WireSplitter.cxx
+// Created:
+// Author: Peter KURNEV
+// <pkv@irinox>
+
+
+#include <GEOMAlgo_WireSplitter.ixx>
+
+#include <TColStd_SequenceOfReal.hxx>
+#include <Precision.hxx>
+
+#include <gp_Pnt2d.hxx>
+#include <gp_Vec2d.hxx>
+#include <TColgp_SequenceOfPnt2d.hxx>
+
+#include <Geom_Curve.hxx>
+#include <Geom2d_Curve.hxx>
+#include <GeomAdaptor_Surface.hxx>
+
+#include <TopAbs_Orientation.hxx>
+
+#include <TopoDS.hxx>
+#include <TopoDS_Vertex.hxx>
+#include <TopoDS_Edge.hxx>
+#include <TopoDS_Face.hxx>
+#include <TopoDS_Iterator.hxx>
+
+
+#include <BRep_Tool.hxx>
+#include <BRepAdaptor_Surface.hxx>
+#include <BRepAdaptor_Curve2d.hxx>
+
+#include <TopExp.hxx>
+#include <TopExp_Explorer.hxx>
+
+
+
+#include <TopTools_SequenceOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+
+#include <BOPTColStd_ListOfListOfShape.hxx>
+#include <BOPTColStd_ListIteratorOfListOfListOfShape.hxx>
+
+#include <BOPTools_Tools2D.hxx>
+
+#include <BOP_EdgeInfo.hxx>
+#include <BOP_ListOfEdgeInfo.hxx>
+#include <BOP_ListIteratorOfListOfEdgeInfo.hxx>
+#include <BOP_IndexedDataMapOfVertexListEdgeInfo.hxx>
+
+static
+ void Path (const GeomAdaptor_Surface& aGAS,
+ const TopoDS_Face& myFace,
+ const TopoDS_Vertex& aVa,
+ const TopoDS_Edge& aEOuta,
+ BOP_EdgeInfo& anEdgeInfo,
+ TopTools_SequenceOfShape& aLS,
+ TopTools_SequenceOfShape& aVertVa,
+ TColgp_SequenceOfPnt2d& aCoordVa,
+ BOPTColStd_ListOfListOfShape& myShapes,
+ BOP_IndexedDataMapOfVertexListEdgeInfo& mySmartMap);
+
+
+static
+ Standard_Real Angle (const gp_Dir2d& aDir2D);
+
+
+static
+ void GetNextVertex(const TopoDS_Vertex& aV,
+ const TopoDS_Edge& aE,
+ TopoDS_Vertex& aV1);
+static
+ Standard_Real ClockWiseAngle(const Standard_Real aAngleIn,
+ const Standard_Real aAngleOut);
+
+static
+ Standard_Real AngleIn(const TopoDS_Edge& aEIn,
+ const BOP_ListOfEdgeInfo& aLEInfo);
+
+static
+ Standard_Real Angle2D (const TopoDS_Vertex& aV,
+ const TopoDS_Edge& anEdge,
+ const TopoDS_Face& myFace,
+ const GeomAdaptor_Surface& aGAS,
+ const Standard_Boolean aFlag);
+static
+ gp_Pnt2d Coord2d (const TopoDS_Vertex& aV1,
+ const TopoDS_Edge& aE1,
+ const TopoDS_Face& aF);
+static
+ gp_Pnt2d Coord2dVf (const TopoDS_Edge& aE,
+ const TopoDS_Face& aF);
+static
+ Standard_Real Tolerance2D (const TopoDS_Vertex& aV,
+ const GeomAdaptor_Surface& aGAS);
+
+static
+ void UVTolerance2D (const TopoDS_Vertex& aV,
+ const GeomAdaptor_Surface& aGAS,
+ Standard_Real& aTolU,
+ Standard_Real& aTolV);
+static
+ Standard_Integer NbWaysOut(const BOP_ListOfEdgeInfo& );
+//
+
+//=======================================================================
+// function:
+// purpose:
+//=======================================================================
+ GEOMAlgo_WireSplitter::GEOMAlgo_WireSplitter()
+:
+ GEOMAlgo_Algo(),
+ myNothingToDo(Standard_False)
+{
+}
+//=======================================================================
+// function: ~
+// purpose:
+//=======================================================================
+ GEOMAlgo_WireSplitter::~GEOMAlgo_WireSplitter()
+{
+}
+//=======================================================================
+// function: SetFace
+// purpose:
+//=======================================================================
+ void GEOMAlgo_WireSplitter::SetFace(const TopoDS_Face& aFace)
+{
+ myFace=aFace;
+}
+//=======================================================================
+// function: Face
+// purpose:
+//=======================================================================
+ const TopoDS_Face& GEOMAlgo_WireSplitter::Face()const
+{
+ return myFace;
+}
+//=======================================================================
+// function: SetEdges
+// purpose:
+//=======================================================================
+ void GEOMAlgo_WireSplitter::SetEdges(const TopTools_ListOfShape& aLE)
+{
+ TopTools_ListIteratorOfListOfShape anIt;
+ //
+ myEdges.Clear();
+ anIt.Initialize(aLE);
+ for (; anIt.More(); anIt.Next()) {
+ const TopoDS_Shape& aE =anIt.Value();
+ //
+ if (aE.Orientation()==TopAbs_INTERNAL){
+ continue;
+ }
+ //
+ myEdges.Append(aE);
+ }
+}
+//=======================================================================
+// function: Edges
+// purpose:
+//=======================================================================
+ const TopTools_ListOfShape& GEOMAlgo_WireSplitter::Edges()const
+{
+ return myEdges;
+}
+//=======================================================================
+// function: IsNothingToDo
+// purpose:
+//=======================================================================
+ Standard_Boolean GEOMAlgo_WireSplitter::IsNothingToDo()const
+{
+ return myNothingToDo;
+}
+//=======================================================================
+// function: Shapes
+// purpose:
+//=======================================================================
+ const BOPTColStd_ListOfListOfShape& GEOMAlgo_WireSplitter::Shapes()const
+{
+ return myShapes;
+}
+//=======================================================================
+// function: Perform
+// purpose:
+//=======================================================================
+ void GEOMAlgo_WireSplitter::Perform()
+{
+ myErrorStatus=2;
+ myNothingToDo=Standard_True;
+
+ Standard_Integer index, i, aNb, aCntIn, aCntOut;
+ Standard_Boolean anIsIn;
+ Standard_Real anAngle;
+
+ BOP_ListOfEdgeInfo emptyInfo;
+ TopTools_ListIteratorOfListOfShape anItList;
+ //
+ // 1.Filling mySmartMap
+ mySmartMap.Clear();
+
+ anItList.Initialize(myEdges);
+ for (; anItList.More(); anItList.Next()) {
+ const TopoDS_Edge& anEdge = TopoDS::Edge(anItList.Value());
+ //
+ if (!BOPTools_Tools2D::HasCurveOnSurface (anEdge, myFace)) {
+ continue;
+ }
+ //
+ TopExp_Explorer anExpVerts (anEdge, TopAbs_VERTEX);
+ for (; anExpVerts.More(); anExpVerts.Next()) {
+ const TopoDS_Shape& aVertex= anExpVerts.Current();
+
+ index = mySmartMap.FindIndex(aVertex);
+ if (!index) {
+ index=mySmartMap.Add(aVertex, emptyInfo);
+ }
+
+ BOP_ListOfEdgeInfo& aListOfEInfo=mySmartMap(index);
+
+ BOP_EdgeInfo aEInfo;
+ aEInfo.SetEdge(anEdge);
+
+ TopAbs_Orientation anOr=aVertex.Orientation();
+
+ if (anOr==TopAbs_FORWARD) {
+ aEInfo.SetInFlag(Standard_False);
+ }
+
+ else if (anOr==TopAbs_REVERSED) {
+ aEInfo.SetInFlag(Standard_True);
+ }
+
+ aListOfEInfo.Append(aEInfo);
+ }
+ }
+ //
+ aNb=mySmartMap.Extent();
+ //
+ // 2. myNothingToDo
+ myNothingToDo=Standard_True;
+
+ for (i=1; i<=aNb; i++) {
+ aCntIn=0;
+ aCntOut=0;
+ const BOP_ListOfEdgeInfo& aLEInfo= mySmartMap(i);
+ BOP_ListIteratorOfListOfEdgeInfo anIt(aLEInfo);
+ for (; anIt.More(); anIt.Next()) {
+ const BOP_EdgeInfo& anEdgeInfo=anIt.Value();
+ anIsIn=anEdgeInfo.IsIn();
+ if (anIsIn) {
+ aCntIn++;
+ }
+ else {
+ aCntOut++;
+ }
+ }
+ if (aCntIn!=1 || aCntOut!=1) {
+ myNothingToDo=Standard_False;
+ break;
+ }
+ }
+ //
+ // Each vertex has one edge In and one - Out. Good. But it is not enought
+ // to consider that nothing to do with this. We must check edges on TShape
+ // coinsidence. If there are such edges there is something to do with.
+ //
+ if (myNothingToDo) {
+ Standard_Integer aNbE, aNbMapEE;
+ TopTools_IndexedDataMapOfShapeListOfShape aMapEE;
+ aNbE=myEdges.Extent();
+
+ anItList.Initialize(myEdges);
+ for (; anItList.More(); anItList.Next()) {
+ const TopoDS_Shape& aE = anItList.Value();
+
+ if (!aMapEE.Contains(aE)) {
+ TopTools_ListOfShape aLEx;
+ aLEx.Append(aE);
+ aMapEE.Add(aE, aLEx);
+ }
+ else {
+ TopTools_ListOfShape& aLEx=aMapEE.ChangeFromKey(aE);
+ aLEx.Append(aE);
+ }
+ }
+
+ Standard_Boolean bFlag;
+ bFlag=Standard_True;
+ aNbMapEE=aMapEE.Extent();
+ for (i=1; i<=aNbMapEE; i++) {
+ const TopTools_ListOfShape& aLEx=aMapEE(i);
+ aNbE=aLEx.Extent();
+ if (aNbE==1) {
+ // usual case
+ continue;
+ }
+ else if (aNbE==2){
+ const TopoDS_Shape& aE1=aLEx.First();
+ const TopoDS_Shape& aE2=aLEx.Last();
+ if (aE1.IsSame(aE2)) {
+ bFlag=Standard_False;
+ break;
+ }
+ }
+ else {
+ bFlag=Standard_False;
+ break;
+ }
+ }
+ myNothingToDo=myNothingToDo && bFlag;
+ }
+ //
+ //
+ if (myNothingToDo) {
+ myErrorStatus=0;
+ return;
+ }
+ //
+ // 3. Angles in mySmartMap
+ BRepAdaptor_Surface aBAS(myFace);
+ const GeomAdaptor_Surface& aGAS=aBAS.Surface();
+ for (i=1; i<=aNb; i++) {
+ const TopoDS_Vertex& aV=TopoDS::Vertex (mySmartMap.FindKey(i));
+ const BOP_ListOfEdgeInfo& aLEInfo= mySmartMap(i);
+
+ BOP_ListIteratorOfListOfEdgeInfo anIt(aLEInfo);
+ for (; anIt.More(); anIt.Next()) {
+ BOP_EdgeInfo& anEdgeInfo=anIt.Value();
+ const TopoDS_Edge& aE=anEdgeInfo.Edge();
+ //
+ TopoDS_Vertex aVV=aV;
+ //
+ anIsIn=anEdgeInfo.IsIn();
+ if (anIsIn) {
+ //
+ aVV.Orientation(TopAbs_REVERSED);
+ anAngle=Angle2D (aVV, aE, myFace, aGAS, Standard_True);
+ }
+ //
+ else { // OUT
+ //
+ aVV.Orientation(TopAbs_FORWARD);
+ anAngle=Angle2D (aVV, aE, myFace, aGAS, Standard_False);
+ }
+ anEdgeInfo.SetAngle(anAngle);
+
+ }
+ }
+ //
+ // 4. Do
+ //
+ Standard_Boolean anIsOut, anIsNotPassed;
+
+ TopTools_SequenceOfShape aLS, aVertVa;
+ TColgp_SequenceOfPnt2d aCoordVa;
+
+ BOP_ListIteratorOfListOfEdgeInfo anIt;
+
+ for (i=1; i<=aNb; i++) {
+ const TopoDS_Vertex aVa=TopoDS::Vertex (mySmartMap.FindKey(i));
+ const BOP_ListOfEdgeInfo& aLEInfo=mySmartMap(i);
+
+ anIt.Initialize(aLEInfo);
+ for (; anIt.More(); anIt.Next()) {
+ BOP_EdgeInfo& anEdgeInfo=anIt.Value();
+ const TopoDS_Edge& aEOuta=anEdgeInfo.Edge();
+
+ anIsOut=!anEdgeInfo.IsIn();
+ anIsNotPassed=!anEdgeInfo.Passed();
+
+ if (anIsOut && anIsNotPassed) {
+ //
+ aLS.Clear();
+ aVertVa.Clear();
+ aCoordVa.Clear();
+ //
+ Path(aGAS, myFace, aVa, aEOuta, anEdgeInfo, aLS,
+ aVertVa, aCoordVa, myShapes, mySmartMap);
+ }
+ }
+ }
+ //
+ {
+ Standard_Integer aNbV, aNbE;
+ TopoDS_Vertex aV1, aV2;
+ BOPTColStd_ListOfListOfShape aShapes;
+ BOPTColStd_ListIteratorOfListOfListOfShape anItW(myShapes);
+
+ for (; anItW.More(); anItW.Next()) {
+ TopTools_IndexedMapOfShape aMV, aME;
+ const TopTools_ListOfShape& aLE=anItW.Value();
+ TopTools_ListIteratorOfListOfShape anItE(aLE);
+ for (; anItE.More(); anItE.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(anItE.Value());
+ aME.Add(aE);
+ TopExp::Vertices(aE, aV1, aV2);
+ aMV.Add(aV1);
+ aMV.Add(aV2);
+ }
+ aNbV=aMV.Extent();
+ aNbE=aME.Extent();
+ if (aNbV<=aNbE) {
+ aShapes.Append(aLE);
+ }
+ }
+ //
+ myShapes.Clear();
+ anItW.Initialize(aShapes);
+ for (; anItW.More(); anItW.Next()) {
+ const TopTools_ListOfShape& aLE=anItW.Value();
+ myShapes.Append(aLE);
+ }
+ }
+ //
+ myErrorStatus=0;
+}
+//=======================================================================
+// function: Path
+// purpose:
+//=======================================================================
+ void Path (const GeomAdaptor_Surface& aGAS,
+ const TopoDS_Face& myFace,
+ const TopoDS_Vertex& aVa,
+ const TopoDS_Edge& aEOuta,
+ BOP_EdgeInfo& anEdgeInfo,
+ TopTools_SequenceOfShape& aLS,
+ TopTools_SequenceOfShape& aVertVa,
+ TColgp_SequenceOfPnt2d& aCoordVa,
+ BOPTColStd_ListOfListOfShape& myShapes,
+ BOP_IndexedDataMapOfVertexListEdgeInfo& mySmartMap)
+
+{
+ Standard_Integer i,j, aNb, aNbj;
+ Standard_Real aTol, anAngleIn, anAngleOut, anAngle, aMinAngle;
+ Standard_Real aTol2D, aTol2D2;
+ Standard_Real aTol2, aD2, aTolUVb, aTolVVb;
+ Standard_Boolean anIsSameV2d, anIsSameV, anIsFound, anIsOut, anIsNotPassed;
+ BOP_ListIteratorOfListOfEdgeInfo anIt;
+ TopoDS_Vertex aVb;
+ TopoDS_Edge aEOutb;
+ //
+ aTol=1.e-7;
+ //
+ // append block
+ //
+ // Do not escape through edge from which you enter
+ aNb=aLS.Length();
+ if (aNb==1) {
+ const TopoDS_Shape& anEPrev=aLS(aNb);
+ if (anEPrev.IsSame(aEOuta)) {
+ return;
+ }
+ }
+ //
+ //
+ anEdgeInfo.SetPassed(Standard_True);
+ aLS.Append(aEOuta);
+ aVertVa.Append(aVa);
+
+ TopoDS_Vertex pVa=aVa;
+ pVa.Orientation(TopAbs_FORWARD);
+ gp_Pnt2d aPa=Coord2d(pVa, aEOuta, myFace);
+ aCoordVa.Append(aPa);
+
+ GetNextVertex (pVa, aEOuta, aVb);
+
+ gp_Pnt2d aPb=Coord2d(aVb, aEOuta, myFace);
+
+ const BOP_ListOfEdgeInfo& aLEInfoVb=mySmartMap.FindFromKey(aVb);
+ //
+ aTol=2.*Tolerance2D(aVb, aGAS);
+ aTol2=aTol*aTol;
+ //
+ UVTolerance2D(aVb, aGAS, aTolUVb, aTolVVb);
+ aTolUVb = 2.*aTolUVb;
+ aTolVVb = 2.*aTolVVb;
+ //
+ aNb=aLS.Length();
+ if (aNb>0) {
+ //
+ TopTools_ListOfShape aBuf;
+ //
+ for (i=aNb; i>0; i--) {
+ const TopoDS_Shape& aVPrev=aVertVa(i);
+ const gp_Pnt2d& aPaPrev=aCoordVa(i);
+ const TopoDS_Shape& aEPrev=aLS(i);
+
+ aBuf.Append(aEPrev);
+
+ anIsSameV=aVPrev.IsSame(aVb);
+ anIsSameV2d = Standard_False;
+
+ if (anIsSameV) {
+ anIsSameV2d = Standard_True;
+ //
+ aD2=aPaPrev.SquareDistance(aPb);
+ anIsSameV2d =aD2<aTol2;
+ //
+ if(anIsSameV2d) {
+ Standard_Real udist, vdist;
+ //
+ udist=fabs(aPaPrev.X() - aPb.X());
+ vdist=fabs(aPaPrev.Y() - aPb.Y());
+ if((udist > aTolUVb) || (vdist > aTolVVb)) {
+ anIsSameV2d=!anIsSameV2d;
+ }
+ }
+ }//if (anIsSameV) {
+ //
+ if (anIsSameV && anIsSameV2d) {
+ myShapes.Append(aBuf);
+ //
+ TopTools_SequenceOfShape aLSt, aVertVat;
+ TColgp_SequenceOfPnt2d aCoordVat;
+ //
+ aNbj=i-1;
+ if (aNbj<1) {
+ //
+ aLS.Clear();
+ aVertVa.Clear();
+ aCoordVa.Clear();
+ //
+ return;
+ }
+
+ aVb=TopoDS::Vertex(aVertVa(i));
+
+ for (j=1; j<=aNbj; j++) {
+ aLSt.Append(aLS(j));
+ aVertVat.Append(aVertVa(j));
+ aCoordVat.Append(aCoordVa(j));
+ }
+ //
+ aLS.Clear();
+ aVertVa.Clear();
+ aCoordVa.Clear();
+
+ aLS=aLSt;
+ aVertVa=aVertVat;
+ aCoordVa=aCoordVat;
+ //
+ break;
+ }
+ }
+ }
+ //
+ aTol2D=2.*Tolerance2D(aVb, aGAS);
+ aTol2D2=aTol2D*aTol2D;
+ //
+ // anAngleIn in Vb from edge aEOuta
+ const BOP_ListOfEdgeInfo& aLEInfo=mySmartMap.FindFromKey(aVb);
+ //
+ anAngleIn=AngleIn(aEOuta, aLEInfo);
+ //
+ // aEOutb
+ BOP_EdgeInfo *pEdgeInfo=NULL;
+
+ aMinAngle=100.;
+ anIsFound=Standard_False;
+
+ Standard_Integer aCurIndexE = 0;
+
+ anIt.Initialize(aLEInfo);
+ for (; anIt.More(); anIt.Next()) {
+ BOP_EdgeInfo& anEI=anIt.Value();
+ const TopoDS_Edge& aE=anEI.Edge();
+ anIsOut=!anEI.IsIn();
+ anIsNotPassed=!anEI.Passed();
+
+ if (anIsOut && anIsNotPassed) {
+ aCurIndexE++;
+ //
+ // Is there one way to go out of the vertex
+ // we have to use it only.
+ Standard_Integer iCnt;
+ iCnt=NbWaysOut (aLEInfo);
+ //
+ if (!iCnt) {
+ // no way to go . (Error)
+ return ;
+ }
+ //
+ if (iCnt==1) {
+ // the one and only way to go out .
+ pEdgeInfo=&anEI;
+ anIsFound=Standard_True;
+ break;
+ }
+ //
+ // Look for minimal angle and make the choice.
+ gp_Pnt2d aP2Dx;
+ //
+ aP2Dx=Coord2dVf(aE, myFace);
+ //
+ aD2=aP2Dx.SquareDistance(aPb);
+ if (aD2 > aTol2D2){
+ continue;
+ }
+ //
+ //
+ anAngleOut=anEI.Angle();
+ //
+ anAngle=ClockWiseAngle(anAngleIn, anAngleOut);
+ if (anAngle < aMinAngle) {
+ aMinAngle=anAngle;
+ pEdgeInfo=&anEI;
+ anIsFound=Standard_True;
+ }
+ }
+ } // for (; anIt.More(); anIt.Next())
+ //
+ if (!anIsFound) {
+ // no way to go . (Error)
+ return;
+ }
+
+ aEOutb=pEdgeInfo->Edge();
+ //
+ Path (aGAS, myFace, aVb, aEOutb, *pEdgeInfo, aLS,
+ aVertVa, aCoordVa, myShapes, mySmartMap);
+}
+//=======================================================================
+// function: Coord2dVf
+// purpose:
+//=======================================================================
+ gp_Pnt2d Coord2dVf (const TopoDS_Edge& aE,
+ const TopoDS_Face& aF)
+{
+ Standard_Real aCoord=99.;
+ gp_Pnt2d aP2D1(aCoord, aCoord);
+ TopoDS_Iterator aIt;
+ //
+ aIt.Initialize(aE);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aVx=aIt.Value();
+ if (aVx.Orientation()==TopAbs_FORWARD) {
+ const TopoDS_Vertex& aVxx=TopoDS::Vertex(aVx);
+ aP2D1=Coord2d(aVxx, aE, aF);
+ return aP2D1;
+ }
+ }
+ return aP2D1;
+}
+//=======================================================================
+// function: Tolerance2D
+// purpose:
+//=======================================================================
+ Standard_Real Tolerance2D (const TopoDS_Vertex& aV,
+ const GeomAdaptor_Surface& aGAS)
+{
+ Standard_Real aTol2D, anUr, aVr, aTolV3D;
+ GeomAbs_SurfaceType aType;
+ //
+ aType=aGAS.GetType();
+ aTolV3D=BRep_Tool::Tolerance(aV);
+
+ anUr=aGAS.UResolution(aTolV3D);
+ aVr =aGAS.VResolution(aTolV3D);
+ aTol2D=(aVr>anUr) ? aVr : anUr;
+ //
+ if (aType==GeomAbs_BSplineSurface||
+ aType==GeomAbs_Sphere) {
+ if (aTol2D < aTolV3D) {
+ aTol2D=aTolV3D;
+ }
+ }
+ if (aType==GeomAbs_BSplineSurface) {
+ aTol2D=1.1*aTol2D;
+ }
+ //
+ return aTol2D;
+}
+
+//=======================================================================
+// function: Coord2d
+// purpose:
+//=======================================================================
+ gp_Pnt2d Coord2d (const TopoDS_Vertex& aV1,
+ const TopoDS_Edge& aE1,
+ const TopoDS_Face& aF)
+{
+ Standard_Real aT, aFirst, aLast;
+ Handle(Geom2d_Curve) aC2D;
+ gp_Pnt2d aP2D1;
+ //
+ aT=BRep_Tool::Parameter (aV1, aE1, aF);
+ aC2D=BRep_Tool::CurveOnSurface(aE1, aF, aFirst, aLast);
+ aC2D->D0 (aT, aP2D1);
+ //
+ return aP2D1;
+}
+//=======================================================================
+// function: AngleIn
+// purpose:
+//=======================================================================
+ Standard_Real AngleIn(const TopoDS_Edge& aEIn,
+ const BOP_ListOfEdgeInfo& aLEInfo)
+{
+ Standard_Real anAngleIn;
+ Standard_Boolean anIsIn;
+ BOP_ListIteratorOfListOfEdgeInfo anIt;
+
+ anIt.Initialize(aLEInfo);
+ for (; anIt.More(); anIt.Next()) {
+ BOP_EdgeInfo& anEdgeInfo=anIt.Value();
+ const TopoDS_Edge& aE=anEdgeInfo.Edge();
+ anIsIn=anEdgeInfo.IsIn();
+ //
+ if (anIsIn && aE==aEIn) {
+ anAngleIn=anEdgeInfo.Angle();
+ return anAngleIn;
+ }
+ }
+ anAngleIn=0.;
+ return anAngleIn;
+}
+//=======================================================================
+// function: ClockWiseAngle
+// purpose:
+//=======================================================================
+ Standard_Real ClockWiseAngle(const Standard_Real aAngleIn,
+ const Standard_Real aAngleOut)
+{
+ Standard_Real aTwoPi=Standard_PI+Standard_PI;
+ Standard_Real dA, A1, A2, AIn, AOut ;
+
+ AIn=aAngleIn;
+ AOut=aAngleOut;
+ if (AIn >= aTwoPi) {
+ AIn=AIn-aTwoPi;
+ }
+
+ if (AOut >= aTwoPi) {
+ AOut=AOut-aTwoPi;
+ }
+
+ A1=AIn+Standard_PI;
+
+ if (A1 >= aTwoPi) {
+ A1=A1-aTwoPi;
+ }
+
+ A2=AOut;
+
+ dA=A1-A2;
+ if (dA <= 0.) {
+ dA=aTwoPi+dA;
+ }
+ //xx
+ //else if (dA <= 1.e-15) {
+ else if (dA <= 1.e-14) {
+ dA=aTwoPi;
+ }
+ return dA;
+}
+//=======================================================================
+// function: GetNextVertex
+// purpose:
+//=======================================================================
+ void GetNextVertex(const TopoDS_Vertex& aV,
+ const TopoDS_Edge& aE,
+ TopoDS_Vertex& aV1)
+{
+ TopoDS_Iterator aIt;
+ //
+ aIt.Initialize(aE);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aVx=aIt.Value();
+ if (!aVx.IsEqual(aV)) {
+ aV1=TopoDS::Vertex(aVx);
+ return ;
+ }
+ }
+ aV1=aV;
+}
+//=======================================================================
+// function: Angle2D
+// purpose:
+//=======================================================================
+ Standard_Real Angle2D (const TopoDS_Vertex& aV,
+ const TopoDS_Edge& anEdge,
+ const TopoDS_Face& myFace,
+ const GeomAdaptor_Surface& aGAS,
+ const Standard_Boolean aFlag)
+{
+ Standard_Real aFirst, aLast, aToler, dt, aTV, aTV1, anAngle;
+
+ Handle(Geom2d_Curve) aC2D;
+
+ BOPTools_Tools2D::CurveOnSurface (anEdge, myFace, aC2D,
+ aFirst, aLast, aToler, Standard_True);
+
+ aTV=BRep_Tool::Parameter (aV, anEdge, myFace);
+ if (Precision::IsInfinite(aTV))
+ return 0.;
+
+ //dt=1.e-7;
+ dt=Tolerance2D(aV, aGAS);
+
+ if(dt > (aLast - aFirst) * 0.25) {
+ // to save direction of the curve as much as it possible
+ // in the case of big tolerances
+ dt = (aLast - aFirst) * 0.25;
+ }
+ //
+ if (fabs (aTV-aFirst) < fabs(aTV - aLast)) {
+ aTV1=aTV + dt;
+ }
+ else {
+ aTV1=aTV - dt;
+ }
+
+ gp_Pnt2d aPV, aPV1;
+ aC2D->D0 (aTV, aPV);
+ aC2D->D0 (aTV1, aPV1);
+
+ gp_Vec2d aV2D;
+ //
+ if (aFlag) {//IN
+ gp_Vec2d aV2DIn(aPV1, aPV);
+ //
+ aV2D=aV2DIn;
+ }
+
+ else {
+ gp_Vec2d aV2DOut(aPV, aPV1);
+ aV2D=aV2DOut;
+ }
+
+ gp_Dir2d aDir2D(aV2D);
+ anAngle=Angle(aDir2D);
+
+ return anAngle;
+}
+//=======================================================================
+// function: Angle
+// purpose:
+//=======================================================================
+Standard_Real Angle (const gp_Dir2d& aDir2D)
+{
+ gp_Dir2d aRefDir(1., 0.);
+ Standard_Real anAngle = aRefDir.Angle(aDir2D);
+
+ if (anAngle < 0.)
+ anAngle += Standard_PI + Standard_PI;
+
+ return anAngle;
+}
+//
+//=======================================================================
+// function: NbWaysOut
+// purpose:
+//=======================================================================
+Standard_Integer NbWaysOut(const BOP_ListOfEdgeInfo& aLEInfo)
+{
+ Standard_Boolean bIsOut, bIsNotPassed;
+ Standard_Integer iCnt=0;
+ BOP_ListIteratorOfListOfEdgeInfo anIt;
+ //
+ anIt.Initialize(aLEInfo);
+ for (; anIt.More(); anIt.Next()) {
+ BOP_EdgeInfo& anEI=anIt.Value();
+ //
+ bIsOut=!anEI.IsIn();
+ bIsNotPassed=!anEI.Passed();
+ if (bIsOut && bIsNotPassed) {
+ iCnt++;
+ }
+ }
+ return iCnt;
+}
+//=======================================================================
+//function : UVTolerance2D
+//purpose :
+//=======================================================================
+void UVTolerance2D (const TopoDS_Vertex& aV,
+ const GeomAdaptor_Surface& aGAS,
+ Standard_Real& aTolU,
+ Standard_Real& aTolV)
+{
+ Standard_Real aTolV3D;
+ //
+ aTolV3D = BRep_Tool::Tolerance(aV);
+ aTolU=aGAS.UResolution(aTolV3D);
+ aTolV=aGAS.VResolution(aTolV3D);
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _GEOMAlgo_WireSplitter_HeaderFile
+#define _GEOMAlgo_WireSplitter_HeaderFile
+
+#ifndef _TopoDS_Face_HeaderFile
+#include <TopoDS_Face.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+#ifndef _BOPTColStd_ListOfListOfShape_HeaderFile
+#include <BOPTColStd_ListOfListOfShape.hxx>
+#endif
+#ifndef _BOP_IndexedDataMapOfVertexListEdgeInfo_HeaderFile
+#include <BOP_IndexedDataMapOfVertexListEdgeInfo.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_Algo_HeaderFile
+#include <GEOMAlgo_Algo.hxx>
+#endif
+class TopoDS_Face;
+class TopTools_ListOfShape;
+class BOPTColStd_ListOfListOfShape;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+//! the algorithm to split multiconnexed set of edges <br>
+//! wires on a face onto simple connexed wires <br>
+//! . <br>
+class GEOMAlgo_WireSplitter : public GEOMAlgo_Algo {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT GEOMAlgo_WireSplitter();
+Standard_EXPORT virtual ~GEOMAlgo_WireSplitter();
+
+
+Standard_EXPORT void SetFace(const TopoDS_Face& aF) ;
+
+
+Standard_EXPORT void SetEdges(const TopTools_ListOfShape& aLE) ;
+
+
+Standard_EXPORT const TopTools_ListOfShape& Edges() const;
+
+
+Standard_EXPORT virtual void Perform() ;
+
+
+Standard_EXPORT Standard_Boolean IsNothingToDo() const;
+
+
+Standard_EXPORT const TopoDS_Face& Face() const;
+
+
+Standard_EXPORT const BOPTColStd_ListOfListOfShape& Shapes() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+TopoDS_Face myFace;
+Standard_Boolean myIsDone;
+Standard_Boolean myNothingToDo;
+BOPTColStd_ListOfListOfShape myShapes;
+BOP_IndexedDataMapOfVertexListEdgeInfo mySmartMap;
+TopTools_ListOfShape myEdges;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <GEOMAlgo_WireSplitter.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _TopoDS_Face_HeaderFile
+#include <TopoDS_Face.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _BOPTColStd_ListOfListOfShape_HeaderFile
+#include <BOPTColStd_ListOfListOfShape.hxx>
+#endif
+#ifndef _GEOMAlgo_WireSplitter_HeaderFile
+#include <GEOMAlgo_WireSplitter.hxx>
+#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger)():Handle(TCollection_MapNode)() {}
Handle(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger)(const Handle(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger* operator->()
- {
- return (GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger *)ControlAccess();
- }
-
- GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger* operator->() const
+ GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger* operator->() const
{
return (GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger *)ControlAccess();
}
- Standard_EXPORT ~Handle(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger)();
+// Standard_EXPORT ~Handle(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger)();
Standard_EXPORT static const Handle(GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger) DownCast(const Handle(Standard_Transient)& AnObject);
};
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_HeaderFile
+#define _Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_HeaderFile
+
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+
+#ifndef _Handle_TCollection_MapNode_HeaderFile
+#include <Handle_TCollection_MapNode.hxx>
+#endif
+
+class Standard_Transient;
+class Handle_Standard_Type;
+class Handle(TCollection_MapNode);
+class GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape;
+Standard_EXPORT Handle_Standard_Type& STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape);
+
+class Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape) : public Handle(TCollection_MapNode) {
+ public:
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)():Handle(TCollection_MapNode)() {}
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)(const Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)& aHandle) : Handle(TCollection_MapNode)(aHandle)
+ {
+ }
+
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)(const GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape* anItem) : Handle(TCollection_MapNode)((TCollection_MapNode *)anItem)
+ {
+ }
+
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)& operator=(const Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)& aHandle)
+ {
+ Assign(aHandle.Access());
+ return *this;
+ }
+
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)& operator=(const GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape* anItem)
+ {
+ Assign((Standard_Transient *)anItem);
+ return *this;
+ }
+
+ GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape* operator->() const
+ {
+ return (GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape *)ControlAccess();
+ }
+
+// Standard_EXPORT ~Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape)();
+
+ Standard_EXPORT static const Handle(GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape) DownCast(const Handle(Standard_Transient)& AnObject);
+};
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_HeaderFile
+#define _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_HeaderFile
+
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+
+#ifndef _Handle_TCollection_MapNode_HeaderFile
+#include <Handle_TCollection_MapNode.hxx>
+#endif
+
+class Standard_Transient;
+class Handle_Standard_Type;
+class Handle(TCollection_MapNode);
+class GEOMAlgo_DataMapNodeOfDataMapOfShapeReal;
+Standard_EXPORT Handle_Standard_Type& STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal);
+
+class Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal) : public Handle(TCollection_MapNode) {
+ public:
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)():Handle(TCollection_MapNode)() {}
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)(const Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)& aHandle) : Handle(TCollection_MapNode)(aHandle)
+ {
+ }
+
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)(const GEOMAlgo_DataMapNodeOfDataMapOfShapeReal* anItem) : Handle(TCollection_MapNode)((TCollection_MapNode *)anItem)
+ {
+ }
+
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)& operator=(const Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)& aHandle)
+ {
+ Assign(aHandle.Access());
+ return *this;
+ }
+
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)& operator=(const GEOMAlgo_DataMapNodeOfDataMapOfShapeReal* anItem)
+ {
+ Assign((Standard_Transient *)anItem);
+ return *this;
+ }
+
+ GEOMAlgo_DataMapNodeOfDataMapOfShapeReal* operator->() const
+ {
+ return (GEOMAlgo_DataMapNodeOfDataMapOfShapeReal *)ControlAccess();
+ }
+
+// Standard_EXPORT ~Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal)();
+
+ Standard_EXPORT static const Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeReal) DownCast(const Handle(Standard_Transient)& AnObject);
+};
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_HeaderFile
+#define _Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_HeaderFile
+
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+
+#ifndef _Handle_TCollection_MapNode_HeaderFile
+#include <Handle_TCollection_MapNode.hxx>
+#endif
+
+class Standard_Transient;
+class Handle_Standard_Type;
+class Handle(TCollection_MapNode);
+class GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet;
+Standard_EXPORT Handle_Standard_Type& STANDARD_TYPE(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet);
+
+class Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet) : public Handle(TCollection_MapNode) {
+ public:
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)():Handle(TCollection_MapNode)() {}
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)(const Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)& aHandle) : Handle(TCollection_MapNode)(aHandle)
+ {
+ }
+
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)(const GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet* anItem) : Handle(TCollection_MapNode)((TCollection_MapNode *)anItem)
+ {
+ }
+
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)& operator=(const Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)& aHandle)
+ {
+ Assign(aHandle.Access());
+ return *this;
+ }
+
+ Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)& operator=(const GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet* anItem)
+ {
+ Assign((Standard_Transient *)anItem);
+ return *this;
+ }
+
+ GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet* operator->() const
+ {
+ return (GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet *)ControlAccess();
+ }
+
+// Standard_EXPORT ~Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet)();
+
+ Standard_EXPORT static const Handle(GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet) DownCast(const Handle(Standard_Transient)& AnObject);
+};
+#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape)():Handle(TCollection_MapNode)() {}
Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape)(const Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape* operator->()
- {
- return (GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape *)ControlAccess();
- }
-
- GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape* operator->() const
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape* operator->() const
{
return (GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape *)ControlAccess();
}
- Standard_EXPORT ~Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape)();
+// Standard_EXPORT ~Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape)();
Standard_EXPORT static const Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape)():Handle(TCollection_MapNode)() {}
Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape)(const Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape* operator->()
- {
- return (GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape *)ControlAccess();
- }
-
- GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape* operator->() const
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape* operator->() const
{
return (GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape *)ControlAccess();
}
- Standard_EXPORT ~Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape)();
+// Standard_EXPORT ~Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape)();
Standard_EXPORT static const Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox)():Handle(TCollection_MapNode)() {}
Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox)(const Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox* operator->()
- {
- return (GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox *)ControlAccess();
- }
-
- GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox* operator->() const
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox* operator->() const
{
return (GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox *)ControlAccess();
}
- Standard_EXPORT ~Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox)();
+// Standard_EXPORT ~Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox)();
Standard_EXPORT static const Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState)():Handle(TCollection_MapNode)() {}
Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState)(const Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState* operator->()
- {
- return (GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState *)ControlAccess();
- }
-
- GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState* operator->() const
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState* operator->() const
{
return (GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState *)ControlAccess();
}
- Standard_EXPORT ~Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState)();
+// Standard_EXPORT ~Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState)();
Standard_EXPORT static const Handle(GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(GEOMAlgo_ListNodeOfListOfCoupleOfShapes) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(GEOMAlgo_ListNodeOfListOfCoupleOfShapes)():Handle(TCollection_MapNode)() {}
Handle(GEOMAlgo_ListNodeOfListOfCoupleOfShapes)(const Handle(GEOMAlgo_ListNodeOfListOfCoupleOfShapes)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- GEOMAlgo_ListNodeOfListOfCoupleOfShapes* operator->()
- {
- return (GEOMAlgo_ListNodeOfListOfCoupleOfShapes *)ControlAccess();
- }
-
- GEOMAlgo_ListNodeOfListOfCoupleOfShapes* operator->() const
+ GEOMAlgo_ListNodeOfListOfCoupleOfShapes* operator->() const
{
return (GEOMAlgo_ListNodeOfListOfCoupleOfShapes *)ControlAccess();
}
- Standard_EXPORT ~Handle(GEOMAlgo_ListNodeOfListOfCoupleOfShapes)();
+// Standard_EXPORT ~Handle(GEOMAlgo_ListNodeOfListOfCoupleOfShapes)();
Standard_EXPORT static const Handle(GEOMAlgo_ListNodeOfListOfCoupleOfShapes) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(GEOMAlgo_ListNodeOfListOfPnt) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(GEOMAlgo_ListNodeOfListOfPnt)():Handle(TCollection_MapNode)() {}
Handle(GEOMAlgo_ListNodeOfListOfPnt)(const Handle(GEOMAlgo_ListNodeOfListOfPnt)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- GEOMAlgo_ListNodeOfListOfPnt* operator->()
- {
- return (GEOMAlgo_ListNodeOfListOfPnt *)ControlAccess();
- }
-
- GEOMAlgo_ListNodeOfListOfPnt* operator->() const
+ GEOMAlgo_ListNodeOfListOfPnt* operator->() const
{
return (GEOMAlgo_ListNodeOfListOfPnt *)ControlAccess();
}
- Standard_EXPORT ~Handle(GEOMAlgo_ListNodeOfListOfPnt)();
+// Standard_EXPORT ~Handle(GEOMAlgo_ListNodeOfListOfPnt)();
Standard_EXPORT static const Handle(GEOMAlgo_ListNodeOfListOfPnt) DownCast(const Handle(Standard_Transient)& AnObject);
};
BlockFix_UnionEdges.cxx \
BlockFix_UnionFaces.cxx \
GEOMAlgo_Algo.cxx \
+ GEOMAlgo_Builder_0.cxx \
+ GEOMAlgo_Builder_1.cxx \
+ GEOMAlgo_Builder_2.cxx \
+ GEOMAlgo_Builder_3.cxx \
+ GEOMAlgo_Builder_4.cxx \
+ GEOMAlgo_BuilderArea.cxx \
+ GEOMAlgo_Builder.cxx \
+ GEOMAlgo_BuilderFace.cxx \
+ GEOMAlgo_BuilderShape.cxx \
+ GEOMAlgo_BuilderSolid.cxx \
+ GEOMAlgo_BuilderTools.cxx \
GEOMAlgo_CoupleOfShapes.cxx \
GEOMAlgo_DataMapIteratorOfDataMapOfPassKeyInteger_0.cxx \
+ GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape_0.cxx \
+ GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal_0.cxx \
+ GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet_0.cxx \
GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger_0.cxx \
+ GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape_0.cxx \
+ GEOMAlgo_DataMapNodeOfDataMapOfShapeReal_0.cxx \
+ GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet_0.cxx \
GEOMAlgo_DataMapOfPassKeyInteger_0.cxx \
+ GEOMAlgo_DataMapOfRealListOfShape_0.cxx \
+ GEOMAlgo_DataMapOfShapeReal_0.cxx \
+ GEOMAlgo_DataMapOfShapeShapeSet_0.cxx \
GEOMAlgo_FinderShapeOn1.cxx \
+ GEOMAlgo_FinderShapeOn.cxx \
GEOMAlgo_FinderShapeOnQuad.cxx \
GEOMAlgo_GlueAnalyser.cxx \
GEOMAlgo_Gluer.cxx \
GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape_0.cxx \
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyListOfShape_0.cxx \
GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape_0.cxx \
GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox_0.cxx \
GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState_0.cxx \
GEOMAlgo_IndexedDataMapOfIntegerShape_0.cxx \
+ GEOMAlgo_IndexedDataMapOfPassKeyListOfShape_0.cxx \
GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape_0.cxx \
GEOMAlgo_IndexedDataMapOfShapeBox_0.cxx \
GEOMAlgo_IndexedDataMapOfShapeState_0.cxx \
GEOMAlgo_PassKeyMapHasher.cxx \
GEOMAlgo_PassKeyShape.cxx \
GEOMAlgo_ShapeAlgo.cxx \
+ GEOMAlgo_ShapeSet.cxx \
+ GEOMAlgo_ShapeSolid.cxx \
+ GEOMAlgo_ShellSolid.cxx \
+ GEOMAlgo_SolidSolid.cxx \
+ GEOMAlgo_Splitter.cxx \
GEOMAlgo_StateCollector.cxx \
GEOMAlgo_SurfaceTools.cxx \
- GEOMAlgo_Tools.cxx
+ GEOMAlgo_Tools3D.cxx \
+ GEOMAlgo_Tools.cxx \
+ GEOMAlgo_VertexSolid.cxx \
+ GEOMAlgo_WESCorrector.cxx \
+ GEOMAlgo_WireEdgeSet.cxx \
+ GEOMAlgo_WireSolid.cxx \
+ GEOMAlgo_WireSplitter.cxx
LIB_CLIENT_IDL =
LIB_SERVER_IDL =
BlockFix_CheckTool.hxx \
Handle_BlockFix_BlockFixAPI.hxx \
GEOMAlgo_Algo.hxx \
+ GEOMAlgo_BuilderArea.hxx \
+ GEOMAlgo_BuilderFace.hxx \
+ GEOMAlgo_Builder.hxx \
+ GEOMAlgo_BuilderShape.hxx \
+ GEOMAlgo_BuilderSolid.hxx \
+ GEOMAlgo_BuilderTools.hxx \
GEOMAlgo_CoupleOfShapes.hxx \
- GEOMAlgo_GlueAnalyser.hxx \
- GEOMAlgo_Gluer.hxx \
+ GEOMAlgo_DataMapIteratorOfDataMapOfPassKeyInteger.hxx \
+ GEOMAlgo_DataMapIteratorOfDataMapOfRealListOfShape.hxx \
+ GEOMAlgo_DataMapIteratorOfDataMapOfShapeReal.hxx \
+ GEOMAlgo_DataMapIteratorOfDataMapOfShapeShapeSet.hxx \
+ GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger.hxx \
+ GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx \
+ GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx \
+ GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx \
+ GEOMAlgo_DataMapOfPassKeyInteger.hxx \
+ GEOMAlgo_DataMapOfRealListOfShape.hxx \
+ GEOMAlgo_DataMapOfShapeReal.hxx \
+ GEOMAlgo_DataMapOfShapeShapeSet.hxx \
GEOMAlgo_FinderShapeOn1.hxx \
+ GEOMAlgo_FinderShapeOn.hxx \
GEOMAlgo_FinderShapeOnQuad.hxx \
+ GEOMAlgo_GlueAnalyser.hxx \
+ GEOMAlgo_Gluer.hxx \
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape.hxx \
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyListOfShape.hxx \
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape.hxx \
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox.hxx \
+ GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState.hxx \
+ GEOMAlgo_IndexedDataMapOfIntegerShape.hxx \
+ GEOMAlgo_IndexedDataMapOfPassKeyListOfShape.hxx \
+ GEOMAlgo_IndexedDataMapOfPassKeyShapeListOfShape.hxx \
+ GEOMAlgo_IndexedDataMapOfShapeBox.hxx \
GEOMAlgo_IndexedDataMapOfShapeState.hxx \
GEOMAlgo_ListIteratorOfListOfCoupleOfShapes.hxx \
+ GEOMAlgo_ListIteratorOfListOfPnt.hxx \
+ GEOMAlgo_ListNodeOfListOfCoupleOfShapes.hxx \
+ GEOMAlgo_ListNodeOfListOfPnt.hxx \
GEOMAlgo_ListOfCoupleOfShapes.hxx \
+ GEOMAlgo_ListOfPnt.hxx \
+ GEOMAlgo_PassKey.hxx \
+ GEOMAlgo_PassKeyMapHasher.hxx \
+ GEOMAlgo_PassKeyShape.hxx \
+ GEOMAlgo_PWireEdgeSet.hxx \
GEOMAlgo_ShapeAlgo.hxx \
+ GEOMAlgo_ShapeSet.hxx \
+ GEOMAlgo_ShapeSolid.hxx \
+ GEOMAlgo_ShellSolid.hxx \
+ GEOMAlgo_SolidSolid.hxx \
+ GEOMAlgo_Splitter.hxx \
+ GEOMAlgo_StateCollector.hxx \
GEOMAlgo_State.hxx \
+ GEOMAlgo_SurfaceTools.hxx \
+ GEOMAlgo_Tools3D.hxx \
+ GEOMAlgo_Tools.hxx \
+ GEOMAlgo_VertexSolid.hxx \
+ GEOMAlgo_WESCorrector.hxx \
+ GEOMAlgo_WireEdgeSet.hxx \
+ GEOMAlgo_WireSolid.hxx \
+ GEOMAlgo_WireSplitter.hxx \
+ Handle_GEOMAlgo_DataMapNodeOfDataMapOfPassKeyInteger.hxx \
+ Handle_GEOMAlgo_DataMapNodeOfDataMapOfRealListOfShape.hxx \
+ Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeReal.hxx \
+ Handle_GEOMAlgo_DataMapNodeOfDataMapOfShapeShapeSet.hxx \
+ Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfIntegerShape.hxx \
+ Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyListOfShape.hxx \
+ Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfPassKeyShapeListOfShape.hxx \
+ Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeBox.hxx \
Handle_GEOMAlgo_IndexedDataMapNodeOfIndexedDataMapOfShapeState.hxx \
- Handle_GEOMAlgo_ListNodeOfListOfCoupleOfShapes.hxx
+ Handle_GEOMAlgo_ListNodeOfListOfCoupleOfShapes.hxx \
+ Handle_GEOMAlgo_ListNodeOfListOfPnt.hxx
# idl files
EXPORT_IDLS=
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)():Handle(TCollection_MapNode)() {}
Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)(const Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger* operator->()
- {
- return (NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger *)ControlAccess();
- }
-
- NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger* operator->() const
+ NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger* operator->() const
{
return (NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger *)ControlAccess();
}
- Standard_EXPORT ~Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)();
+// Standard_EXPORT ~Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)();
Standard_EXPORT static const Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)():Handle(TCollection_MapNode)() {}
Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)(const Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors* operator->()
- {
- return (NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors *)ControlAccess();
- }
-
- NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors* operator->() const
+ NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors* operator->() const
{
return (NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors *)ControlAccess();
}
- Standard_EXPORT ~Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)();
+// Standard_EXPORT ~Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)();
Standard_EXPORT static const Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors) DownCast(const Handle(Standard_Transient)& AnObject);
};
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _Handle_NMTDS_ListNodeOfListOfPassKey_HeaderFile
+#define _Handle_NMTDS_ListNodeOfListOfPassKey_HeaderFile
+
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+
+#ifndef _Handle_TCollection_MapNode_HeaderFile
+#include <Handle_TCollection_MapNode.hxx>
+#endif
+
+class Standard_Transient;
+class Handle_Standard_Type;
+class Handle(TCollection_MapNode);
+class NMTDS_ListNodeOfListOfPassKey;
+Standard_EXPORT Handle_Standard_Type& STANDARD_TYPE(NMTDS_ListNodeOfListOfPassKey);
+
+class Handle(NMTDS_ListNodeOfListOfPassKey) : public Handle(TCollection_MapNode) {
+ public:
+ Handle(NMTDS_ListNodeOfListOfPassKey)():Handle(TCollection_MapNode)() {}
+ Handle(NMTDS_ListNodeOfListOfPassKey)(const Handle(NMTDS_ListNodeOfListOfPassKey)& aHandle) : Handle(TCollection_MapNode)(aHandle)
+ {
+ }
+
+ Handle(NMTDS_ListNodeOfListOfPassKey)(const NMTDS_ListNodeOfListOfPassKey* anItem) : Handle(TCollection_MapNode)((TCollection_MapNode *)anItem)
+ {
+ }
+
+ Handle(NMTDS_ListNodeOfListOfPassKey)& operator=(const Handle(NMTDS_ListNodeOfListOfPassKey)& aHandle)
+ {
+ Assign(aHandle.Access());
+ return *this;
+ }
+
+ Handle(NMTDS_ListNodeOfListOfPassKey)& operator=(const NMTDS_ListNodeOfListOfPassKey* anItem)
+ {
+ Assign((Standard_Transient *)anItem);
+ return *this;
+ }
+
+ NMTDS_ListNodeOfListOfPassKey* operator->() const
+ {
+ return (NMTDS_ListNodeOfListOfPassKey *)ControlAccess();
+ }
+
+// Standard_EXPORT ~Handle(NMTDS_ListNodeOfListOfPassKey)();
+
+ Standard_EXPORT static const Handle(NMTDS_ListNodeOfListOfPassKey) DownCast(const Handle(Standard_Transient)& AnObject);
+};
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _Handle_NMTDS_ListNodeOfListOfPassKeyBoolean_HeaderFile
+#define _Handle_NMTDS_ListNodeOfListOfPassKeyBoolean_HeaderFile
+
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+
+#ifndef _Handle_TCollection_MapNode_HeaderFile
+#include <Handle_TCollection_MapNode.hxx>
+#endif
+
+class Standard_Transient;
+class Handle_Standard_Type;
+class Handle(TCollection_MapNode);
+class NMTDS_ListNodeOfListOfPassKeyBoolean;
+Standard_EXPORT Handle_Standard_Type& STANDARD_TYPE(NMTDS_ListNodeOfListOfPassKeyBoolean);
+
+class Handle(NMTDS_ListNodeOfListOfPassKeyBoolean) : public Handle(TCollection_MapNode) {
+ public:
+ Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)():Handle(TCollection_MapNode)() {}
+ Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)(const Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)& aHandle) : Handle(TCollection_MapNode)(aHandle)
+ {
+ }
+
+ Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)(const NMTDS_ListNodeOfListOfPassKeyBoolean* anItem) : Handle(TCollection_MapNode)((TCollection_MapNode *)anItem)
+ {
+ }
+
+ Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)& operator=(const Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)& aHandle)
+ {
+ Assign(aHandle.Access());
+ return *this;
+ }
+
+ Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)& operator=(const NMTDS_ListNodeOfListOfPassKeyBoolean* anItem)
+ {
+ Assign((Standard_Transient *)anItem);
+ return *this;
+ }
+
+ NMTDS_ListNodeOfListOfPassKeyBoolean* operator->() const
+ {
+ return (NMTDS_ListNodeOfListOfPassKeyBoolean *)ControlAccess();
+ }
+
+// Standard_EXPORT ~Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)();
+
+ Standard_EXPORT static const Handle(NMTDS_ListNodeOfListOfPassKeyBoolean) DownCast(const Handle(Standard_Transient)& AnObject);
+};
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _Handle_NMTDS_StdMapNodeOfMapOfPassKey_HeaderFile
+#define _Handle_NMTDS_StdMapNodeOfMapOfPassKey_HeaderFile
+
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+
+#ifndef _Handle_TCollection_MapNode_HeaderFile
+#include <Handle_TCollection_MapNode.hxx>
+#endif
+
+class Standard_Transient;
+class Handle_Standard_Type;
+class Handle(TCollection_MapNode);
+class NMTDS_StdMapNodeOfMapOfPassKey;
+Standard_EXPORT Handle_Standard_Type& STANDARD_TYPE(NMTDS_StdMapNodeOfMapOfPassKey);
+
+class Handle(NMTDS_StdMapNodeOfMapOfPassKey) : public Handle(TCollection_MapNode) {
+ public:
+ Handle(NMTDS_StdMapNodeOfMapOfPassKey)():Handle(TCollection_MapNode)() {}
+ Handle(NMTDS_StdMapNodeOfMapOfPassKey)(const Handle(NMTDS_StdMapNodeOfMapOfPassKey)& aHandle) : Handle(TCollection_MapNode)(aHandle)
+ {
+ }
+
+ Handle(NMTDS_StdMapNodeOfMapOfPassKey)(const NMTDS_StdMapNodeOfMapOfPassKey* anItem) : Handle(TCollection_MapNode)((TCollection_MapNode *)anItem)
+ {
+ }
+
+ Handle(NMTDS_StdMapNodeOfMapOfPassKey)& operator=(const Handle(NMTDS_StdMapNodeOfMapOfPassKey)& aHandle)
+ {
+ Assign(aHandle.Access());
+ return *this;
+ }
+
+ Handle(NMTDS_StdMapNodeOfMapOfPassKey)& operator=(const NMTDS_StdMapNodeOfMapOfPassKey* anItem)
+ {
+ Assign((Standard_Transient *)anItem);
+ return *this;
+ }
+
+ NMTDS_StdMapNodeOfMapOfPassKey* operator->() const
+ {
+ return (NMTDS_StdMapNodeOfMapOfPassKey *)ControlAccess();
+ }
+
+// Standard_EXPORT ~Handle(NMTDS_StdMapNodeOfMapOfPassKey)();
+
+ Standard_EXPORT static const Handle(NMTDS_StdMapNodeOfMapOfPassKey) DownCast(const Handle(Standard_Transient)& AnObject);
+};
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean_HeaderFile
+#define _Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean_HeaderFile
+
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+
+#ifndef _Handle_TCollection_MapNode_HeaderFile
+#include <Handle_TCollection_MapNode.hxx>
+#endif
+
+class Standard_Transient;
+class Handle_Standard_Type;
+class Handle(TCollection_MapNode);
+class NMTDS_StdMapNodeOfMapOfPassKeyBoolean;
+Standard_EXPORT Handle_Standard_Type& STANDARD_TYPE(NMTDS_StdMapNodeOfMapOfPassKeyBoolean);
+
+class Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean) : public Handle(TCollection_MapNode) {
+ public:
+ Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)():Handle(TCollection_MapNode)() {}
+ Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)(const Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)& aHandle) : Handle(TCollection_MapNode)(aHandle)
+ {
+ }
+
+ Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)(const NMTDS_StdMapNodeOfMapOfPassKeyBoolean* anItem) : Handle(TCollection_MapNode)((TCollection_MapNode *)anItem)
+ {
+ }
+
+ Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)& operator=(const Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)& aHandle)
+ {
+ Assign(aHandle.Access());
+ return *this;
+ }
+
+ Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)& operator=(const NMTDS_StdMapNodeOfMapOfPassKeyBoolean* anItem)
+ {
+ Assign((Standard_Transient *)anItem);
+ return *this;
+ }
+
+ NMTDS_StdMapNodeOfMapOfPassKeyBoolean* operator->() const
+ {
+ return (NMTDS_StdMapNodeOfMapOfPassKeyBoolean *)ControlAccess();
+ }
+
+// Standard_EXPORT ~Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)();
+
+ Standard_EXPORT static const Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean) DownCast(const Handle(Standard_Transient)& AnObject);
+};
+#endif
NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger_0.cxx \
NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger_0.cxx \
NMTDS_IndexRange.cxx \
+ NMTDS_Iterator.cxx \
NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors_0.cxx \
+ NMTDS_ListIteratorOfListOfPassKey_0.cxx \
+ NMTDS_ListIteratorOfListOfPassKeyBoolean_0.cxx \
NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors_0.cxx \
+ NMTDS_ListNodeOfListOfPassKey_0.cxx \
+ NMTDS_ListNodeOfListOfPassKeyBoolean_0.cxx \
NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors_0.cxx \
- NMTDS_ShapesDataStructure.cxx
+ NMTDS_ListOfPassKey_0.cxx \
+ NMTDS_ListOfPassKeyBoolean_0.cxx \
+ NMTDS_MapIteratorOfMapOfPassKey_0.cxx \
+ NMTDS_MapIteratorOfMapOfPassKeyBoolean_0.cxx \
+ NMTDS_MapOfPassKey_0.cxx \
+ NMTDS_MapOfPassKeyBoolean_0.cxx \
+ NMTDS_PassKeyBoolean.cxx \
+ NMTDS_PassKey.cxx \
+ NMTDS_PassKeyMapHasher.cxx \
+ NMTDS_ShapesDataStructure.cxx \
+ NMTDS_StdMapNodeOfMapOfPassKey_0.cxx \
+ NMTDS_StdMapNodeOfMapOfPassKeyBoolean_0.cxx
LIB_CLIENT_IDL =
LIB_SERVER_IDL =
# header files
EXPORT_HEADERS = \
- NMTDS_ShapesDataStructure.hxx \
- NMTDS_PShapesDataStructure.hxx \
+ Handle_NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger.hxx \
+ Handle_NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors.hxx \
+ Handle_NMTDS_ListNodeOfListOfPassKeyBoolean.hxx \
+ Handle_NMTDS_ListNodeOfListOfPassKey.hxx \
+ Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx \
+ Handle_NMTDS_StdMapNodeOfMapOfPassKey.hxx \
NMTDS_CArray1OfIndexRange.hxx \
+ NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger.hxx \
NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger.hxx \
- Handle_NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger.hxx
+ NMTDS_IndexRange.hxx \
+ NMTDS_Iterator.hxx \
+ NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors.hxx \
+ NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx \
+ NMTDS_ListIteratorOfListOfPassKey.hxx \
+ NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors.hxx \
+ NMTDS_ListNodeOfListOfPassKeyBoolean.hxx \
+ NMTDS_ListNodeOfListOfPassKey.hxx \
+ NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors.hxx \
+ NMTDS_ListOfPassKeyBoolean.hxx \
+ NMTDS_ListOfPassKey.hxx \
+ NMTDS_MapIteratorOfMapOfPassKeyBoolean.hxx \
+ NMTDS_MapIteratorOfMapOfPassKey.hxx \
+ NMTDS_MapOfPassKeyBoolean.hxx \
+ NMTDS_MapOfPassKey.hxx \
+ NMTDS_PassKeyBoolean.hxx \
+ NMTDS_PassKey.hxx \
+ NMTDS_PassKeyMapHasher.hxx \
+ NMTDS_PShapesDataStructure.hxx \
+ NMTDS_ShapesDataStructure.hxx \
+ NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx \
+ NMTDS_StdMapNodeOfMapOfPassKey.hxx
# idl files
EXPORT_IDLS=
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTDS.cdl
-- Created: Fri Nov 28 10:13:19 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
package NMTDS
BOPTColStd
is
class ShapesDataStructure;
- class IndexRange;
-
+ class IndexRange;
+
+ -- Modified to Add new classes Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ class Iterator;
+ class PassKey;
+ class PassKeyBoolean;
+ class PassKeyMapHasher;
+ -- Contribution of Samtech www.samcef.com END
+
pointer PShapesDataStructure to ShapesDataStructure from NMTDS;
class CArray1OfIndexRange instantiates
IndexedDataMap from TCollection(Integer from Standard,
IndexedDataMapOfShapeInteger from BooleanOperations,
MapIntegerHasher from TColStd);
-
+
+ -- Modified to Add new classes Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ class ListOfPassKey instantiates
+ List from TCollection(PassKey from NMTDS);
+
+ class MapOfPassKey instantiates
+ Map from TCollection(PassKey from NMTDS,
+ PassKeyMapHasher from NMTDS);
+
+ class ListOfPassKeyBoolean instantiates
+ List from TCollection(PassKeyBoolean from NMTDS);
+
+ class MapOfPassKeyBoolean instantiates
+ Map from TCollection(PassKeyBoolean from NMTDS,
+ PassKeyMapHasher from NMTDS);
+ -- Contribution of Samtech www.samcef.com END
end NMTDS;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTDS_CArray1OfIndexRange {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTDS_CArray1OfIndexRange(const Standard_Integer Length = 0,const Standard_Integer BlockLength = 5);
+
+
Standard_EXPORT void Resize(const Standard_Integer theNewLength) ;
+
+
Standard_EXPORT void Destroy() ;
~NMTDS_CArray1OfIndexRange()
{
Destroy();
}
+
+
Standard_EXPORT Standard_Integer Length() const;
+
+
Standard_EXPORT Standard_Integer Extent() const;
+
+
Standard_EXPORT Standard_Integer FactLength() const;
+
+
Standard_EXPORT Standard_Integer Append(const NMTDS_IndexRange& Value) ;
+
+
Standard_EXPORT void Remove(const Standard_Integer Index) ;
+
+
Standard_EXPORT const NMTDS_IndexRange& Value(const Standard_Integer Index) const;
const NMTDS_IndexRange& operator ()(const Standard_Integer Index) const
{
return Value(Index);
}
+
+
Standard_EXPORT NMTDS_IndexRange& ChangeValue(const Standard_Integer Index) ;
NMTDS_IndexRange& operator ()(const Standard_Integer Index)
{
return ChangeValue(Index);
}
+
+
Standard_EXPORT void SetBlockLength(const Standard_Integer aBL) ;
+
+
Standard_EXPORT Standard_Integer BlockLength() const;
// Methods PRIVATE
//
+
+
Standard_EXPORT NMTDS_CArray1OfIndexRange(const NMTDS_CArray1OfIndexRange& AnArray);
+
+
Standard_EXPORT NMTDS_CArray1OfIndexRange& Assign(const NMTDS_CArray1OfIndexRange& Other) ;
NMTDS_CArray1OfIndexRange& operator =(const NMTDS_CArray1OfIndexRange& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT Standard_Boolean IsInvalidIndex(const Standard_Integer Index) const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTDS_IndexRange.cdl
-- Created: Fri Nov 28 10:31:05 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
-
class IndexRange from NMTDS
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTDS_IndexRange {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTDS_IndexRange();
+
+
Standard_EXPORT void SetFirst(const Standard_Integer aFirst) ;
+
+
Standard_EXPORT void SetLast(const Standard_Integer aLast) ;
+
+
Standard_EXPORT Standard_Integer First() const;
+
+
Standard_EXPORT Standard_Integer Last() const;
+
+
Standard_EXPORT Standard_Boolean IsInRange(const Standard_Integer aIndex) const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _NMTDS_IndexRange_HeaderFile
#include <NMTDS_IndexRange.hxx>
#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger;
+
class NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger(const Standard_Integer& K1,const Standard_Integer K2,const BooleanOperations_IndexedDataMapOfShapeInteger& I,const TCollection_MapNodePtr& n1,const TCollection_MapNodePtr& n2);
+
Standard_Integer& Key1() const;
+
Standard_Integer& Key2() const;
+
TCollection_MapNodePtr& Next2() const;
+
BooleanOperations_IndexedDataMapOfShapeInteger& Value() const;
-Standard_EXPORT ~NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger();
+//Standard_EXPORT ~NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger_HeaderFile
#include <NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger.hxx>
#endif
-NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger::~NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger() {}
+//NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger::~NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger) ;
}
-Standard_Boolean NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger::~Handle_NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger() {}
+//Standard_Boolean NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger::~Handle_NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger() {}
#define TheKey Standard_Integer
#define TheKey_hxx <Standard_Integer.hxx>
#define TheItem BooleanOperations_IndexedDataMapOfShapeInteger
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger : public TCollection_BasicMap {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger(const Standard_Integer NbBuckets = 1);
+
+
Standard_EXPORT NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger& Assign(const NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger& Other) ;
NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger& operator =(const NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
Standard_EXPORT void Clear() ;
~NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger()
{
Clear();
}
+
+
Standard_EXPORT Standard_Integer Add(const Standard_Integer& K,const BooleanOperations_IndexedDataMapOfShapeInteger& I) ;
+
+
Standard_EXPORT void Substitute(const Standard_Integer I,const Standard_Integer& K,const BooleanOperations_IndexedDataMapOfShapeInteger& T) ;
+
+
Standard_EXPORT void RemoveLast() ;
+
+
Standard_EXPORT Standard_Boolean Contains(const Standard_Integer& K) const;
+
+
Standard_EXPORT const Standard_Integer& FindKey(const Standard_Integer I) const;
+
+
Standard_EXPORT const BooleanOperations_IndexedDataMapOfShapeInteger& FindFromIndex(const Standard_Integer I) const;
const BooleanOperations_IndexedDataMapOfShapeInteger& operator ()(const Standard_Integer I) const
{
return FindFromIndex(I);
}
+
+
Standard_EXPORT BooleanOperations_IndexedDataMapOfShapeInteger& ChangeFromIndex(const Standard_Integer I) ;
BooleanOperations_IndexedDataMapOfShapeInteger& operator ()(const Standard_Integer I)
{
return ChangeFromIndex(I);
}
+
+
Standard_EXPORT Standard_Integer FindIndex(const Standard_Integer& K) const;
+
+
Standard_EXPORT const BooleanOperations_IndexedDataMapOfShapeInteger& FindFromKey(const Standard_Integer& K) const;
+
+
Standard_EXPORT BooleanOperations_IndexedDataMapOfShapeInteger& ChangeFromKey(const Standard_Integer& K) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger(const NMTDS_IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
--- /dev/null
+-- Copyright (C) 2006 SAMTECH
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: NMTDS_Iterator.cdl
+-- Created: Sun May 07 14:58:16 2006
+-- Author: Peter KURNEV
+-- <peter@PREFEX>
+
+
+
+class Iterator from NMTDS
+
+ ---Purpose:
+
+uses
+ ShapeEnum from TopAbs,
+ ShapesDataStructure from NMTDS,
+ PShapesDataStructure from NMTDS,
+ ListOfPassKeyBoolean from NMTDS,
+ ListIteratorOfListOfPassKeyBoolean from NMTDS
+--raises
+
+is
+ Create
+ returns Iterator from NMTDS;
+ ---C++: alias "Standard_EXPORT virtual ~NMTDS_Iterator();"
+
+
+ SetDS(me:out;
+ pDS:PShapesDataStructure from NMTDS);
+
+ DS(me)
+ returns ShapesDataStructure from NMTDS;
+ ---C++:return const &
+
+ Initialize(me: out;
+ aType1: ShapeEnum from TopAbs;
+ aType2: ShapeEnum from TopAbs);
+ More(me)
+ returns Boolean from Standard;
+
+ Next(me: out);
+
+ Current(me; aIndex1:out Integer from Standard;
+ aIndex2:out Integer from Standard;
+ aWithSubShape: out Boolean from Standard);
+
+ Prepare(me:out);
+
+ ExpectedLength(me)
+ returns Integer from Standard;
+
+fields
+ myPDS :PShapesDataStructure from NMTDS is protected;
+ myLists :ListOfPassKeyBoolean from NMTDS [6] is protected;
+ myIterator :ListIteratorOfListOfPassKeyBoolean from NMTDS is protected;
+ myEmptyList:ListOfPassKeyBoolean from NMTDS is protected;
+ myLength :Integer from Standard is protected;
+
+end Iterator;
--- /dev/null
+// Copyright (C) 2006 SAMTECH
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: NMTDS_Iterator.cxx
+// Created: Sun May 07 15:04:41 2006
+// Author: Peter KURNEV
+// <peter@PREFEX>
+
+
+#include <NMTDS_Iterator.ixx>
+#include <NMTDS_CArray1OfIndexRange.hxx>
+#include <NMTDS_IndexRange.hxx>
+#include <Bnd_Box.hxx>
+#include <TopoDS_Shape.hxx>
+#include <TColStd_ListOfInteger.hxx>
+#include <TColStd_Array1OfListOfInteger.hxx>
+#include <TColStd_ListIteratorOfListOfInteger.hxx>
+#include <TColStd_MapOfInteger.hxx>
+#include <TColStd_MapIteratorOfMapOfInteger.hxx>
+#include <NMTDS_PassKeyBoolean.hxx>
+#include <NMTDS_MapOfPassKeyBoolean.hxx>
+
+static
+ Bnd_Box& ComputeBoxEx(const Standard_Integer iX,
+ NMTDS_ShapesDataStructure* pDS,
+ Bnd_Box* pBoxes);
+static
+ Standard_Integer TypeToInteger(const TopAbs_ShapeEnum aType);
+
+static
+ Standard_Integer TypeToInteger(const TopAbs_ShapeEnum aType1,
+ const TopAbs_ShapeEnum aType2);
+static
+ void PropagateState(const Standard_Integer aIDS1,
+ const Standard_Integer aIDS2,
+ const Standard_Integer iStatus,
+ const Standard_Integer aNb,
+ NMTDS_ShapesDataStructure* pDS,
+ Standard_Integer *pTable);
+static
+ void FillSuccessors(const Standard_Integer aIDS,
+ NMTDS_ShapesDataStructure* pDS,
+ TColStd_MapOfInteger& aMS);
+
+//=======================================================================
+//function : NMTDS_Iterator
+//purpose :
+//=======================================================================
+ NMTDS_Iterator::NMTDS_Iterator()
+{
+ myPDS=NULL;
+ myLength=0;
+}
+//=======================================================================
+//function : ~NMTDS_Iterator
+//purpose :
+//=======================================================================
+ NMTDS_Iterator::~NMTDS_Iterator()
+{
+}
+//=======================================================================
+// function: SetDS
+// purpose:
+//=======================================================================
+ void NMTDS_Iterator::SetDS(const NMTDS_PShapesDataStructure& aDS)
+{
+ myPDS=aDS;
+}
+//=======================================================================
+// function: DS
+// purpose:
+//=======================================================================
+ const NMTDS_ShapesDataStructure& NMTDS_Iterator::DS()const
+{
+ return *myPDS;
+}
+//=======================================================================
+// function: ExpectedLength
+// purpose:
+//=======================================================================
+ Standard_Integer NMTDS_Iterator::ExpectedLength() const
+{
+ return myLength;
+}
+//=======================================================================
+// function: Initialize
+// purpose:
+//=======================================================================
+ void NMTDS_Iterator::Initialize(const TopAbs_ShapeEnum aType1,
+ const TopAbs_ShapeEnum aType2)
+{
+ Standard_Integer iX;
+ //
+ iX=TypeToInteger(aType1, aType2);
+ if (iX>=0) {
+ myIterator.Initialize(myLists[iX]);
+ myLength=myLists[iX].Extent();
+ }
+ else {
+ myIterator.Initialize(myEmptyList);
+ myLength=0;
+ }
+}
+//=======================================================================
+// function: More
+// purpose:
+//=======================================================================
+ Standard_Boolean NMTDS_Iterator::More()const
+{
+ return myIterator.More();
+}
+//=======================================================================
+// function: Next
+// purpose:
+//=======================================================================
+ void NMTDS_Iterator::Next()
+{
+ myIterator.Next();
+}
+//=======================================================================
+// function: Current
+// purpose:
+//=======================================================================
+ void NMTDS_Iterator::Current(Standard_Integer& aIndex1,
+ Standard_Integer& aIndex2,
+ Standard_Boolean& aWithSubShape) const
+{
+ const NMTDS_PassKeyBoolean& aPKB=myIterator.Value();
+ aPKB.Ids(aIndex1, aIndex2);
+ aWithSubShape=aPKB.Flag();
+}
+//=======================================================================
+// function: Prepare
+// purpose:
+//=======================================================================
+ void NMTDS_Iterator::Prepare()
+{
+ Standard_Boolean bFlag;
+ Standard_Integer aNb, aNb2, aNbR, iR, jR1, jR2, jR;
+ Standard_Integer *pTable, i, j, k, iT1, iT2, i1, i2, j1, j2, iT, jT;
+ Standard_Integer iStatus, iX;
+ Bnd_Box *pBoxes, aBox;
+ TColStd_ListIteratorOfListOfInteger aItIT, aItJT;
+ TopAbs_ShapeEnum aTi, aTj;
+ NMTDS_PassKeyBoolean aPKXB;
+ NMTDS_MapOfPassKeyBoolean aMPKXB;
+ //
+ if (myPDS==NULL){
+ return;
+ }
+ //
+ myLength=0;
+ for (i=0; i<6; ++i) {
+ myLists[i].Clear();
+ }
+ //
+ aNb=myPDS->NumberOfShapesOfTheObject();
+ aNb2=aNb*aNb;
+ //
+ pTable=new Standard_Integer [aNb2];
+ pBoxes=new Bnd_Box [aNb];
+ //
+ // 1. Set status to Unknown
+ for (i=0; i<aNb2; ++i) {
+ pTable[i]=0; // Unknown
+ }
+ //
+ // 2. Treat Ranges
+ // Set status to SameRange;
+ // Compute enlarged boxes ;
+ const NMTDS_CArray1OfIndexRange& aRanges=myPDS->Ranges();
+ aNbR=aRanges.Extent();
+ for (iR=1; iR<=aNbR; ++iR) {
+ const NMTDS_IndexRange& aRange=aRanges(iR);
+ jR1=aRange.First();
+ jR2=aRange.Last();
+ for (i=jR1; i<=jR2; ++i) {
+ for (j=i; j<=jR2; ++j) {
+ k=(i-1)*aNb+(j-1);
+ pTable[k]=4; //SameRange
+ }
+ //
+ ComputeBoxEx(i, myPDS, pBoxes);
+ }
+ }
+ //
+ // 3. Intersect shapes by ranges
+ iT1=TypeToInteger(TopAbs_COMPOUND);
+ iT2=TypeToInteger(TopAbs_VERTEX);
+ //
+ for (iR=1; iR<aNbR; ++iR) {
+ TColStd_Array1OfListOfInteger aALIR(iT1, iT2), aALJR(iT1, iT2);
+ //
+ const NMTDS_IndexRange& aRi=aRanges(iR);
+ i1=aRi.First();
+ i2=aRi.Last();
+ for (i=i1; i<=i2; ++i) {
+ aALIR(TypeToInteger(myPDS->GetShapeType(i))).Append(i);
+ }
+ //
+ for (jR=2; jR<=aNbR; ++jR) {
+ const NMTDS_IndexRange& aRj=aRanges(jR);
+ j1=aRj.First();
+ j2=aRj.Last();
+ for (j=j1; j<=j2; ++j) {
+ aALJR(TypeToInteger(myPDS->GetShapeType(j))).Append(j);
+ }
+ }
+ //
+ for (iT=iT1; iT<=iT2; ++iT) {
+ const TColStd_ListOfInteger& aLIT=aALIR(iT);
+ if (aLIT.IsEmpty()) {
+ continue;
+ }
+ for (jT=iT1; jT<=iT2; ++jT) {
+ const TColStd_ListOfInteger& aLJT=aALJR(jT);
+ if (aLJT.IsEmpty()) {
+ continue;
+ }
+ //
+ aItIT.Initialize(aLIT);
+ for (; aItIT.More(); aItIT.Next()) {
+ aItJT.Initialize(aLJT);
+ for (; aItJT.More(); aItJT.Next()) {
+ i1=aItIT.Value();
+ j1=aItJT.Value();
+ if (i1>j1) {
+ iX=i1;
+ i1=j1;
+ j1=iX;
+ }
+ //
+ i=i1-1;
+ j=j1-1;
+ k=i*aNb+j;
+ //
+ if (pTable[k]!=0 && pTable[k]!=2) {
+ continue;
+ }
+ // enlarged boxes
+ const Bnd_Box& aBoxEi=pBoxes[i];
+ const Bnd_Box& aBoxEj=pBoxes[j];
+ if (aBoxEi.IsOut(aBoxEj)) {
+ iStatus=3; // Non-intersected
+ PropagateState(i1, j1, iStatus, aNb, myPDS, pTable);
+ }
+ else {
+ iStatus=1; // Bounding boxes are intersected
+ const Bnd_Box& aBoxi=myPDS->GetBoundingBox(i1);
+ const Bnd_Box& aBoxj=myPDS->GetBoundingBox(j1);
+ if (aBoxi.IsOut(aBoxj)) {
+ iStatus=2; // Bounding boxes of Sub-shapes are intersected
+ }
+ pTable[k]=iStatus;
+ //
+ aTi=myPDS->GetShapeType(i1);
+ aTj=myPDS->GetShapeType(j1);
+ iX=TypeToInteger(aTi, aTj);
+ //
+ if (iX>=0) {
+ aPKXB.SetIds(i1, j1);
+ if (aMPKXB.Add(aPKXB)) {
+ bFlag=Standard_False;
+ if(iStatus==2) {
+ bFlag=!bFlag;
+ }
+ aPKXB.SetFlag(bFlag);
+ myLists[iX].Append(aPKXB);
+ }
+ }//if (iX>=0) {
+ }// else {
+ }//for (; aItJT.More(); aItJT.Next()) {
+ }//for (; aItIT.More(); aItIT.Next()) {
+ }//for (jT=iT1; jT<=iT2; ++jT) {
+ }//for (iT=iT1; iT<=iT2; ++iT) {
+ }
+ //
+ //
+ delete [] (Bnd_Box*)pBoxes;
+ delete [] (Standard_Integer*)pTable;
+}
+//=======================================================================
+// function: PropagateState
+// purpose:
+//=======================================================================
+void PropagateState(const Standard_Integer aIDS1,
+ const Standard_Integer aIDS2,
+ const Standard_Integer iStatus,
+ const Standard_Integer aNb,
+ NMTDS_ShapesDataStructure* pDS,
+ Standard_Integer *pTable)
+{
+ Standard_Integer i, j, k, i1, j1, iX, i11, j11;
+ TColStd_MapOfInteger aMS1, aMS2;
+ TColStd_MapIteratorOfMapOfInteger aIt1, aIt2;
+ //
+ FillSuccessors(aIDS1, pDS, aMS1);
+ FillSuccessors(aIDS2, pDS, aMS2);
+ //
+ aIt1.Initialize(aMS1);
+ for (; aIt1.More(); aIt1.Next()) {
+ i1=aIt1.Key();
+ //
+ aIt2.Initialize(aMS2);
+ for (; aIt2.More(); aIt2.Next()) {
+ j1=aIt2.Key();
+ //
+ i11=i1;
+ j11=j1;
+ //
+ if (i1>j1) {
+ iX=i11;
+ i11=j11;
+ j11=iX;
+ }
+ i=i11-1;
+ j=j11-1;
+ k=i*aNb+j;
+ if (!pTable[k]) {
+ pTable[k]=iStatus;
+ }
+ }
+ }
+}
+//=======================================================================
+// function: FillSuccessors
+// purpose:
+//=======================================================================
+void FillSuccessors(const Standard_Integer aIDS,
+ NMTDS_ShapesDataStructure* pDS,
+ TColStd_MapOfInteger& aMS)
+{
+ Standard_Integer i, aNbS, iDS1;
+ //
+ aMS.Add(aIDS);
+ aNbS=pDS->NumberOfSuccessors(aIDS);
+ for (i=1; i<=aNbS; ++i) {
+ iDS1=pDS->GetSuccessor(aIDS, i);
+ FillSuccessors(iDS1, pDS, aMS);
+ }
+}
+//=======================================================================
+// function: ComputeBoxEx
+// purpose:
+//=======================================================================
+Bnd_Box& ComputeBoxEx(const Standard_Integer aIndexDS,
+ NMTDS_ShapesDataStructure* pDS,
+ Bnd_Box* pBoxes)
+{
+ Standard_Boolean bIsVoid;
+ Standard_Integer iX;
+ //
+ iX=aIndexDS-1;
+ Bnd_Box& aBoxEx=pBoxes[iX];
+ //
+ bIsVoid=aBoxEx.IsVoid();
+ if (bIsVoid) {
+ Standard_Integer i, aNb, iS;
+ //
+ const Bnd_Box& aBox=pDS->GetBoundingBox(aIndexDS);
+ aBoxEx.Add(aBox);
+ //
+ aNb=pDS->NumberOfSuccessors(aIndexDS);
+ for (i=1; i<=aNb; ++i) {
+ iS=pDS->GetSuccessor(aIndexDS, i);
+ Bnd_Box& aBoxS=ComputeBoxEx(iS, pDS, pBoxes);
+ aBoxEx.Add(aBoxS);
+ }
+ }
+ return aBoxEx;
+}
+//=======================================================================
+// function: TypeToInteger
+// purpose:
+//=======================================================================
+Standard_Integer TypeToInteger(const TopAbs_ShapeEnum aType)
+{
+ return (Standard_Integer)aType;
+}
+//=======================================================================
+// function: TypeToInteger
+// purpose:
+//=======================================================================
+Standard_Integer TypeToInteger(const TopAbs_ShapeEnum aType1,
+ const TopAbs_ShapeEnum aType2)
+{
+ Standard_Integer iRet, iT1, iT2, iX;
+ //
+ iRet=-1;
+ iT1=(Standard_Integer)aType1;
+ iT2=(Standard_Integer)aType2;
+ //
+ iX=iT2*10+iT1;
+ switch (iX) {
+ case 77:
+ iRet=5; // VV
+ break;
+ case 76:
+ case 67:
+ iRet=4; // VE
+ break;
+ case 74:
+ case 47:
+ iRet=2; // VF
+ break;
+ case 66:
+ iRet=3; // EE
+ break;
+ case 64:
+ case 46:
+ iRet=1; // EF
+ break;
+ case 44:
+ iRet=0; // FF
+ break;
+ default:
+ break;
+ }
+ return iRet;
+}
+
+/*
+ printf(" *** pTable ***\n");
+ for (i=0; i<aNb; ++i) {
+ for (j=0; j<aNb; ++j) {
+ k=i*aNb+j;
+ printf(" %2d", pTable[k]);
+ }
+ printf("\n");
+ }
+ */
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_Iterator_HeaderFile
+#define _NMTDS_Iterator_HeaderFile
+
+#ifndef _NMTDS_PShapesDataStructure_HeaderFile
+#include <NMTDS_PShapesDataStructure.hxx>
+#endif
+#ifndef _NMTDS_ListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListOfPassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_ListIteratorOfListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _TopAbs_ShapeEnum_HeaderFile
+#include <TopAbs_ShapeEnum.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class NMTDS_ShapesDataStructure;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_Iterator {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_Iterator();
+Standard_EXPORT virtual ~NMTDS_Iterator();
+
+
+Standard_EXPORT void SetDS(const NMTDS_PShapesDataStructure& pDS) ;
+
+
+Standard_EXPORT const NMTDS_ShapesDataStructure& DS() const;
+
+
+Standard_EXPORT void Initialize(const TopAbs_ShapeEnum aType1,const TopAbs_ShapeEnum aType2) ;
+
+
+Standard_EXPORT Standard_Boolean More() const;
+
+
+Standard_EXPORT void Next() ;
+
+
+Standard_EXPORT void Current(Standard_Integer& aIndex1,Standard_Integer& aIndex2,Standard_Boolean& aWithSubShape) const;
+
+
+Standard_EXPORT void Prepare() ;
+
+
+Standard_EXPORT Standard_Integer ExpectedLength() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+NMTDS_PShapesDataStructure myPDS;
+NMTDS_ListOfPassKeyBoolean myLists[6];
+NMTDS_ListIteratorOfListOfPassKeyBoolean myIterator;
+NMTDS_ListOfPassKeyBoolean myEmptyList;
+Standard_Integer myLength;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_Iterator.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_ShapesDataStructure_HeaderFile
+#include <NMTDS_ShapesDataStructure.hxx>
+#endif
+#ifndef _NMTDS_Iterator_HeaderFile
+#include <NMTDS_Iterator.hxx>
+#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors();
+
+
Standard_EXPORT NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors(const NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors& L);
+
+
Standard_EXPORT void Initialize(const NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors& L) ;
+
Standard_Boolean More() const;
+
+
Standard_EXPORT void Next() ;
+
+
Standard_EXPORT BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& Value() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_ListIteratorOfListOfPassKey_HeaderFile
+#define _NMTDS_ListIteratorOfListOfPassKey_HeaderFile
+
+#ifndef _Standard_Address_HeaderFile
+#include <Standard_Address.hxx>
+#endif
+#ifndef _Handle_NMTDS_ListNodeOfListOfPassKey_HeaderFile
+#include <Handle_NMTDS_ListNodeOfListOfPassKey.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class Standard_NoMoreObject;
+class Standard_NoSuchObject;
+class NMTDS_ListOfPassKey;
+class NMTDS_PassKey;
+class NMTDS_ListNodeOfListOfPassKey;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_ListIteratorOfListOfPassKey {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_ListIteratorOfListOfPassKey();
+
+
+Standard_EXPORT NMTDS_ListIteratorOfListOfPassKey(const NMTDS_ListOfPassKey& L);
+
+
+Standard_EXPORT void Initialize(const NMTDS_ListOfPassKey& L) ;
+
+ Standard_Boolean More() const;
+
+
+Standard_EXPORT void Next() ;
+
+
+Standard_EXPORT NMTDS_PassKey& Value() const;
+
+
+friend class NMTDS_ListOfPassKey;
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+Standard_Address current;
+Standard_Address previous;
+
+
+};
+
+#define Item NMTDS_PassKey
+#define Item_hxx <NMTDS_PassKey.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKey.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKey
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKey.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKey_Type_()
+#define TCollection_List NMTDS_ListOfPassKey
+#define TCollection_List_hxx <NMTDS_ListOfPassKey.hxx>
+
+#include <TCollection_ListIterator.lxx>
+
+#undef Item
+#undef Item_hxx
+#undef TCollection_ListNode
+#undef TCollection_ListNode_hxx
+#undef TCollection_ListIterator
+#undef TCollection_ListIterator_hxx
+#undef Handle_TCollection_ListNode
+#undef TCollection_ListNode_Type_
+#undef TCollection_List
+#undef TCollection_List_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_ListIteratorOfListOfPassKeyBoolean_HeaderFile
+#define _NMTDS_ListIteratorOfListOfPassKeyBoolean_HeaderFile
+
+#ifndef _Standard_Address_HeaderFile
+#include <Standard_Address.hxx>
+#endif
+#ifndef _Handle_NMTDS_ListNodeOfListOfPassKeyBoolean_HeaderFile
+#include <Handle_NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class Standard_NoMoreObject;
+class Standard_NoSuchObject;
+class NMTDS_ListOfPassKeyBoolean;
+class NMTDS_PassKeyBoolean;
+class NMTDS_ListNodeOfListOfPassKeyBoolean;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_ListIteratorOfListOfPassKeyBoolean {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_ListIteratorOfListOfPassKeyBoolean();
+
+
+Standard_EXPORT NMTDS_ListIteratorOfListOfPassKeyBoolean(const NMTDS_ListOfPassKeyBoolean& L);
+
+
+Standard_EXPORT void Initialize(const NMTDS_ListOfPassKeyBoolean& L) ;
+
+ Standard_Boolean More() const;
+
+
+Standard_EXPORT void Next() ;
+
+
+Standard_EXPORT NMTDS_PassKeyBoolean& Value() const;
+
+
+friend class NMTDS_ListOfPassKeyBoolean;
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+Standard_Address current;
+Standard_Address previous;
+
+
+};
+
+#define Item NMTDS_PassKeyBoolean
+#define Item_hxx <NMTDS_PassKeyBoolean.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKeyBoolean
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKeyBoolean_Type_()
+#define TCollection_List NMTDS_ListOfPassKeyBoolean
+#define TCollection_List_hxx <NMTDS_ListOfPassKeyBoolean.hxx>
+
+#include <TCollection_ListIterator.lxx>
+
+#undef Item
+#undef Item_hxx
+#undef TCollection_ListNode
+#undef TCollection_ListNode_hxx
+#undef TCollection_ListIterator
+#undef TCollection_ListIterator_hxx
+#undef Handle_TCollection_ListNode
+#undef TCollection_ListNode_Type_
+#undef TCollection_List
+#undef TCollection_List_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+
+#ifndef _Standard_NoMoreObject_HeaderFile
+#include <Standard_NoMoreObject.hxx>
+#endif
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _NMTDS_ListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListOfPassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#include <NMTDS_PassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_ListNodeOfListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#endif
+
+
+#define Item NMTDS_PassKeyBoolean
+#define Item_hxx <NMTDS_PassKeyBoolean.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKeyBoolean
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKeyBoolean_Type_()
+#define TCollection_List NMTDS_ListOfPassKeyBoolean
+#define TCollection_List_hxx <NMTDS_ListOfPassKeyBoolean.hxx>
+#include <TCollection_ListIterator.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_ListIteratorOfListOfPassKey.hxx>
+
+#ifndef _Standard_NoMoreObject_HeaderFile
+#include <Standard_NoMoreObject.hxx>
+#endif
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _NMTDS_ListOfPassKey_HeaderFile
+#include <NMTDS_ListOfPassKey.hxx>
+#endif
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+#ifndef _NMTDS_ListNodeOfListOfPassKey_HeaderFile
+#include <NMTDS_ListNodeOfListOfPassKey.hxx>
+#endif
+
+
+#define Item NMTDS_PassKey
+#define Item_hxx <NMTDS_PassKey.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKey.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKey
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKey.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKey_Type_()
+#define TCollection_List NMTDS_ListOfPassKey
+#define TCollection_List_hxx <NMTDS_ListOfPassKey.hxx>
+#include <TCollection_ListIterator.gxx>
+
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors;
+
class NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors(const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& I,const TCollection_MapNodePtr& n);
+
BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& Value() const;
-Standard_EXPORT ~NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors();
+//Standard_EXPORT ~NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors_HeaderFile
#include <NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors.hxx>
#endif
-NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors::~NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors() {}
+//NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors::~NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors) ;
}
-Standard_Boolean NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors::~Handle_NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors() {}
+//Standard_Boolean NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors::~Handle_NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors() {}
#define Item BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors
#define Item_hxx <BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors.hxx>
#define TCollection_ListNode NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_ListNodeOfListOfPassKey_HeaderFile
+#define _NMTDS_ListNodeOfListOfPassKey_HeaderFile
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Handle_NMTDS_ListNodeOfListOfPassKey_HeaderFile
+#include <Handle_NMTDS_ListNodeOfListOfPassKey.hxx>
+#endif
+
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+#ifndef _TCollection_MapNode_HeaderFile
+#include <TCollection_MapNode.hxx>
+#endif
+#ifndef _TCollection_MapNodePtr_HeaderFile
+#include <TCollection_MapNodePtr.hxx>
+#endif
+class NMTDS_PassKey;
+class NMTDS_ListOfPassKey;
+class NMTDS_ListIteratorOfListOfPassKey;
+
+
+
+class NMTDS_ListNodeOfListOfPassKey : public TCollection_MapNode {
+
+public:
+ // Methods PUBLIC
+ //
+
+NMTDS_ListNodeOfListOfPassKey(const NMTDS_PassKey& I,const TCollection_MapNodePtr& n);
+
+ NMTDS_PassKey& Value() const;
+//Standard_EXPORT ~NMTDS_ListNodeOfListOfPassKey();
+
+
+
+
+ // Type management
+ //
+ Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+NMTDS_PassKey myValue;
+
+
+};
+
+#define Item NMTDS_PassKey
+#define Item_hxx <NMTDS_PassKey.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKey.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKey
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKey.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKey_Type_()
+#define TCollection_List NMTDS_ListOfPassKey
+#define TCollection_List_hxx <NMTDS_ListOfPassKey.hxx>
+
+#include <TCollection_ListNode.lxx>
+
+#undef Item
+#undef Item_hxx
+#undef TCollection_ListNode
+#undef TCollection_ListNode_hxx
+#undef TCollection_ListIterator
+#undef TCollection_ListIterator_hxx
+#undef Handle_TCollection_ListNode
+#undef TCollection_ListNode_Type_
+#undef TCollection_List
+#undef TCollection_List_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_ListNodeOfListOfPassKeyBoolean_HeaderFile
+#define _NMTDS_ListNodeOfListOfPassKeyBoolean_HeaderFile
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Handle_NMTDS_ListNodeOfListOfPassKeyBoolean_HeaderFile
+#include <Handle_NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#endif
+
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#include <NMTDS_PassKeyBoolean.hxx>
+#endif
+#ifndef _TCollection_MapNode_HeaderFile
+#include <TCollection_MapNode.hxx>
+#endif
+#ifndef _TCollection_MapNodePtr_HeaderFile
+#include <TCollection_MapNodePtr.hxx>
+#endif
+class NMTDS_PassKeyBoolean;
+class NMTDS_ListOfPassKeyBoolean;
+class NMTDS_ListIteratorOfListOfPassKeyBoolean;
+
+
+
+class NMTDS_ListNodeOfListOfPassKeyBoolean : public TCollection_MapNode {
+
+public:
+ // Methods PUBLIC
+ //
+
+NMTDS_ListNodeOfListOfPassKeyBoolean(const NMTDS_PassKeyBoolean& I,const TCollection_MapNodePtr& n);
+
+ NMTDS_PassKeyBoolean& Value() const;
+//Standard_EXPORT ~NMTDS_ListNodeOfListOfPassKeyBoolean();
+
+
+
+
+ // Type management
+ //
+ Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+NMTDS_PassKeyBoolean myValue;
+
+
+};
+
+#define Item NMTDS_PassKeyBoolean
+#define Item_hxx <NMTDS_PassKeyBoolean.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKeyBoolean
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKeyBoolean_Type_()
+#define TCollection_List NMTDS_ListOfPassKeyBoolean
+#define TCollection_List_hxx <NMTDS_ListOfPassKeyBoolean.hxx>
+
+#include <TCollection_ListNode.lxx>
+
+#undef Item
+#undef Item_hxx
+#undef TCollection_ListNode
+#undef TCollection_ListNode_hxx
+#undef TCollection_ListIterator
+#undef TCollection_ListIterator_hxx
+#undef Handle_TCollection_ListNode
+#undef TCollection_ListNode_Type_
+#undef TCollection_List
+#undef TCollection_List_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+
+#ifndef _Standard_TypeMismatch_HeaderFile
+#include <Standard_TypeMismatch.hxx>
+#endif
+
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#include <NMTDS_PassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_ListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListOfPassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_ListIteratorOfListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#endif
+//NMTDS_ListNodeOfListOfPassKeyBoolean::~NMTDS_ListNodeOfListOfPassKeyBoolean() {}
+
+
+
+Standard_EXPORT Handle_Standard_Type& NMTDS_ListNodeOfListOfPassKeyBoolean_Type_()
+{
+
+ static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
+ static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
+ static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
+
+
+ static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
+ static Handle_Standard_Type _aType = new Standard_Type("NMTDS_ListNodeOfListOfPassKeyBoolean",
+ sizeof(NMTDS_ListNodeOfListOfPassKeyBoolean),
+ 1,
+ (Standard_Address)_Ancestors,
+ (Standard_Address)NULL);
+
+ return _aType;
+}
+
+
+// DownCast method
+// allow safe downcasting
+//
+const Handle(NMTDS_ListNodeOfListOfPassKeyBoolean) Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)::DownCast(const Handle(Standard_Transient)& AnObject)
+{
+ Handle(NMTDS_ListNodeOfListOfPassKeyBoolean) _anOtherObject;
+
+ if (!AnObject.IsNull()) {
+ if (AnObject->IsKind(STANDARD_TYPE(NMTDS_ListNodeOfListOfPassKeyBoolean))) {
+ _anOtherObject = Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)((Handle(NMTDS_ListNodeOfListOfPassKeyBoolean)&)AnObject);
+ }
+ }
+
+ return _anOtherObject ;
+}
+const Handle(Standard_Type)& NMTDS_ListNodeOfListOfPassKeyBoolean::DynamicType() const
+{
+ return STANDARD_TYPE(NMTDS_ListNodeOfListOfPassKeyBoolean) ;
+}
+//Standard_Boolean NMTDS_ListNodeOfListOfPassKeyBoolean::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTDS_ListNodeOfListOfPassKeyBoolean) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTDS_ListNodeOfListOfPassKeyBoolean::~Handle_NMTDS_ListNodeOfListOfPassKeyBoolean() {}
+#define Item NMTDS_PassKeyBoolean
+#define Item_hxx <NMTDS_PassKeyBoolean.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKeyBoolean
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKeyBoolean_Type_()
+#define TCollection_List NMTDS_ListOfPassKeyBoolean
+#define TCollection_List_hxx <NMTDS_ListOfPassKeyBoolean.hxx>
+#include <TCollection_ListNode.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_ListNodeOfListOfPassKey.hxx>
+
+#ifndef _Standard_TypeMismatch_HeaderFile
+#include <Standard_TypeMismatch.hxx>
+#endif
+
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+#ifndef _NMTDS_ListOfPassKey_HeaderFile
+#include <NMTDS_ListOfPassKey.hxx>
+#endif
+#ifndef _NMTDS_ListIteratorOfListOfPassKey_HeaderFile
+#include <NMTDS_ListIteratorOfListOfPassKey.hxx>
+#endif
+//NMTDS_ListNodeOfListOfPassKey::~NMTDS_ListNodeOfListOfPassKey() {}
+
+
+
+Standard_EXPORT Handle_Standard_Type& NMTDS_ListNodeOfListOfPassKey_Type_()
+{
+
+ static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
+ static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
+ static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
+
+
+ static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
+ static Handle_Standard_Type _aType = new Standard_Type("NMTDS_ListNodeOfListOfPassKey",
+ sizeof(NMTDS_ListNodeOfListOfPassKey),
+ 1,
+ (Standard_Address)_Ancestors,
+ (Standard_Address)NULL);
+
+ return _aType;
+}
+
+
+// DownCast method
+// allow safe downcasting
+//
+const Handle(NMTDS_ListNodeOfListOfPassKey) Handle(NMTDS_ListNodeOfListOfPassKey)::DownCast(const Handle(Standard_Transient)& AnObject)
+{
+ Handle(NMTDS_ListNodeOfListOfPassKey) _anOtherObject;
+
+ if (!AnObject.IsNull()) {
+ if (AnObject->IsKind(STANDARD_TYPE(NMTDS_ListNodeOfListOfPassKey))) {
+ _anOtherObject = Handle(NMTDS_ListNodeOfListOfPassKey)((Handle(NMTDS_ListNodeOfListOfPassKey)&)AnObject);
+ }
+ }
+
+ return _anOtherObject ;
+}
+const Handle(Standard_Type)& NMTDS_ListNodeOfListOfPassKey::DynamicType() const
+{
+ return STANDARD_TYPE(NMTDS_ListNodeOfListOfPassKey) ;
+}
+//Standard_Boolean NMTDS_ListNodeOfListOfPassKey::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTDS_ListNodeOfListOfPassKey) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTDS_ListNodeOfListOfPassKey::~Handle_NMTDS_ListNodeOfListOfPassKey() {}
+#define Item NMTDS_PassKey
+#define Item_hxx <NMTDS_PassKey.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKey.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKey
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKey.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKey_Type_()
+#define TCollection_List NMTDS_ListOfPassKey
+#define TCollection_List_hxx <NMTDS_ListOfPassKey.hxx>
+#include <TCollection_ListNode.gxx>
+
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors();
+
+
Standard_EXPORT void Assign(const NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors& Other) ;
void operator=(const NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors& Other)
{
Assign(Other);
}
+
+
Standard_EXPORT Standard_Integer Extent() const;
+
+
Standard_EXPORT void Clear() ;
~NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors()
{
Clear();
}
+
Standard_Boolean IsEmpty() const;
+
+
Standard_EXPORT void Prepend(const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& I) ;
+
+
Standard_EXPORT void Prepend(const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& I,NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors& theIt) ;
+
+
Standard_EXPORT void Prepend(NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors& Other) ;
+
+
Standard_EXPORT void Append(const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& I) ;
+
+
Standard_EXPORT void Append(const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& I,NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors& theIt) ;
+
+
Standard_EXPORT void Append(NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors& Other) ;
+
+
Standard_EXPORT BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& First() const;
+
+
Standard_EXPORT BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& Last() const;
+
+
Standard_EXPORT void RemoveFirst() ;
+
+
Standard_EXPORT void Remove(NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors& It) ;
+
+
Standard_EXPORT void InsertBefore(const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& I,NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors& It) ;
+
+
Standard_EXPORT void InsertBefore(NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors& Other,NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors& It) ;
+
+
Standard_EXPORT void InsertAfter(const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& I,NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors& It) ;
+
+
Standard_EXPORT void InsertAfter(NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors& Other,NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors& It) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors(const NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_ListOfPassKey_HeaderFile
+#define _NMTDS_ListOfPassKey_HeaderFile
+
+#ifndef _Standard_Address_HeaderFile
+#include <Standard_Address.hxx>
+#endif
+#ifndef _Handle_NMTDS_ListNodeOfListOfPassKey_HeaderFile
+#include <Handle_NMTDS_ListNodeOfListOfPassKey.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class Standard_NoSuchObject;
+class NMTDS_ListIteratorOfListOfPassKey;
+class NMTDS_PassKey;
+class NMTDS_ListNodeOfListOfPassKey;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_ListOfPassKey {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_ListOfPassKey();
+
+
+Standard_EXPORT void Assign(const NMTDS_ListOfPassKey& Other) ;
+ void operator=(const NMTDS_ListOfPassKey& Other)
+{
+ Assign(Other);
+}
+
+
+
+Standard_EXPORT Standard_Integer Extent() const;
+
+
+Standard_EXPORT void Clear() ;
+~NMTDS_ListOfPassKey()
+{
+ Clear();
+}
+
+
+ Standard_Boolean IsEmpty() const;
+
+
+Standard_EXPORT void Prepend(const NMTDS_PassKey& I) ;
+
+
+Standard_EXPORT void Prepend(const NMTDS_PassKey& I,NMTDS_ListIteratorOfListOfPassKey& theIt) ;
+
+
+Standard_EXPORT void Prepend(NMTDS_ListOfPassKey& Other) ;
+
+
+Standard_EXPORT void Append(const NMTDS_PassKey& I) ;
+
+
+Standard_EXPORT void Append(const NMTDS_PassKey& I,NMTDS_ListIteratorOfListOfPassKey& theIt) ;
+
+
+Standard_EXPORT void Append(NMTDS_ListOfPassKey& Other) ;
+
+
+Standard_EXPORT NMTDS_PassKey& First() const;
+
+
+Standard_EXPORT NMTDS_PassKey& Last() const;
+
+
+Standard_EXPORT void RemoveFirst() ;
+
+
+Standard_EXPORT void Remove(NMTDS_ListIteratorOfListOfPassKey& It) ;
+
+
+Standard_EXPORT void InsertBefore(const NMTDS_PassKey& I,NMTDS_ListIteratorOfListOfPassKey& It) ;
+
+
+Standard_EXPORT void InsertBefore(NMTDS_ListOfPassKey& Other,NMTDS_ListIteratorOfListOfPassKey& It) ;
+
+
+Standard_EXPORT void InsertAfter(const NMTDS_PassKey& I,NMTDS_ListIteratorOfListOfPassKey& It) ;
+
+
+Standard_EXPORT void InsertAfter(NMTDS_ListOfPassKey& Other,NMTDS_ListIteratorOfListOfPassKey& It) ;
+
+
+friend class NMTDS_ListIteratorOfListOfPassKey;
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+Standard_EXPORT NMTDS_ListOfPassKey(const NMTDS_ListOfPassKey& Other);
+
+
+ // Fields PRIVATE
+ //
+Standard_Address myFirst;
+Standard_Address myLast;
+
+
+};
+
+#define Item NMTDS_PassKey
+#define Item_hxx <NMTDS_PassKey.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKey.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKey
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKey.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKey_Type_()
+#define TCollection_List NMTDS_ListOfPassKey
+#define TCollection_List_hxx <NMTDS_ListOfPassKey.hxx>
+
+#include <TCollection_List.lxx>
+
+#undef Item
+#undef Item_hxx
+#undef TCollection_ListNode
+#undef TCollection_ListNode_hxx
+#undef TCollection_ListIterator
+#undef TCollection_ListIterator_hxx
+#undef Handle_TCollection_ListNode
+#undef TCollection_ListNode_Type_
+#undef TCollection_List
+#undef TCollection_List_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_ListOfPassKeyBoolean_HeaderFile
+#define _NMTDS_ListOfPassKeyBoolean_HeaderFile
+
+#ifndef _Standard_Address_HeaderFile
+#include <Standard_Address.hxx>
+#endif
+#ifndef _Handle_NMTDS_ListNodeOfListOfPassKeyBoolean_HeaderFile
+#include <Handle_NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class Standard_NoSuchObject;
+class NMTDS_ListIteratorOfListOfPassKeyBoolean;
+class NMTDS_PassKeyBoolean;
+class NMTDS_ListNodeOfListOfPassKeyBoolean;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_ListOfPassKeyBoolean {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_ListOfPassKeyBoolean();
+
+
+Standard_EXPORT void Assign(const NMTDS_ListOfPassKeyBoolean& Other) ;
+ void operator=(const NMTDS_ListOfPassKeyBoolean& Other)
+{
+ Assign(Other);
+}
+
+
+
+Standard_EXPORT Standard_Integer Extent() const;
+
+
+Standard_EXPORT void Clear() ;
+~NMTDS_ListOfPassKeyBoolean()
+{
+ Clear();
+}
+
+
+ Standard_Boolean IsEmpty() const;
+
+
+Standard_EXPORT void Prepend(const NMTDS_PassKeyBoolean& I) ;
+
+
+Standard_EXPORT void Prepend(const NMTDS_PassKeyBoolean& I,NMTDS_ListIteratorOfListOfPassKeyBoolean& theIt) ;
+
+
+Standard_EXPORT void Prepend(NMTDS_ListOfPassKeyBoolean& Other) ;
+
+
+Standard_EXPORT void Append(const NMTDS_PassKeyBoolean& I) ;
+
+
+Standard_EXPORT void Append(const NMTDS_PassKeyBoolean& I,NMTDS_ListIteratorOfListOfPassKeyBoolean& theIt) ;
+
+
+Standard_EXPORT void Append(NMTDS_ListOfPassKeyBoolean& Other) ;
+
+
+Standard_EXPORT NMTDS_PassKeyBoolean& First() const;
+
+
+Standard_EXPORT NMTDS_PassKeyBoolean& Last() const;
+
+
+Standard_EXPORT void RemoveFirst() ;
+
+
+Standard_EXPORT void Remove(NMTDS_ListIteratorOfListOfPassKeyBoolean& It) ;
+
+
+Standard_EXPORT void InsertBefore(const NMTDS_PassKeyBoolean& I,NMTDS_ListIteratorOfListOfPassKeyBoolean& It) ;
+
+
+Standard_EXPORT void InsertBefore(NMTDS_ListOfPassKeyBoolean& Other,NMTDS_ListIteratorOfListOfPassKeyBoolean& It) ;
+
+
+Standard_EXPORT void InsertAfter(const NMTDS_PassKeyBoolean& I,NMTDS_ListIteratorOfListOfPassKeyBoolean& It) ;
+
+
+Standard_EXPORT void InsertAfter(NMTDS_ListOfPassKeyBoolean& Other,NMTDS_ListIteratorOfListOfPassKeyBoolean& It) ;
+
+
+friend class NMTDS_ListIteratorOfListOfPassKeyBoolean;
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+Standard_EXPORT NMTDS_ListOfPassKeyBoolean(const NMTDS_ListOfPassKeyBoolean& Other);
+
+
+ // Fields PRIVATE
+ //
+Standard_Address myFirst;
+Standard_Address myLast;
+
+
+};
+
+#define Item NMTDS_PassKeyBoolean
+#define Item_hxx <NMTDS_PassKeyBoolean.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKeyBoolean
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKeyBoolean_Type_()
+#define TCollection_List NMTDS_ListOfPassKeyBoolean
+#define TCollection_List_hxx <NMTDS_ListOfPassKeyBoolean.hxx>
+
+#include <TCollection_List.lxx>
+
+#undef Item
+#undef Item_hxx
+#undef TCollection_ListNode
+#undef TCollection_ListNode_hxx
+#undef TCollection_ListIterator
+#undef TCollection_ListIterator_hxx
+#undef Handle_TCollection_ListNode
+#undef TCollection_ListNode_Type_
+#undef TCollection_List
+#undef TCollection_List_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_ListOfPassKeyBoolean.hxx>
+
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _NMTDS_ListIteratorOfListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#include <NMTDS_PassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_ListNodeOfListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#endif
+
+
+#define Item NMTDS_PassKeyBoolean
+#define Item_hxx <NMTDS_PassKeyBoolean.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKeyBoolean.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKeyBoolean
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKeyBoolean
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKeyBoolean_Type_()
+#define TCollection_List NMTDS_ListOfPassKeyBoolean
+#define TCollection_List_hxx <NMTDS_ListOfPassKeyBoolean.hxx>
+#include <TCollection_List.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_ListOfPassKey.hxx>
+
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _NMTDS_ListIteratorOfListOfPassKey_HeaderFile
+#include <NMTDS_ListIteratorOfListOfPassKey.hxx>
+#endif
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+#ifndef _NMTDS_ListNodeOfListOfPassKey_HeaderFile
+#include <NMTDS_ListNodeOfListOfPassKey.hxx>
+#endif
+
+
+#define Item NMTDS_PassKey
+#define Item_hxx <NMTDS_PassKey.hxx>
+#define TCollection_ListNode NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_hxx <NMTDS_ListNodeOfListOfPassKey.hxx>
+#define TCollection_ListIterator NMTDS_ListIteratorOfListOfPassKey
+#define TCollection_ListIterator_hxx <NMTDS_ListIteratorOfListOfPassKey.hxx>
+#define Handle_TCollection_ListNode Handle_NMTDS_ListNodeOfListOfPassKey
+#define TCollection_ListNode_Type_() NMTDS_ListNodeOfListOfPassKey_Type_()
+#define TCollection_List NMTDS_ListOfPassKey
+#define TCollection_List_hxx <NMTDS_ListOfPassKey.hxx>
+#include <TCollection_List.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_MapIteratorOfMapOfPassKey_HeaderFile
+#define _NMTDS_MapIteratorOfMapOfPassKey_HeaderFile
+
+#ifndef _TCollection_BasicMapIterator_HeaderFile
+#include <TCollection_BasicMapIterator.hxx>
+#endif
+#ifndef _Handle_NMTDS_StdMapNodeOfMapOfPassKey_HeaderFile
+#include <Handle_NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+#endif
+class Standard_NoSuchObject;
+class NMTDS_PassKey;
+class NMTDS_PassKeyMapHasher;
+class NMTDS_MapOfPassKey;
+class NMTDS_StdMapNodeOfMapOfPassKey;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_MapIteratorOfMapOfPassKey : public TCollection_BasicMapIterator {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_MapIteratorOfMapOfPassKey();
+
+
+Standard_EXPORT NMTDS_MapIteratorOfMapOfPassKey(const NMTDS_MapOfPassKey& aMap);
+
+
+Standard_EXPORT void Initialize(const NMTDS_MapOfPassKey& aMap) ;
+
+
+Standard_EXPORT const NMTDS_PassKey& Key() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_MapIteratorOfMapOfPassKeyBoolean_HeaderFile
+#define _NMTDS_MapIteratorOfMapOfPassKeyBoolean_HeaderFile
+
+#ifndef _TCollection_BasicMapIterator_HeaderFile
+#include <TCollection_BasicMapIterator.hxx>
+#endif
+#ifndef _Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean_HeaderFile
+#include <Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+#endif
+class Standard_NoSuchObject;
+class NMTDS_PassKeyBoolean;
+class NMTDS_PassKeyMapHasher;
+class NMTDS_MapOfPassKeyBoolean;
+class NMTDS_StdMapNodeOfMapOfPassKeyBoolean;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_MapIteratorOfMapOfPassKeyBoolean : public TCollection_BasicMapIterator {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_MapIteratorOfMapOfPassKeyBoolean();
+
+
+Standard_EXPORT NMTDS_MapIteratorOfMapOfPassKeyBoolean(const NMTDS_MapOfPassKeyBoolean& aMap);
+
+
+Standard_EXPORT void Initialize(const NMTDS_MapOfPassKeyBoolean& aMap) ;
+
+
+Standard_EXPORT const NMTDS_PassKeyBoolean& Key() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_MapIteratorOfMapOfPassKeyBoolean.hxx>
+
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#include <NMTDS_PassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_PassKeyMapHasher_HeaderFile
+#include <NMTDS_PassKeyMapHasher.hxx>
+#endif
+#ifndef _NMTDS_MapOfPassKeyBoolean_HeaderFile
+#include <NMTDS_MapOfPassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_StdMapNodeOfMapOfPassKeyBoolean_HeaderFile
+#include <NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+#endif
+
+
+#define TheKey NMTDS_PassKeyBoolean
+#define TheKey_hxx <NMTDS_PassKeyBoolean.hxx>
+#define Hasher NMTDS_PassKeyMapHasher
+#define Hasher_hxx <NMTDS_PassKeyMapHasher.hxx>
+#define TCollection_StdMapNode NMTDS_StdMapNodeOfMapOfPassKeyBoolean
+#define TCollection_StdMapNode_hxx <NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+#define TCollection_MapIterator NMTDS_MapIteratorOfMapOfPassKeyBoolean
+#define TCollection_MapIterator_hxx <NMTDS_MapIteratorOfMapOfPassKeyBoolean.hxx>
+#define Handle_TCollection_StdMapNode Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean
+#define TCollection_StdMapNode_Type_() NMTDS_StdMapNodeOfMapOfPassKeyBoolean_Type_()
+#define TCollection_Map NMTDS_MapOfPassKeyBoolean
+#define TCollection_Map_hxx <NMTDS_MapOfPassKeyBoolean.hxx>
+#include <TCollection_MapIterator.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_MapIteratorOfMapOfPassKey.hxx>
+
+#ifndef _Standard_NoSuchObject_HeaderFile
+#include <Standard_NoSuchObject.hxx>
+#endif
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+#ifndef _NMTDS_PassKeyMapHasher_HeaderFile
+#include <NMTDS_PassKeyMapHasher.hxx>
+#endif
+#ifndef _NMTDS_MapOfPassKey_HeaderFile
+#include <NMTDS_MapOfPassKey.hxx>
+#endif
+#ifndef _NMTDS_StdMapNodeOfMapOfPassKey_HeaderFile
+#include <NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+#endif
+
+
+#define TheKey NMTDS_PassKey
+#define TheKey_hxx <NMTDS_PassKey.hxx>
+#define Hasher NMTDS_PassKeyMapHasher
+#define Hasher_hxx <NMTDS_PassKeyMapHasher.hxx>
+#define TCollection_StdMapNode NMTDS_StdMapNodeOfMapOfPassKey
+#define TCollection_StdMapNode_hxx <NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+#define TCollection_MapIterator NMTDS_MapIteratorOfMapOfPassKey
+#define TCollection_MapIterator_hxx <NMTDS_MapIteratorOfMapOfPassKey.hxx>
+#define Handle_TCollection_StdMapNode Handle_NMTDS_StdMapNodeOfMapOfPassKey
+#define TCollection_StdMapNode_Type_() NMTDS_StdMapNodeOfMapOfPassKey_Type_()
+#define TCollection_Map NMTDS_MapOfPassKey
+#define TCollection_Map_hxx <NMTDS_MapOfPassKey.hxx>
+#include <TCollection_MapIterator.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_MapOfPassKey_HeaderFile
+#define _NMTDS_MapOfPassKey_HeaderFile
+
+#ifndef _TCollection_BasicMap_HeaderFile
+#include <TCollection_BasicMap.hxx>
+#endif
+#ifndef _Handle_NMTDS_StdMapNodeOfMapOfPassKey_HeaderFile
+#include <Handle_NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class Standard_DomainError;
+class NMTDS_PassKey;
+class NMTDS_PassKeyMapHasher;
+class NMTDS_StdMapNodeOfMapOfPassKey;
+class NMTDS_MapIteratorOfMapOfPassKey;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_MapOfPassKey : public TCollection_BasicMap {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_MapOfPassKey(const Standard_Integer NbBuckets = 1);
+
+
+Standard_EXPORT NMTDS_MapOfPassKey& Assign(const NMTDS_MapOfPassKey& Other) ;
+ NMTDS_MapOfPassKey& operator =(const NMTDS_MapOfPassKey& Other)
+{
+ return Assign(Other);
+}
+
+
+
+Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
+Standard_EXPORT void Clear() ;
+~NMTDS_MapOfPassKey()
+{
+ Clear();
+}
+
+
+
+Standard_EXPORT Standard_Boolean Add(const NMTDS_PassKey& aKey) ;
+
+
+Standard_EXPORT Standard_Boolean Contains(const NMTDS_PassKey& aKey) const;
+
+
+Standard_EXPORT Standard_Boolean Remove(const NMTDS_PassKey& aKey) ;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+Standard_EXPORT NMTDS_MapOfPassKey(const NMTDS_MapOfPassKey& Other);
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_MapOfPassKeyBoolean_HeaderFile
+#define _NMTDS_MapOfPassKeyBoolean_HeaderFile
+
+#ifndef _TCollection_BasicMap_HeaderFile
+#include <TCollection_BasicMap.hxx>
+#endif
+#ifndef _Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean_HeaderFile
+#include <Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class Standard_DomainError;
+class NMTDS_PassKeyBoolean;
+class NMTDS_PassKeyMapHasher;
+class NMTDS_StdMapNodeOfMapOfPassKeyBoolean;
+class NMTDS_MapIteratorOfMapOfPassKeyBoolean;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_MapOfPassKeyBoolean : public TCollection_BasicMap {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_MapOfPassKeyBoolean(const Standard_Integer NbBuckets = 1);
+
+
+Standard_EXPORT NMTDS_MapOfPassKeyBoolean& Assign(const NMTDS_MapOfPassKeyBoolean& Other) ;
+ NMTDS_MapOfPassKeyBoolean& operator =(const NMTDS_MapOfPassKeyBoolean& Other)
+{
+ return Assign(Other);
+}
+
+
+
+Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
+Standard_EXPORT void Clear() ;
+~NMTDS_MapOfPassKeyBoolean()
+{
+ Clear();
+}
+
+
+
+Standard_EXPORT Standard_Boolean Add(const NMTDS_PassKeyBoolean& aKey) ;
+
+
+Standard_EXPORT Standard_Boolean Contains(const NMTDS_PassKeyBoolean& aKey) const;
+
+
+Standard_EXPORT Standard_Boolean Remove(const NMTDS_PassKeyBoolean& aKey) ;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+Standard_EXPORT NMTDS_MapOfPassKeyBoolean(const NMTDS_MapOfPassKeyBoolean& Other);
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_MapOfPassKeyBoolean.hxx>
+
+#ifndef _Standard_DomainError_HeaderFile
+#include <Standard_DomainError.hxx>
+#endif
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#include <NMTDS_PassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_PassKeyMapHasher_HeaderFile
+#include <NMTDS_PassKeyMapHasher.hxx>
+#endif
+#ifndef _NMTDS_StdMapNodeOfMapOfPassKeyBoolean_HeaderFile
+#include <NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_MapIteratorOfMapOfPassKeyBoolean_HeaderFile
+#include <NMTDS_MapIteratorOfMapOfPassKeyBoolean.hxx>
+#endif
+
+
+#define TheKey NMTDS_PassKeyBoolean
+#define TheKey_hxx <NMTDS_PassKeyBoolean.hxx>
+#define Hasher NMTDS_PassKeyMapHasher
+#define Hasher_hxx <NMTDS_PassKeyMapHasher.hxx>
+#define TCollection_StdMapNode NMTDS_StdMapNodeOfMapOfPassKeyBoolean
+#define TCollection_StdMapNode_hxx <NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+#define TCollection_MapIterator NMTDS_MapIteratorOfMapOfPassKeyBoolean
+#define TCollection_MapIterator_hxx <NMTDS_MapIteratorOfMapOfPassKeyBoolean.hxx>
+#define Handle_TCollection_StdMapNode Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean
+#define TCollection_StdMapNode_Type_() NMTDS_StdMapNodeOfMapOfPassKeyBoolean_Type_()
+#define TCollection_Map NMTDS_MapOfPassKeyBoolean
+#define TCollection_Map_hxx <NMTDS_MapOfPassKeyBoolean.hxx>
+#include <TCollection_Map.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_MapOfPassKey.hxx>
+
+#ifndef _Standard_DomainError_HeaderFile
+#include <Standard_DomainError.hxx>
+#endif
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+#ifndef _NMTDS_PassKeyMapHasher_HeaderFile
+#include <NMTDS_PassKeyMapHasher.hxx>
+#endif
+#ifndef _NMTDS_StdMapNodeOfMapOfPassKey_HeaderFile
+#include <NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+#endif
+#ifndef _NMTDS_MapIteratorOfMapOfPassKey_HeaderFile
+#include <NMTDS_MapIteratorOfMapOfPassKey.hxx>
+#endif
+
+
+#define TheKey NMTDS_PassKey
+#define TheKey_hxx <NMTDS_PassKey.hxx>
+#define Hasher NMTDS_PassKeyMapHasher
+#define Hasher_hxx <NMTDS_PassKeyMapHasher.hxx>
+#define TCollection_StdMapNode NMTDS_StdMapNodeOfMapOfPassKey
+#define TCollection_StdMapNode_hxx <NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+#define TCollection_MapIterator NMTDS_MapIteratorOfMapOfPassKey
+#define TCollection_MapIterator_hxx <NMTDS_MapIteratorOfMapOfPassKey.hxx>
+#define Handle_TCollection_StdMapNode Handle_NMTDS_StdMapNodeOfMapOfPassKey
+#define TCollection_StdMapNode_Type_() NMTDS_StdMapNodeOfMapOfPassKey_Type_()
+#define TCollection_Map NMTDS_MapOfPassKey
+#define TCollection_Map_hxx <NMTDS_MapOfPassKey.hxx>
+#include <TCollection_Map.gxx>
+
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
--- /dev/null
+-- Copyright (C) 2006 SAMTECH
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: NMTDS_PassKey.cdl
+-- Created:
+-- Author: Peter KURNEV
+-- <pkv@irinox>
+
+class PassKey from NMTDS
+
+ ---Purpose:
+
+uses
+ Shape from TopoDS,
+ ListOfInteger from TColStd
+
+--raises
+
+is
+ Create
+ returns PassKey from NMTDS;
+
+ Assign(me:out;
+ Other : PassKey from NMTDS)
+ returns PassKey from NMTDS;
+ ---C++: alias operator =
+ ---C++: return &
+--
+ SetIds(me:out;
+ aI1 :Integer from Standard;
+ aI2 :Integer from Standard);
+
+ NbMax(me)
+ returns Integer from Standard;
+
+ Clear(me:out);
+
+ Compute(me:out);
+
+ IsEqual(me;
+ aOther:PassKey from NMTDS)
+ returns Boolean from Standard;
+
+ Key(me)
+ returns Address from Standard;
+
+ HashCode(me;
+ Upper : Integer from Standard)
+ returns Integer from Standard;
+
+
+ Ids(me;
+ aI1 :out Integer from Standard;
+ aI2 :out Integer from Standard);
+
+ Dump(me);
+
+fields
+
+ myNbIds: Integer from Standard is protected;
+ myNbMax: Integer from Standard is protected;
+ mySum : Integer from Standard is protected;
+ myIds : Integer from Standard [2] is protected;
+
+end PassKey;
--- /dev/null
+// Copyright (C) 2006 SAMTECH
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: NMTDS_PassKey.cxx
+// Created:
+// Author: Peter KURNEV
+// <pkv@irinox>
+
+
+#include <NMTDS_PassKey.ixx>
+
+#include <stdio.h>
+#include <string.h>
+#include <TColStd_ListIteratorOfListOfInteger.hxx>
+
+#ifdef WNT
+#pragma warning( disable : 4101)
+#endif
+
+static
+ void SortShell(const int n, int* a);
+static
+ Standard_Integer NormalizedId(const Standard_Integer aId,
+ const Standard_Integer aDiv);
+
+//=======================================================================
+//function :
+//purpose :
+//=======================================================================
+ NMTDS_PassKey::NMTDS_PassKey()
+{
+ Clear();
+}
+//=======================================================================
+//function :Assign
+//purpose :
+//=======================================================================
+ NMTDS_PassKey& NMTDS_PassKey::Assign(const NMTDS_PassKey& anOther)
+{
+ myNbIds=anOther.myNbIds;
+ myNbMax=anOther.myNbMax;
+ mySum=anOther.mySum;
+ memcpy(myIds, anOther.myIds, sizeof(myIds));
+ return *this;
+}
+//=======================================================================
+//function :Clear
+//purpose :
+//=======================================================================
+ void NMTDS_PassKey::Clear()
+{
+ Standard_Integer i;
+ //
+ myNbIds=0;
+ myNbMax=2;
+ mySum=0;
+ for (i=0; i<myNbMax; ++i) {
+ myIds[i]=0;
+ }
+}
+//=======================================================================
+//function :SetIds
+//purpose :
+//=======================================================================
+ void NMTDS_PassKey::SetIds(const Standard_Integer anId1,
+ const Standard_Integer anId2)
+{
+ Standard_Integer aIdN1, aIdN2;
+ //
+ myNbIds=2;
+ aIdN1=NormalizedId(anId1, myNbIds);
+ aIdN2=NormalizedId(anId2, myNbIds);
+ mySum=aIdN1+aIdN2;
+ //
+ if (anId1<anId2) {
+ myIds[myNbMax-2]=anId1;
+ myIds[myNbMax-1]=anId2;
+ return;
+ }
+ myIds[myNbMax-2]=anId2;
+ myIds[myNbMax-1]=anId1;
+}
+//=======================================================================
+//function :Ids
+//purpose :
+//=======================================================================
+ void NMTDS_PassKey::Ids(Standard_Integer& aId1,
+ Standard_Integer& aId2)const
+{
+ aId1=myIds[0];
+ aId2=myIds[1];
+}
+//=======================================================================
+//function :NbMax
+//purpose :
+//=======================================================================
+ Standard_Integer NMTDS_PassKey::NbMax()const
+{
+ return myNbMax;
+}
+//=======================================================================
+//function :Compute
+//purpose :
+//=======================================================================
+ void NMTDS_PassKey::Compute()
+{
+ SortShell(myNbIds, myIds+myNbMax-myNbIds);
+}
+//=======================================================================
+//function :IsEqual
+//purpose :
+//=======================================================================
+ Standard_Boolean NMTDS_PassKey::IsEqual(const NMTDS_PassKey& anOther) const
+{
+ Standard_Integer iIsEqual;
+ Standard_Boolean bIsEqual;
+ //
+ iIsEqual=memcmp(myIds, anOther.myIds, sizeof(myIds));
+ bIsEqual=Standard_False;
+ if (!iIsEqual) {
+ bIsEqual=!bIsEqual;
+ }
+ return bIsEqual;
+}
+//=======================================================================
+//function :Key
+//purpose :
+//=======================================================================
+ Standard_Address NMTDS_PassKey::Key()const
+{
+ return (Standard_Address)myIds;
+}
+//=======================================================================
+//function : HashCode
+//purpose :
+//=======================================================================
+ Standard_Integer NMTDS_PassKey::HashCode(const Standard_Integer Upper) const
+{
+ return ::HashCode(mySum, Upper);
+}
+//=======================================================================
+//function : Dump
+//purpose :
+//=======================================================================
+ void NMTDS_PassKey::Dump()const
+{
+ Standard_Integer i;
+ //
+ printf(" PassKey: {");
+ for (i=0; i<myNbMax; ++i) {
+ printf(" %d", myIds[i]);
+ }
+ printf(" }");
+}
+//=======================================================================
+// function: NormalizedId
+// purpose :
+//=======================================================================
+Standard_Integer NormalizedId(const Standard_Integer aId,
+ const Standard_Integer aDiv)
+{
+ Standard_Integer aMax, aTresh, aIdRet;
+ //
+ aIdRet=aId;
+ aMax=::IntegerLast();
+ aTresh=aMax/aDiv;
+ if (aId>aTresh) {
+ aIdRet=aId%aTresh;
+ }
+ return aIdRet;
+}
+//=======================================================================
+// function: SortShell
+// purpose :
+//=======================================================================
+void SortShell(const int n, int* a)
+{
+ int x, nd, i, j, l, d=1;
+ //
+ while(d<=n) {
+ d*=2;
+ }
+ //
+ while (d) {
+ d=(d-1)/2;
+ //
+ nd=n-d;
+ for (i=0; i<nd; ++i) {
+ j=i;
+ m30:;
+ l=j+d;
+ if (a[l] < a[j]){
+ x=a[j];
+ a[j]=a[l];
+ a[l]=x;
+ j-=d;
+ if (j > -1) goto m30;
+ }//if (a[l] < a[j]){
+ }//for (i=0; i<nd; ++i)
+ }//while (1)
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_PassKey_HeaderFile
+#define _NMTDS_PassKey_HeaderFile
+
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+#ifndef _Standard_Address_HeaderFile
+#include <Standard_Address.hxx>
+#endif
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_PassKey {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_PassKey();
+
+
+Standard_EXPORT NMTDS_PassKey& Assign(const NMTDS_PassKey& Other) ;
+ NMTDS_PassKey& operator =(const NMTDS_PassKey& Other)
+{
+ return Assign(Other);
+}
+
+
+
+Standard_EXPORT void SetIds(const Standard_Integer aI1,const Standard_Integer aI2) ;
+
+
+Standard_EXPORT Standard_Integer NbMax() const;
+
+
+Standard_EXPORT void Clear() ;
+
+
+Standard_EXPORT void Compute() ;
+
+
+Standard_EXPORT Standard_Boolean IsEqual(const NMTDS_PassKey& aOther) const;
+
+
+Standard_EXPORT Standard_Address Key() const;
+
+
+Standard_EXPORT Standard_Integer HashCode(const Standard_Integer Upper) const;
+
+
+Standard_EXPORT void Ids(Standard_Integer& aI1,Standard_Integer& aI2) const;
+
+
+Standard_EXPORT void Dump() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+Standard_Integer myNbIds;
+Standard_Integer myNbMax;
+Standard_Integer mySum;
+Standard_Integer myIds[2];
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_PassKey.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
--- /dev/null
+-- Copyright (C) 2006 SAMTECH
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: NMTDS_PassKeyBoolean.cdl
+-- Created:
+-- Author: Peter KURNEV
+-- <pkv@irinox>
+
+
+class PassKeyBoolean from NMTDS
+ inherits PassKey from NMTDS
+
+ ---Purpose:
+
+uses
+ Shape from TopoDS,
+ ListOfInteger from TColStd
+
+--raises
+
+is
+ Create
+ returns PassKeyBoolean from NMTDS;
+
+ Assign(me:out;
+ Other : PassKeyBoolean from NMTDS)
+ returns PassKeyBoolean from NMTDS;
+ ---C++: alias operator =
+ ---C++: return &
+--
+ SetFlag(me:out;
+ aFlag: Boolean from Standard);
+
+ Flag(me)
+ returns Boolean from Standard;
+
+fields
+
+ myFlag: Boolean from Standard is protected;
+
+end PassKeyBoolean;
--- /dev/null
+// Copyright (C) 2006 SAMTECH
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: NMTDS_PassKeyBoolean.cxx
+// Created: Mon May 15 14:31:05 2006
+// Author: Peter KURNEV
+// <pkv@irinox>
+
+
+#include <NMTDS_PassKeyBoolean.ixx>
+
+//=======================================================================
+//function : NMTDS_PassKeyBoolean
+//purpose :
+//=======================================================================
+ NMTDS_PassKeyBoolean::NMTDS_PassKeyBoolean()
+:
+ myFlag(Standard_False),
+ NMTDS_PassKey()
+{
+}
+//=======================================================================
+//function :Assign
+//purpose :
+//=======================================================================
+ NMTDS_PassKeyBoolean& NMTDS_PassKeyBoolean::Assign(const NMTDS_PassKeyBoolean& anOther)
+{
+ myFlag=anOther.myFlag;
+ NMTDS_PassKey::Assign(anOther);
+ return *this;
+}
+//=======================================================================
+//function :SetFlag
+//purpose :
+//=======================================================================
+ void NMTDS_PassKeyBoolean::SetFlag(const Standard_Boolean aFlag)
+{
+ myFlag=aFlag;
+}
+//=======================================================================
+//function :Flag
+//purpose :
+//=======================================================================
+ Standard_Boolean NMTDS_PassKeyBoolean::Flag()const
+{
+ return myFlag;
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#define _NMTDS_PassKeyBoolean_HeaderFile
+
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_PassKeyBoolean : public NMTDS_PassKey {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_PassKeyBoolean();
+
+
+Standard_EXPORT NMTDS_PassKeyBoolean& Assign(const NMTDS_PassKeyBoolean& Other) ;
+ NMTDS_PassKeyBoolean& operator =(const NMTDS_PassKeyBoolean& Other)
+{
+ return Assign(Other);
+}
+
+
+
+Standard_EXPORT void SetFlag(const Standard_Boolean aFlag) ;
+
+
+Standard_EXPORT Standard_Boolean Flag() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+Standard_Boolean myFlag;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_PassKeyBoolean.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#include <NMTDS_PassKeyBoolean.hxx>
+#endif
--- /dev/null
+-- Copyright (C) 2006 SAMTECH
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
+-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+--
+-- File: NMTDS_PassKeyMapHasher.cdl
+-- Created:
+-- Author: Peter KURNEV
+-- <pkv@irinox>
+
+
+class PassKeyMapHasher from NMTDS
+
+ ---Purpose:
+
+uses
+ PassKey from NMTDS
+
+--raises
+
+is
+ HashCode(myclass;
+ aPKey : PassKey from NMTDS;
+ Upper : Integer from Standard)
+ returns Integer from Standard;
+
+
+ IsEqual(myclass;
+ aPKey1 : PassKey from NMTDS;
+ aPKey2 : PassKey from NMTDS)
+ returns Boolean from Standard;
+
+end PassKeyMapHasher;
--- /dev/null
+// Copyright (C) 2006 SAMTECH
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+//
+// File: NMTDS_PassKeyMapHasher.cxx
+// Created:
+// Author: Peter KURNEV
+// <pkv@irinox>
+
+
+#include <NMTDS_PassKeyMapHasher.ixx>
+
+//=======================================================================
+//function : HashCode
+//purpose :
+//=======================================================================
+ Standard_Integer NMTDS_PassKeyMapHasher::HashCode(const NMTDS_PassKey& aPKey,
+ const Standard_Integer Upper)
+{
+ return aPKey.HashCode(Upper);
+}
+//=======================================================================
+//function :IsEqual
+//purpose :
+//=======================================================================
+ Standard_Boolean NMTDS_PassKeyMapHasher::IsEqual(const NMTDS_PassKey& aPKey1,
+ const NMTDS_PassKey& aPKey2)
+{
+ return aPKey1.IsEqual(aPKey2);
+}
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_PassKeyMapHasher_HeaderFile
+#define _NMTDS_PassKeyMapHasher_HeaderFile
+
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class NMTDS_PassKey;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_PassKeyMapHasher {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT static Standard_Integer HashCode(const NMTDS_PassKey& aPKey,const Standard_Integer Upper) ;
+
+
+Standard_EXPORT static Standard_Boolean IsEqual(const NMTDS_PassKey& aPKey1,const NMTDS_PassKey& aPKey2) ;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_PassKeyMapHasher.jxx>
+
+
+
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+#ifndef _NMTDS_PassKeyMapHasher_HeaderFile
+#include <NMTDS_PassKeyMapHasher.hxx>
+#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTDS_ShapesDataStructure.cdl
-- Created: Mon Dec 1 10:17:05 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
-
class ShapesDataStructure from NMTDS
inherits ShapesDataStructure from BooleanOperations
---Purpose:
uses
- Shape from TopoDS,
+ Shape from TopoDS,
+ IndexedDataMapOfShapeAncestorsSuccessors from BooleanOperations,
CArray1OfIndexRange from NMTDS,
IndexedDataMapOfIntegerIndexedDataMapOfShapeInteger from NMTDS
--raises
is
Create
returns ShapesDataStructure from NMTDS;
- ---C++: alias "Standard_EXPORT virtual ~NMTDS_ShapesDataStructure();"
---modified by NIZNHY-PKV Wed Feb 2 11:44:38 2005ft
-
+
SetCompositeShape(me:out;
aS:Shape from TopoDS);
aS:Shape from TopoDS;
iRank:Integer from Standard)
returns Integer from Standard
- is redefined;
+ is redefined;
+
+-- Modified to Add new methods Thu Sep 14 14:35:18 2006
+-- Contribution of Samtech www.samcef.com BEGIN
+ FillMap (me;
+ aS :Shape from TopoDS;
+ aMSA: out IndexedDataMapOfShapeAncestorsSuccessors from BooleanOperations;
+ aMS : out IndexedDataMapOfShapeAncestorsSuccessors from BooleanOperations);
+
+ FillSubshapes (me;
+ aS :Shape from TopoDS;
+ aMSA:out IndexedDataMapOfShapeAncestorsSuccessors from BooleanOperations;
+ aMS :out IndexedDataMapOfShapeAncestorsSuccessors from BooleanOperations);
+-- Contribution of Samtech www.samcef.com END
+
fields
myCompositeShape: Shape from TopoDS is protected;
myRanges : CArray1OfIndexRange from NMTDS is protected;
#include <NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors.hxx>
#include <BooleanOperations_ShapeAndInterferences.hxx>
#include <NMTDS_IndexRange.hxx>
+//
+#include <BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors.hxx>
+#include <BooleanOperations_AncestorsSeqAndSuccessorsSeq.hxx>
+#include <TColStd_MapOfInteger.hxx>
//===========================================================================
//function : NMTDS_ShapesDataStructure::NMTDS_ShapesDataStructure
NMTDS_ShapesDataStructure::NMTDS_ShapesDataStructure()
:
BooleanOperations_ShapesDataStructure()
-{
- //printf(" NMTDS_ShapesDataStructure CREATE:%x\n", (int)this);
-}
-//modified by NIZNHY-PKV Wed Feb 2 11:45:04 2005f
-//===========================================================================
-//function : ~
-//purpose :
-//===========================================================================
- NMTDS_ShapesDataStructure::~NMTDS_ShapesDataStructure()
-{
- //printf(" NMTDS_ShapesDataStructure DELETE:%x\n", (int)this);
-}
-//modified by NIZNHY-PKV Wed Feb 2 11:45:06 2005t
+{}
//===========================================================================
//function : SetCompositeShape
//purpose :
{
return myRanges;
}
+// Modified to Add new methods Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+//===========================================================================
+//function : FillMap
+//purpose :
+//===========================================================================
+ void NMTDS_ShapesDataStructure::FillMap
+ (const TopoDS_Shape& aS,
+ BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aMSA,
+ BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aMS) const
+{
+ Standard_Integer iX, i, j, aIndex, aNbSc, aNbS;
+ BooleanOperations_AncestorsSeqAndSuccessorsSeq aAS;
+ //
+ aMSA.Add(aS, aAS);
+ aMS.Add(aS, aAS);
+ FillSubshapes(aS, aMSA, aMS);
+ //
+ aNbS=aMS.Extent();
+ for(i=1; i<=aNbS; ++i) {
+ TColStd_MapOfInteger aMFence;
+ //
+ const TopoDS_Shape& aSX=aMS.FindKey(i);
+ iX=aMSA.FindIndex(aSX);
+ const BooleanOperations_AncestorsSeqAndSuccessorsSeq& aAS1=aMSA(iX);
+ //
+ aNbSc=aAS1.NumberOfSuccessors();
+ for(j=1; j<=aNbSc; ++j) {
+ aIndex=aAS1.GetSuccessor(j);
+ if(aMFence.Add(aIndex)) {
+ BooleanOperations_AncestorsSeqAndSuccessorsSeq& aAS2=aMSA.ChangeFromIndex(aIndex);
+ aAS2.SetNewAncestor(iX);
+ }
+ }
+ }
+}
+//===========================================================================
+//function : FillSubshapes
+//purpose :
+//===========================================================================
+ void NMTDS_ShapesDataStructure::FillSubshapes
+ (const TopoDS_Shape& aS,
+ BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aMSA,
+ BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aMS) const
+{
+ Standard_Boolean bIsNewSubShape;
+ Standard_Integer aIndexSubShape, aIndex;
+ BooleanOperations_AncestorsSeqAndSuccessorsSeq aASx;
+ //
+ aIndex=aMSA.FindIndex(aS);
+ BooleanOperations_AncestorsSeqAndSuccessorsSeq& aAS=aMSA.ChangeFromIndex(aIndex);
+ //
+ TopoDS_Iterator anIt(aS, Standard_True);
+ for(; anIt.More(); anIt.Next()) {
+ const TopoDS_Shape& aSubShape = anIt.Value();
+ bIsNewSubShape = Standard_False;
+ if(!aMSA.Contains(aSubShape)) {
+ bIsNewSubShape=!bIsNewSubShape;
+ aIndexSubShape=aMSA.Add(aSubShape, aASx);
+ aMS.Add(aSubShape, aASx);
+ }
+ else {
+ aIndexSubShape=aMSA.FindIndex(aSubShape);
+ }
+ aAS.SetNewSuccessor(aIndexSubShape);
+ aAS.SetNewOrientation(aSubShape.Orientation());
+ //
+ if(bIsNewSubShape && (aSubShape.ShapeType() != TopAbs_VERTEX)) {
+ FillSubshapes(aSubShape, aMSA, aMS);
+ }
+ }
+}
+// Contribution of Samtech www.samcef.com END
//===========================================================================
//function : Init
//purpose :
NMTDS_ListOfIndexedDataMapOfShapeAncestorsSuccessors aLx;
NMTDS_ListIteratorOfListOfIndexedDataMapOfShapeAncestorsSuccessors aLit;
TopoDS_Iterator anIt;
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors aMSA;
+ // Contribution of Samtech www.samcef.com END
//
- aNbS=0;
anIt.Initialize(myCompositeShape);
for (i=0; anIt.More(); anIt.Next(), ++i) {
- const TopoDS_Shape& aSx=anIt.Value();
- BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors aIndDatMapShape;
- FillIndexedMapOfShapesAncestorsAndSuccessors(aSx, aIndDatMapShape);
- aNbSx=aIndDatMapShape.Extent();
- aNbS+=aNbSx;
- aLx.Append(aIndDatMapShape);
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ const TopoDS_Shape& aSx=anIt.Value();
+ BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors aMS;
+ FillMap(aSx, aMSA, aMS);
+ aLx.Append(aMS);
+ // Contribution of Samtech www.samcef.com END
}
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ aNbS=aMSA.Extent();
+ // Contribution of Samtech www.samcef.com END
//
// Fill myRanges
myRanges.Resize(i);
aLit.Initialize(aLx);
for (i=1; aLit.More(); aLit.Next(), ++i) {
- const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aM=aLit.Value();
- aNbSx=aM.Extent();
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aMSx=aLit.Value();
+ aNbSx=aMSx.Extent();
+ // Contribution of Samtech www.samcef.com END
if (i==1) {
iFirst=1;
iLast=aNbSx;
}
//
myNumberOfShapesOfTheObject=aNbS;
- myNumberOfShapesOfTheTool=aNbS;
- myLength=3*aNbS;
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ //myNumberOfShapesOfTheTool=aNbS;
+ //myLength=3*aNbS;
+ myNumberOfShapesOfTheTool=0;
+ myLength=2*aNbS;
+ // Contribution of Samtech www.samcef.com END
//
// Allocate the whole Table
myListOfShapeAndInterferences = (BooleanOperations_PShapeAndInterferences)
Standard::Allocate(myLength*sizeof(BooleanOperations_ShapeAndInterferences));
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
//
// Fill the table
- for (i=0; i<2; ++i) {
- aShift=0;
- if (i) {
- aShift=myNumberOfShapesOfTheObject;
- }
- aLit.Initialize(aLx);
- for (; aLit.More(); aLit.Next()) {
- const BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aM=aLit.Value();
- aNbSx=aM.Extent();
- for (j=1; j<=aNbSx; ++j) {
- const TopoDS_Shape& aSx=aM.FindKey(j);
- const BooleanOperations_AncestorsSeqAndSuccessorsSeq& aASx=aM.FindFromIndex(j);
- InsertShapeAndAncestorsSuccessors(aSx, aASx, aShift);
- }
- aShift+=aNbSx;
- }
+ //modified by NIZNHY-PKV Tue May 16 11:47:28 2006f
+
+ //aShift=0;
+ //for (i=0; i<2; ++i) {
+ // if (i) {
+ // aShift=aNbS;
+ // }
+ // for (j=1; j<=aNbS; ++j) {
+ // const TopoDS_Shape& aSx=aMSA.FindKey(j);
+ // const BooleanOperations_AncestorsSeqAndSuccessorsSeq& aASx=
+ // aMSA.FindFromIndex(j);
+ // InsertShapeAndAncestorsSuccessors(aSx, aASx, aShift);
+ // }
+ //}
+
+ aShift=0;
+ for (j=1; j<=aNbS; ++j) {
+ const TopoDS_Shape& aSx=aMSA.FindKey(j);
+ const BooleanOperations_AncestorsSeqAndSuccessorsSeq& aASx=aMSA.FindFromIndex(j);
+ InsertShapeAndAncestorsSuccessors(aSx, aASx, aShift);
}
+ // Contribution of Samtech www.samcef.com END
//
// myShapeIndexMap
myShapeIndexMap.Clear();
iFirst=aR.First();
iLast =aR.Last();
for (j=iFirst; j<=iLast; ++j) {
- const TopoDS_Shape& aS=GetShape(j);
+ const TopoDS_Shape& aS=Shape(j);
aSIM.Add(aS, j);
}
myShapeIndexMap.Add(i, aSIM);
if (!bFound) {
return aIndex;
}
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
//
- const BooleanOperations_IndexedDataMapOfShapeInteger& aSIM=myShapeIndexMap.FindFromKey(aRank);
+ //const BooleanOperations_IndexedDataMapOfShapeInteger& aSIM=
+ // myShapeIndexMap.FindFromKey(aRank);
//
- bFound=aSIM.Contains(aS);
- if (!bFound) {
- return aIndex;
- }
+ //bFound=aSIM.Contains(aS);
+ //if (!bFound) {
+ // return aIndex;
+ //}
//
- aIndex=aSIM.FindFromKey(aS);
+ //aIndex=aSIM.FindFromKey(aS);
+ //
+ Standard_Integer i, aNbRanks;
+ //
+ aNbRanks=myShapeIndexMap.Extent();
+ for (i=1; i<=aNbRanks; ++i){
+ const BooleanOperations_IndexedDataMapOfShapeInteger& aSIM=myShapeIndexMap.FindFromKey(i);
+ bFound=aSIM.Contains(aS);
+ if (bFound) {
+ aIndex=aSIM.FindFromKey(aS);
+ return aIndex;
+ }
+ }
+ // Contribution of Samtech www.samcef.com END
return aIndex;
}
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#endif
class TopoDS_Shape;
class NMTDS_CArray1OfIndexRange;
+class BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors;
#ifndef _Standard_HeaderFile
#include <Standard_Macro.hxx>
#endif
+
class NMTDS_ShapesDataStructure : public BooleanOperations_ShapesDataStructure {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTDS_ShapesDataStructure();
-Standard_EXPORT virtual ~NMTDS_ShapesDataStructure();
+
+
Standard_EXPORT void SetCompositeShape(const TopoDS_Shape& aS) ;
+
+
Standard_EXPORT void Init() ;
+
+
Standard_EXPORT const NMTDS_CArray1OfIndexRange& Ranges() const;
+
+
Standard_EXPORT const TopoDS_Shape& CompositeShape() const;
+
+
Standard_EXPORT Standard_Integer ShapeRangeIndex(const Standard_Integer aId) const;
+
+
Standard_EXPORT virtual Standard_Integer Rank(const Standard_Integer anIndex) const;
+
+
Standard_EXPORT virtual Standard_Integer ShapeIndex(const TopoDS_Shape& aS,const Standard_Integer iRank) const;
+Standard_EXPORT void FillMap(const TopoDS_Shape& aS,BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aMSA,BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aMS) const;
+
+
+Standard_EXPORT void FillSubshapes(const TopoDS_Shape& aS,BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aMSA,BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors& aMS) const;
+
+
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopoDS_Shape_HeaderFile
#include <TopoDS_Shape.hxx>
#endif
#ifndef _NMTDS_CArray1OfIndexRange_HeaderFile
#include <NMTDS_CArray1OfIndexRange.hxx>
#endif
+#ifndef _BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors_HeaderFile
+#include <BooleanOperations_IndexedDataMapOfShapeAncestorsSuccessors.hxx>
+#endif
#ifndef _NMTDS_ShapesDataStructure_HeaderFile
#include <NMTDS_ShapesDataStructure.hxx>
#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_StdMapNodeOfMapOfPassKey_HeaderFile
+#define _NMTDS_StdMapNodeOfMapOfPassKey_HeaderFile
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Handle_NMTDS_StdMapNodeOfMapOfPassKey_HeaderFile
+#include <Handle_NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+#endif
+
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+#ifndef _TCollection_MapNode_HeaderFile
+#include <TCollection_MapNode.hxx>
+#endif
+#ifndef _TCollection_MapNodePtr_HeaderFile
+#include <TCollection_MapNodePtr.hxx>
+#endif
+class NMTDS_PassKey;
+class NMTDS_PassKeyMapHasher;
+class NMTDS_MapOfPassKey;
+class NMTDS_MapIteratorOfMapOfPassKey;
+
+
+
+class NMTDS_StdMapNodeOfMapOfPassKey : public TCollection_MapNode {
+
+public:
+ // Methods PUBLIC
+ //
+
+NMTDS_StdMapNodeOfMapOfPassKey(const NMTDS_PassKey& K,const TCollection_MapNodePtr& n);
+
+ NMTDS_PassKey& Key() const;
+//Standard_EXPORT ~NMTDS_StdMapNodeOfMapOfPassKey();
+
+
+
+
+ // Type management
+ //
+ Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+NMTDS_PassKey myKey;
+
+
+};
+
+#define TheKey NMTDS_PassKey
+#define TheKey_hxx <NMTDS_PassKey.hxx>
+#define Hasher NMTDS_PassKeyMapHasher
+#define Hasher_hxx <NMTDS_PassKeyMapHasher.hxx>
+#define TCollection_StdMapNode NMTDS_StdMapNodeOfMapOfPassKey
+#define TCollection_StdMapNode_hxx <NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+#define TCollection_MapIterator NMTDS_MapIteratorOfMapOfPassKey
+#define TCollection_MapIterator_hxx <NMTDS_MapIteratorOfMapOfPassKey.hxx>
+#define Handle_TCollection_StdMapNode Handle_NMTDS_StdMapNodeOfMapOfPassKey
+#define TCollection_StdMapNode_Type_() NMTDS_StdMapNodeOfMapOfPassKey_Type_()
+#define TCollection_Map NMTDS_MapOfPassKey
+#define TCollection_Map_hxx <NMTDS_MapOfPassKey.hxx>
+
+#include <TCollection_StdMapNode.lxx>
+
+#undef TheKey
+#undef TheKey_hxx
+#undef Hasher
+#undef Hasher_hxx
+#undef TCollection_StdMapNode
+#undef TCollection_StdMapNode_hxx
+#undef TCollection_MapIterator
+#undef TCollection_MapIterator_hxx
+#undef Handle_TCollection_StdMapNode
+#undef TCollection_StdMapNode_Type_
+#undef TCollection_Map
+#undef TCollection_Map_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_StdMapNodeOfMapOfPassKeyBoolean_HeaderFile
+#define _NMTDS_StdMapNodeOfMapOfPassKeyBoolean_HeaderFile
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean_HeaderFile
+#include <Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+#endif
+
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#include <NMTDS_PassKeyBoolean.hxx>
+#endif
+#ifndef _TCollection_MapNode_HeaderFile
+#include <TCollection_MapNode.hxx>
+#endif
+#ifndef _TCollection_MapNodePtr_HeaderFile
+#include <TCollection_MapNodePtr.hxx>
+#endif
+class NMTDS_PassKeyBoolean;
+class NMTDS_PassKeyMapHasher;
+class NMTDS_MapOfPassKeyBoolean;
+class NMTDS_MapIteratorOfMapOfPassKeyBoolean;
+
+
+
+class NMTDS_StdMapNodeOfMapOfPassKeyBoolean : public TCollection_MapNode {
+
+public:
+ // Methods PUBLIC
+ //
+
+NMTDS_StdMapNodeOfMapOfPassKeyBoolean(const NMTDS_PassKeyBoolean& K,const TCollection_MapNodePtr& n);
+
+ NMTDS_PassKeyBoolean& Key() const;
+//Standard_EXPORT ~NMTDS_StdMapNodeOfMapOfPassKeyBoolean();
+
+
+
+
+ // Type management
+ //
+ Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+NMTDS_PassKeyBoolean myKey;
+
+
+};
+
+#define TheKey NMTDS_PassKeyBoolean
+#define TheKey_hxx <NMTDS_PassKeyBoolean.hxx>
+#define Hasher NMTDS_PassKeyMapHasher
+#define Hasher_hxx <NMTDS_PassKeyMapHasher.hxx>
+#define TCollection_StdMapNode NMTDS_StdMapNodeOfMapOfPassKeyBoolean
+#define TCollection_StdMapNode_hxx <NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+#define TCollection_MapIterator NMTDS_MapIteratorOfMapOfPassKeyBoolean
+#define TCollection_MapIterator_hxx <NMTDS_MapIteratorOfMapOfPassKeyBoolean.hxx>
+#define Handle_TCollection_StdMapNode Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean
+#define TCollection_StdMapNode_Type_() NMTDS_StdMapNodeOfMapOfPassKeyBoolean_Type_()
+#define TCollection_Map NMTDS_MapOfPassKeyBoolean
+#define TCollection_Map_hxx <NMTDS_MapOfPassKeyBoolean.hxx>
+
+#include <TCollection_StdMapNode.lxx>
+
+#undef TheKey
+#undef TheKey_hxx
+#undef Hasher
+#undef Hasher_hxx
+#undef TCollection_StdMapNode
+#undef TCollection_StdMapNode_hxx
+#undef TCollection_MapIterator
+#undef TCollection_MapIterator_hxx
+#undef Handle_TCollection_StdMapNode
+#undef TCollection_StdMapNode_Type_
+#undef TCollection_Map
+#undef TCollection_Map_hxx
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+
+#ifndef _Standard_TypeMismatch_HeaderFile
+#include <Standard_TypeMismatch.hxx>
+#endif
+
+#ifndef _NMTDS_PassKeyBoolean_HeaderFile
+#include <NMTDS_PassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_PassKeyMapHasher_HeaderFile
+#include <NMTDS_PassKeyMapHasher.hxx>
+#endif
+#ifndef _NMTDS_MapOfPassKeyBoolean_HeaderFile
+#include <NMTDS_MapOfPassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_MapIteratorOfMapOfPassKeyBoolean_HeaderFile
+#include <NMTDS_MapIteratorOfMapOfPassKeyBoolean.hxx>
+#endif
+//NMTDS_StdMapNodeOfMapOfPassKeyBoolean::~NMTDS_StdMapNodeOfMapOfPassKeyBoolean() {}
+
+
+
+Standard_EXPORT Handle_Standard_Type& NMTDS_StdMapNodeOfMapOfPassKeyBoolean_Type_()
+{
+
+ static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
+ static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
+ static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
+
+
+ static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
+ static Handle_Standard_Type _aType = new Standard_Type("NMTDS_StdMapNodeOfMapOfPassKeyBoolean",
+ sizeof(NMTDS_StdMapNodeOfMapOfPassKeyBoolean),
+ 1,
+ (Standard_Address)_Ancestors,
+ (Standard_Address)NULL);
+
+ return _aType;
+}
+
+
+// DownCast method
+// allow safe downcasting
+//
+const Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean) Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)::DownCast(const Handle(Standard_Transient)& AnObject)
+{
+ Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean) _anOtherObject;
+
+ if (!AnObject.IsNull()) {
+ if (AnObject->IsKind(STANDARD_TYPE(NMTDS_StdMapNodeOfMapOfPassKeyBoolean))) {
+ _anOtherObject = Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)((Handle(NMTDS_StdMapNodeOfMapOfPassKeyBoolean)&)AnObject);
+ }
+ }
+
+ return _anOtherObject ;
+}
+const Handle(Standard_Type)& NMTDS_StdMapNodeOfMapOfPassKeyBoolean::DynamicType() const
+{
+ return STANDARD_TYPE(NMTDS_StdMapNodeOfMapOfPassKeyBoolean) ;
+}
+//Standard_Boolean NMTDS_StdMapNodeOfMapOfPassKeyBoolean::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTDS_StdMapNodeOfMapOfPassKeyBoolean) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean::~Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean() {}
+#define TheKey NMTDS_PassKeyBoolean
+#define TheKey_hxx <NMTDS_PassKeyBoolean.hxx>
+#define Hasher NMTDS_PassKeyMapHasher
+#define Hasher_hxx <NMTDS_PassKeyMapHasher.hxx>
+#define TCollection_StdMapNode NMTDS_StdMapNodeOfMapOfPassKeyBoolean
+#define TCollection_StdMapNode_hxx <NMTDS_StdMapNodeOfMapOfPassKeyBoolean.hxx>
+#define TCollection_MapIterator NMTDS_MapIteratorOfMapOfPassKeyBoolean
+#define TCollection_MapIterator_hxx <NMTDS_MapIteratorOfMapOfPassKeyBoolean.hxx>
+#define Handle_TCollection_StdMapNode Handle_NMTDS_StdMapNodeOfMapOfPassKeyBoolean
+#define TCollection_StdMapNode_Type_() NMTDS_StdMapNodeOfMapOfPassKeyBoolean_Type_()
+#define TCollection_Map NMTDS_MapOfPassKeyBoolean
+#define TCollection_Map_hxx <NMTDS_MapOfPassKeyBoolean.hxx>
+#include <TCollection_StdMapNode.gxx>
+
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#include <NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+
+#ifndef _Standard_TypeMismatch_HeaderFile
+#include <Standard_TypeMismatch.hxx>
+#endif
+
+#ifndef _NMTDS_PassKey_HeaderFile
+#include <NMTDS_PassKey.hxx>
+#endif
+#ifndef _NMTDS_PassKeyMapHasher_HeaderFile
+#include <NMTDS_PassKeyMapHasher.hxx>
+#endif
+#ifndef _NMTDS_MapOfPassKey_HeaderFile
+#include <NMTDS_MapOfPassKey.hxx>
+#endif
+#ifndef _NMTDS_MapIteratorOfMapOfPassKey_HeaderFile
+#include <NMTDS_MapIteratorOfMapOfPassKey.hxx>
+#endif
+//NMTDS_StdMapNodeOfMapOfPassKey::~NMTDS_StdMapNodeOfMapOfPassKey() {}
+
+
+
+Standard_EXPORT Handle_Standard_Type& NMTDS_StdMapNodeOfMapOfPassKey_Type_()
+{
+
+ static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
+ static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
+ static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
+
+
+ static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
+ static Handle_Standard_Type _aType = new Standard_Type("NMTDS_StdMapNodeOfMapOfPassKey",
+ sizeof(NMTDS_StdMapNodeOfMapOfPassKey),
+ 1,
+ (Standard_Address)_Ancestors,
+ (Standard_Address)NULL);
+
+ return _aType;
+}
+
+
+// DownCast method
+// allow safe downcasting
+//
+const Handle(NMTDS_StdMapNodeOfMapOfPassKey) Handle(NMTDS_StdMapNodeOfMapOfPassKey)::DownCast(const Handle(Standard_Transient)& AnObject)
+{
+ Handle(NMTDS_StdMapNodeOfMapOfPassKey) _anOtherObject;
+
+ if (!AnObject.IsNull()) {
+ if (AnObject->IsKind(STANDARD_TYPE(NMTDS_StdMapNodeOfMapOfPassKey))) {
+ _anOtherObject = Handle(NMTDS_StdMapNodeOfMapOfPassKey)((Handle(NMTDS_StdMapNodeOfMapOfPassKey)&)AnObject);
+ }
+ }
+
+ return _anOtherObject ;
+}
+const Handle(Standard_Type)& NMTDS_StdMapNodeOfMapOfPassKey::DynamicType() const
+{
+ return STANDARD_TYPE(NMTDS_StdMapNodeOfMapOfPassKey) ;
+}
+//Standard_Boolean NMTDS_StdMapNodeOfMapOfPassKey::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTDS_StdMapNodeOfMapOfPassKey) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTDS_StdMapNodeOfMapOfPassKey::~Handle_NMTDS_StdMapNodeOfMapOfPassKey() {}
+#define TheKey NMTDS_PassKey
+#define TheKey_hxx <NMTDS_PassKey.hxx>
+#define Hasher NMTDS_PassKeyMapHasher
+#define Hasher_hxx <NMTDS_PassKeyMapHasher.hxx>
+#define TCollection_StdMapNode NMTDS_StdMapNodeOfMapOfPassKey
+#define TCollection_StdMapNode_hxx <NMTDS_StdMapNodeOfMapOfPassKey.hxx>
+#define TCollection_MapIterator NMTDS_MapIteratorOfMapOfPassKey
+#define TCollection_MapIterator_hxx <NMTDS_MapIteratorOfMapOfPassKey.hxx>
+#define Handle_TCollection_StdMapNode Handle_NMTDS_StdMapNodeOfMapOfPassKey
+#define TCollection_StdMapNode_Type_() NMTDS_StdMapNodeOfMapOfPassKey_Type_()
+#define TCollection_Map NMTDS_MapOfPassKey
+#define TCollection_Map_hxx <NMTDS_MapOfPassKey.hxx>
+#include <TCollection_StdMapNode.gxx>
+
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)():Handle(TCollection_MapNode)() {}
Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)(const Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger* operator->()
- {
- return (NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger *)ControlAccess();
- }
-
- NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger* operator->() const
+ NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger* operator->() const
{
return (NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger *)ControlAccess();
}
- Standard_EXPORT ~Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)();
+// Standard_EXPORT ~Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger)();
Standard_EXPORT static const Handle(NMTDS_IndexedDataMapNodeOfIndexedDataMapOfIntegerIndexedDataMapOfShapeInteger) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)():Handle(TCollection_MapNode)() {}
Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)(const Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors* operator->()
- {
- return (NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors *)ControlAccess();
- }
-
- NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors* operator->() const
+ NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors* operator->() const
{
return (NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors *)ControlAccess();
}
- Standard_EXPORT ~Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)();
+// Standard_EXPORT ~Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors)();
Standard_EXPORT static const Handle(NMTDS_ListNodeOfListOfIndexedDataMapOfShapeAncestorsSuccessors) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger)():Handle(TCollection_MapNode)() {}
Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger)(const Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger* operator->()
- {
- return (NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger *)ControlAccess();
- }
-
- NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger* operator->() const
+ NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger* operator->() const
{
return (NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger *)ControlAccess();
}
- Standard_EXPORT ~Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger)();
+// Standard_EXPORT ~Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger)();
Standard_EXPORT static const Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape)():Handle(TCollection_MapNode)() {}
Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape)(const Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape* operator->()
- {
- return (NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape *)ControlAccess();
- }
-
- NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape* operator->() const
+ NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape* operator->() const
{
return (NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape *)ControlAccess();
}
- Standard_EXPORT ~Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape)();
+// Standard_EXPORT ~Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape)();
Standard_EXPORT static const Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock)():Handle(TCollection_MapNode)() {}
Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock)(const Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock* operator->()
- {
- return (NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock *)ControlAccess();
- }
-
- NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock* operator->() const
+ NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock* operator->() const
{
return (NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock *)ControlAccess();
}
- Standard_EXPORT ~Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock)();
+// Standard_EXPORT ~Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock)();
Standard_EXPORT static const Handle(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(NMTTools_ListNodeOfListOfCommonBlock) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(NMTTools_ListNodeOfListOfCommonBlock)():Handle(TCollection_MapNode)() {}
Handle(NMTTools_ListNodeOfListOfCommonBlock)(const Handle(NMTTools_ListNodeOfListOfCommonBlock)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- NMTTools_ListNodeOfListOfCommonBlock* operator->()
- {
- return (NMTTools_ListNodeOfListOfCommonBlock *)ControlAccess();
- }
-
- NMTTools_ListNodeOfListOfCommonBlock* operator->() const
+ NMTTools_ListNodeOfListOfCommonBlock* operator->() const
{
return (NMTTools_ListNodeOfListOfCommonBlock *)ControlAccess();
}
- Standard_EXPORT ~Handle(NMTTools_ListNodeOfListOfCommonBlock)();
+// Standard_EXPORT ~Handle(NMTTools_ListNodeOfListOfCommonBlock)();
Standard_EXPORT static const Handle(NMTTools_ListNodeOfListOfCommonBlock) DownCast(const Handle(Standard_Transient)& AnObject);
};
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class Handle(NMTTools_ListNodeOfListOfCoupleOfShape) : public Handle(TCollection_MapNode) {
public:
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
Handle(NMTTools_ListNodeOfListOfCoupleOfShape)():Handle(TCollection_MapNode)() {}
Handle(NMTTools_ListNodeOfListOfCoupleOfShape)(const Handle(NMTTools_ListNodeOfListOfCoupleOfShape)& aHandle) : Handle(TCollection_MapNode)(aHandle)
{
return *this;
}
- NMTTools_ListNodeOfListOfCoupleOfShape* operator->()
- {
- return (NMTTools_ListNodeOfListOfCoupleOfShape *)ControlAccess();
- }
-
- NMTTools_ListNodeOfListOfCoupleOfShape* operator->() const
+ NMTTools_ListNodeOfListOfCoupleOfShape* operator->() const
{
return (NMTTools_ListNodeOfListOfCoupleOfShape *)ControlAccess();
}
- Standard_EXPORT ~Handle(NMTTools_ListNodeOfListOfCoupleOfShape)();
+// Standard_EXPORT ~Handle(NMTTools_ListNodeOfListOfCoupleOfShape)();
Standard_EXPORT static const Handle(NMTTools_ListNodeOfListOfCoupleOfShape) DownCast(const Handle(Standard_Transient)& AnObject);
};
# Libraries targets
LIB = libNMTTools.la
LIB_SRC = \
- NMTTools_CommonBlock.cxx \
NMTTools_CommonBlockAPI.cxx \
+ NMTTools_CommonBlock.cxx \
NMTTools_CommonBlockPool_0.cxx \
NMTTools_CoupleOfShape.cxx \
NMTTools_DEProcessor.cxx \
NMTTools_ListNodeOfListOfCoupleOfShape_0.cxx \
NMTTools_ListOfCommonBlock_0.cxx \
NMTTools_ListOfCoupleOfShape_0.cxx \
- NMTTools_PaveFiller.cxx \
NMTTools_PaveFiller_0.cxx \
NMTTools_PaveFiller_1.cxx \
NMTTools_PaveFiller_2.cxx \
NMTTools_PaveFiller_7.cxx \
NMTTools_PaveFiller_8.cxx \
NMTTools_PaveFiller_9.cxx \
+ NMTTools_PaveFiller.cxx \
NMTTools_PCurveMaker.cxx \
NMTTools_Tools.cxx
# header files
EXPORT_HEADERS = \
- NMTTools_PDSFiller.hxx \
- NMTTools_DSFiller.hxx \
- NMTTools_PPaveFiller.hxx \
- NMTTools_PaveFiller.hxx \
- NMTTools_ListOfCoupleOfShape.hxx \
- NMTTools_Tools.hxx \
+ Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger.hxx \
+ Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape.hxx \
+ Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock.hxx \
+ Handle_NMTTools_ListNodeOfListOfCommonBlock.hxx \
+ Handle_NMTTools_ListNodeOfListOfCoupleOfShape.hxx \
+ NMTTools_CommonBlockAPI.hxx \
+ NMTTools_CommonBlock.hxx \
+ NMTTools_CommonBlockPool.hxx \
NMTTools_CoupleOfShape.hxx \
- NMTTools_ListIteratorOfListOfCoupleOfShape.hxx \
+ NMTTools_DEProcessor.hxx \
+ NMTTools_DSFiller.hxx \
+ NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger.hxx \
+ NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape.hxx \
+ NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock.hxx \
+ NMTTools_IndexedDataMapOfIndexedMapOfInteger.hxx \
NMTTools_IndexedDataMapOfShapeIndexedMapOfShape.hxx \
+ NMTTools_IndexedDataMapOfShapePaveBlock.hxx \
NMTTools_IteratorOfCoupleOfShape.hxx \
- NMTTools_CommonBlockPool.hxx \
- Handle_NMTTools_ListNodeOfListOfCoupleOfShape.hxx \
- Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape.hxx
+ NMTTools_ListIteratorOfListOfCommonBlock.hxx \
+ NMTTools_ListIteratorOfListOfCoupleOfShape.hxx \
+ NMTTools_ListNodeOfListOfCommonBlock.hxx \
+ NMTTools_ListNodeOfListOfCoupleOfShape.hxx \
+ NMTTools_ListOfCommonBlock.hxx \
+ NMTTools_ListOfCoupleOfShape.hxx \
+ NMTTools_PaveFiller.hxx \
+ NMTTools_PCurveMaker.hxx \
+ NMTTools_PDSFiller.hxx \
+ NMTTools_PPaveFiller.hxx \
+ NMTTools_Tools.hxx
# idl files
EXPORT_IDLS=
--- /dev/null
+// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
+#ifndef _NMTDS_Iterator_HeaderFile
+#define _NMTDS_Iterator_HeaderFile
+
+#ifndef _NMTDS_PShapesDataStructure_HeaderFile
+#include <NMTDS_PShapesDataStructure.hxx>
+#endif
+#ifndef _NMTDS_ListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListOfPassKeyBoolean.hxx>
+#endif
+#ifndef _NMTDS_ListIteratorOfListOfPassKeyBoolean_HeaderFile
+#include <NMTDS_ListIteratorOfListOfPassKeyBoolean.hxx>
+#endif
+#ifndef _Standard_Integer_HeaderFile
+#include <Standard_Integer.hxx>
+#endif
+#ifndef _TopAbs_ShapeEnum_HeaderFile
+#include <TopAbs_ShapeEnum.hxx>
+#endif
+#ifndef _Standard_Boolean_HeaderFile
+#include <Standard_Boolean.hxx>
+#endif
+class NMTDS_ShapesDataStructure;
+
+
+#ifndef _Standard_HeaderFile
+#include <Standard.hxx>
+#endif
+#ifndef _Standard_Macro_HeaderFile
+#include <Standard_Macro.hxx>
+#endif
+
+
+class NMTDS_Iterator {
+
+public:
+
+ void* operator new(size_t,void* anAddress)
+ {
+ return anAddress;
+ }
+ void* operator new(size_t size)
+ {
+ return Standard::Allocate(size);
+ }
+ void operator delete(void *anAddress)
+ {
+ if (anAddress) Standard::Free((Standard_Address&)anAddress);
+ }
+ // Methods PUBLIC
+ //
+
+
+Standard_EXPORT NMTDS_Iterator();
+Standard_EXPORT virtual ~NMTDS_Iterator();
+
+
+Standard_EXPORT void SetDS(const NMTDS_PShapesDataStructure& pDS) ;
+
+
+Standard_EXPORT const NMTDS_ShapesDataStructure& DS() const;
+
+
+Standard_EXPORT void Initialize(const TopAbs_ShapeEnum aType1,const TopAbs_ShapeEnum aType2) ;
+
+
+Standard_EXPORT Standard_Boolean More() const;
+
+
+Standard_EXPORT void Next() ;
+
+
+Standard_EXPORT void Current(Standard_Integer& aIndex1,Standard_Integer& aIndex2,Standard_Boolean& aWithSubShape) const;
+
+
+Standard_EXPORT void Prepare() ;
+
+
+Standard_EXPORT Standard_Integer ExpectedLength() const;
+
+
+
+
+
+protected:
+
+ // Methods PROTECTED
+ //
+
+
+ // Fields PROTECTED
+ //
+NMTDS_PShapesDataStructure myPDS;
+NMTDS_ListOfPassKeyBoolean myLists[6];
+NMTDS_ListIteratorOfListOfPassKeyBoolean myIterator;
+NMTDS_ListOfPassKeyBoolean myEmptyList;
+Standard_Integer myLength;
+
+
+private:
+
+ // Methods PRIVATE
+ //
+
+
+ // Fields PRIVATE
+ //
+
+
+};
+
+
+
+
+
+// other Inline functions and methods (like "C++: function call" methods)
+//
+
+
+#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTTools.cdl
-- Created: Thu Dec 4 16:55:49 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
package NMTTools
class PCurveMaker;
class DEProcessor;
class CoupleOfShape;
-
+
pointer PPaveFiller to PaveFiller from NMTTools;
pointer PDSFiller to DSFiller from NMTTools;
class ListOfCoupleOfShape instantiates
List from TCollection(CoupleOfShape from NMTTools);
+
end NMTTools;
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTTools_CommonBlock.cdl
-- Created: Tue Dec 9 12:11:48 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
+
class CommonBlock from NMTTools
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_CommonBlock {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_CommonBlock();
+
+
Standard_EXPORT void AddPaveBlock(const BOPTools_PaveBlock& aPB) ;
+
+
Standard_EXPORT void AddFace(const Standard_Integer aF) ;
+
+
Standard_EXPORT void AddFaces(const TColStd_ListOfInteger& aLF) ;
+
+
Standard_EXPORT const BOPTools_ListOfPaveBlock& PaveBlocks() const;
+
+
Standard_EXPORT const TColStd_ListOfInteger& Faces() const;
+
+
Standard_EXPORT const BOPTools_PaveBlock& PaveBlock1() const;
+
+
Standard_EXPORT BOPTools_PaveBlock& PaveBlock1(const Standard_Integer anIx) ;
+
+
Standard_EXPORT BOPTools_PaveBlock& PaveBlockOnEdge(const Standard_Integer anIndex) ;
+
+
Standard_EXPORT Standard_Boolean IsPaveBlockOnFace(const Standard_Integer anIndex) const;
+
+
Standard_EXPORT Standard_Boolean IsPaveBlockOnEdge(const Standard_Integer anIndex) const;
+
+
Standard_EXPORT Standard_Boolean IsEqual(const NMTTools_CommonBlock& aCB) const;
+
+
Standard_EXPORT Standard_Boolean Contains(const BOPTools_PaveBlock& aPB) const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _BOPTools_PaveBlock_HeaderFile
#include <BOPTools_PaveBlock.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTTools_CommonBlockAPI.cdl
-- Created: Mon Dec 15 11:35:46 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
class CommonBlockAPI from NMTTools
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_CommonBlockAPI {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_CommonBlockAPI(const NMTTools_ListOfCommonBlock& aList);
+
+
+//! Selector <br>
Standard_EXPORT const NMTTools_ListOfCommonBlock& List() const;
+
+
+//! Returns all PaveBlock-s (from the list) that are <br>
+//! common for the given edge with DS-index <anE> <br>
Standard_EXPORT const BOPTools_ListOfPaveBlock& CommonPaveBlocks(const Standard_Integer anE) const;
+
+
+//! Returns TRUE if given PaveBlock <aPB> is <br>
+//! common for the Blocks from the list <br>
Standard_EXPORT Standard_Boolean IsCommonBlock(const BOPTools_PaveBlock& aPB) const;
+
+
Standard_EXPORT NMTTools_CommonBlock& CommonBlock(const BOPTools_PaveBlock& aPB) const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _NMTTools_ListOfCommonBlock_HeaderFile
#include <NMTTools_ListOfCommonBlock.hxx>
#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_CommonBlockPool {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_CommonBlockPool(const Standard_Integer Length = 0,const Standard_Integer BlockLength = 5);
+
+
Standard_EXPORT void Resize(const Standard_Integer theNewLength) ;
+
+
Standard_EXPORT void Destroy() ;
~NMTTools_CommonBlockPool()
{
Destroy();
}
+
+
Standard_EXPORT Standard_Integer Length() const;
+
+
Standard_EXPORT Standard_Integer Extent() const;
+
+
Standard_EXPORT Standard_Integer FactLength() const;
+
+
Standard_EXPORT Standard_Integer Append(const NMTTools_ListOfCommonBlock& Value) ;
+
+
Standard_EXPORT void Remove(const Standard_Integer Index) ;
+
+
Standard_EXPORT const NMTTools_ListOfCommonBlock& Value(const Standard_Integer Index) const;
const NMTTools_ListOfCommonBlock& operator ()(const Standard_Integer Index) const
{
return Value(Index);
}
+
+
Standard_EXPORT NMTTools_ListOfCommonBlock& ChangeValue(const Standard_Integer Index) ;
NMTTools_ListOfCommonBlock& operator ()(const Standard_Integer Index)
{
return ChangeValue(Index);
}
+
+
Standard_EXPORT void SetBlockLength(const Standard_Integer aBL) ;
+
+
Standard_EXPORT Standard_Integer BlockLength() const;
// Methods PRIVATE
//
+
+
Standard_EXPORT NMTTools_CommonBlockPool(const NMTTools_CommonBlockPool& AnArray);
+
+
Standard_EXPORT NMTTools_CommonBlockPool& Assign(const NMTTools_CommonBlockPool& Other) ;
NMTTools_CommonBlockPool& operator =(const NMTTools_CommonBlockPool& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT Standard_Boolean IsInvalidIndex(const Standard_Integer Index) const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTTools_CoupleOfShape.cdl
-- Created: Wed Jan 28 15:03:39 2004
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2004
class CoupleOfShape from NMTTools
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_CoupleOfShape {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_CoupleOfShape();
+
+
Standard_EXPORT void SetShape1(const TopoDS_Shape& aS) ;
+
+
Standard_EXPORT void SetShape2(const TopoDS_Shape& aS) ;
+
+
Standard_EXPORT const TopoDS_Shape& Shape1() const;
+
+
Standard_EXPORT const TopoDS_Shape& Shape2() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopoDS_Shape_HeaderFile
#include <TopoDS_Shape.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTTools_DEProcessor.cdl
-- Created: Wed Sep 12 12:08:37 2001
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2001
class DEProcessor from NMTTools
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
-// File: BOPTools_DEProcessor.cxx
+// File: NMTTools_DEProcessor.cxx
// Created: Wed Sep 12 12:10:52 2001
// Author: Peter KURNEV
// <pkv@irinox>
#include <NMTDS_ShapesDataStructure.hxx>
-//#include <NMTTools_DSFiller.hxx>
#include <NMTTools_PaveFiller.hxx>
//
#include <BOPTools_SequenceOfCurves.hxx>
#include <BOPTools_Curve.hxx>
+//
+#include <Geom2d_TrimmedCurve.hxx>
+
+#include <ElCLib.hxx>
+#include <gp_Lin2d.hxx>
aNb=myDS->NumberOfShapesOfTheObject();
//
for (i=1; i<=aNb; i++) {
- const TopoDS_Shape& aF=myDS->Shape(i);
+ const TopoDS_Shape aF=myDS->Shape(i);//mpv
if (aF.ShapeType()==TopAbs_FACE) {
TopExp::MapShapesAndAncestors (aF, TopAbs_EDGE, TopAbs_FACE, aMEF);
}
}
//
for (i=1; i<=aNb; i++) {
- const TopoDS_Shape& aS=myDS->Shape(i);
+ const TopoDS_Shape aS=myDS->Shape(i);//mpv
if (aS.ShapeType()==TopAbs_EDGE) {
const TopoDS_Edge& aE=TopoDS::Edge(aS);
// Clear aPaveSet, aSplitEdges
aPaveSet.ChangeSet().Clear();
//
- const TopoDS_Edge& aDE=TopoDS::Edge(myDS->Shape(nED));
- const TopoDS_Face& aDF=TopoDS::Face(myDS->Shape(nFD));
+ const TopoDS_Edge aDE=TopoDS::Edge(myDS->Shape(nED));//mpv
+ const TopoDS_Face aDF=TopoDS::Face(myDS->Shape(nFD));//mpv
//
// 2D Curve of degenerated edge on the face aDF
- Handle(Geom2d_Curve) aC2DDE=BRep_Tool::CurveOnSurface(aDE, aDF, aTD1, aTD2);
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ //Handle(Geom2d_Curve) aC2DDE=BRep_Tool::CurveOnSurface(aDE, aDF, aTD1, aTD2);
+ Handle(Geom2d_Curve) aC2DDE1=BRep_Tool::CurveOnSurface(aDE, aDF, aTD1, aTD2);
+ Handle(Geom2d_TrimmedCurve)aC2DDE=new Geom2d_TrimmedCurve(aC2DDE1, aTD1, aTD2);
+ // Contribution of Samtech www.samcef.com END
//
// Choose direction for Degenerated Edge
gp_Pnt2d aP2d1, aP2d2;
for (; anIt.More(); anIt.Next()) {
const BOPTools_PaveBlock& aPB=anIt.Value();
nE=aPB.Edge();
- const TopoDS_Edge& aE=TopoDS::Edge(myDS->Shape(nE));
+ const TopoDS_Edge aE=TopoDS::Edge(myDS->Shape(nE));//mpv
Handle(Geom2d_Curve) aC2D=BRep_Tool::CurveOnSurface(aE, aDF, aT1, aT2);
//
for (j=1; j<=aNbPoints; ++j) {
gp_Pnt2d aP2D=aGInter.Point(j).Value();
//
- aX=(bXDir) ? aP2D.X(): aP2D.Y();
+ // Modified to obtain exact parameter Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ Handle(Geom2d_Line) aCLDE=Handle(Geom2d_Line)::DownCast(aC2DDE1);
+ if (aCLDE.IsNull()) {
+ continue;
+ }
+ gp_Lin2d aLDE=aCLDE->Lin2d();
+ aX=ElCLib::Parameter(aLDE, aP2D);
+ //
+ //aX=(bXDir) ? aP2D.X(): aP2D.Y();
+ // Contribution of Samtech www.samcef.com END
//
if (fabs (aX-aTD1) < aDT || fabs (aX-aTD2) < aDT) {
continue;
TopoDS_Edge aE, aESplit;
TopoDS_Vertex aV1, aV2;
- const TopoDS_Edge& aDE=TopoDS::Edge(myDS->Shape(nED));
- const TopoDS_Face& aDF=TopoDS::Face(myDS->Shape(nFD));
+ const TopoDS_Edge aDE=TopoDS::Edge(myDS->Shape(nED));//mpv
+ const TopoDS_Face aDF=TopoDS::Face(myDS->Shape(nFD));//mpv
BOPTools_ListIteratorOfListOfPaveBlock aPBIt(aSplitEdges);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
+//! <br>
+//! The Algorithm to compute and store in interferences' pool <br>
+//! and in the Data Structure the following values <br>
+//! for degenerated edges <br>
+//! 1. Paves/Pave set(s) <br>
+//! 2. Split parts <br>
+//! 3. States (3D) for split parts <br>
+//! <br>
class NMTTools_DEProcessor {
public:
}
// Methods PUBLIC
//
+
+
+//! Constructor <br>
+//! <br>
+//! Constructor <br>
+//! <br>
Standard_EXPORT NMTTools_DEProcessor(NMTTools_PaveFiller& aFiller);
+
+
+//! Launches the processor <br>
Standard_EXPORT void Do() ;
+
+
+//! Returns TRUE if it is Ok <br>
Standard_EXPORT Standard_Boolean IsDone() const;
// Methods PROTECTED
//
+
+
Standard_EXPORT void FindDegeneratedEdges() ;
+
+
Standard_EXPORT void DoPaves() ;
+
+
Standard_EXPORT void FindPaveBlocks(const Standard_Integer nED,const Standard_Integer nVD,const Standard_Integer nFD,BOPTools_ListOfPaveBlock& aLPB) ;
+
+
Standard_EXPORT void FillPaveSet(const Standard_Integer nED,const Standard_Integer nVD,const Standard_Integer nFD,const BOPTools_ListOfPaveBlock& aLPB) ;
+
+
Standard_EXPORT void FillSplitEdgesPool(const Standard_Integer nED) ;
+
+
Standard_EXPORT void MakeSplitEdges(const Standard_Integer nED,const Standard_Integer nFD) ;
+
+
Standard_EXPORT void MakeSplitEdge(const TopoDS_Edge& aS1,const TopoDS_Face& aF,const TopoDS_Vertex& aV1,const Standard_Real aP1,const TopoDS_Vertex& aV2,const Standard_Real aP2,TopoDS_Edge& aNewEdge) ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _NMTTools_PaveFiller_HeaderFile
#include <NMTTools_PaveFiller.hxx>
#endif
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTTools_DSFiller.cdl
-- Created: Fri Dec 5 13:57:03 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
class DSFiller from NMTTools
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_DSFiller {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_DSFiller();
+
+//! Destructor <br>
+//! <br>
+//! Selectors/Modifiers <br>
Standard_EXPORT void Destroy() ;
~NMTTools_DSFiller()
{
Destroy();
}
+
+
Standard_EXPORT void SetCompositeShape(const TopoDS_Shape& aS) ;
+
+
Standard_EXPORT const TopoDS_Shape& CompositeShape() const;
+
+
Standard_EXPORT void SetNewFiller(const Standard_Boolean aFlag) const;
+
+
Standard_EXPORT Standard_Boolean IsNewFiller() const;
+
+
Standard_EXPORT void Perform() ;
+
+
Standard_EXPORT const NMTDS_ShapesDataStructure& DS() const;
+
+
Standard_EXPORT const BOPTools_InterferencePool& InterfPool() const;
+
+
Standard_EXPORT Standard_Boolean IsDone() const;
+
+
Standard_EXPORT const NMTTools_PaveFiller& PaveFiller() const;
+
+
Standard_EXPORT NMTTools_PaveFiller& ChangePaveFiller() ;
// Methods PROTECTED
//
+
+
Standard_EXPORT void Clear() ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopoDS_Shape_HeaderFile
#include <TopoDS_Shape.hxx>
#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class NMTTools_IndexedDataMapOfIndexedMapOfInteger;
+
class NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger(const Standard_Integer& K1,const Standard_Integer K2,const TColStd_IndexedMapOfInteger& I,const TCollection_MapNodePtr& n1,const TCollection_MapNodePtr& n2);
+
Standard_Integer& Key1() const;
+
Standard_Integer& Key2() const;
+
TCollection_MapNodePtr& Next2() const;
+
TColStd_IndexedMapOfInteger& Value() const;
-Standard_EXPORT ~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger();
+//Standard_EXPORT ~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _NMTTools_IndexedDataMapOfIndexedMapOfInteger_HeaderFile
#include <NMTTools_IndexedDataMapOfIndexedMapOfInteger.hxx>
#endif
-NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger::~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger() {}
+//NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger::~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger) ;
}
-Standard_Boolean NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger::~Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger() {}
+//Standard_Boolean NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger::~Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfIndexedMapOfInteger() {}
#define TheKey Standard_Integer
#define TheKey_hxx <Standard_Integer.hxx>
#define TheItem TColStd_IndexedMapOfInteger
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class NMTTools_IndexedDataMapOfShapeIndexedMapOfShape;
+
class NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape(const TopoDS_Shape& K1,const Standard_Integer K2,const TopTools_IndexedMapOfShape& I,const TCollection_MapNodePtr& n1,const TCollection_MapNodePtr& n2);
+
TopoDS_Shape& Key1() const;
+
Standard_Integer& Key2() const;
+
TCollection_MapNodePtr& Next2() const;
+
TopTools_IndexedMapOfShape& Value() const;
-Standard_EXPORT ~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape();
+//Standard_EXPORT ~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _NMTTools_IndexedDataMapOfShapeIndexedMapOfShape_HeaderFile
#include <NMTTools_IndexedDataMapOfShapeIndexedMapOfShape.hxx>
#endif
-NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape::~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape() {}
+//NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape::~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape) ;
}
-Standard_Boolean NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape::~Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape() {}
+//Standard_Boolean NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape::~Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapeIndexedMapOfShape() {}
#define TheKey TopoDS_Shape
#define TheKey_hxx <TopoDS_Shape.hxx>
#define TheItem TopTools_IndexedMapOfShape
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class NMTTools_IndexedDataMapOfShapePaveBlock;
+
class NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock(const TopoDS_Shape& K1,const Standard_Integer K2,const BOPTools_PaveBlock& I,const TCollection_MapNodePtr& n1,const TCollection_MapNodePtr& n2);
+
TopoDS_Shape& Key1() const;
+
Standard_Integer& Key2() const;
+
TCollection_MapNodePtr& Next2() const;
+
BOPTools_PaveBlock& Value() const;
-Standard_EXPORT ~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock();
+//Standard_EXPORT ~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _NMTTools_IndexedDataMapOfShapePaveBlock_HeaderFile
#include <NMTTools_IndexedDataMapOfShapePaveBlock.hxx>
#endif
-NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock::~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock() {}
+//NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock::~NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock) ;
}
-Standard_Boolean NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock::~Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock() {}
+//Standard_Boolean NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock::~Handle_NMTTools_IndexedDataMapNodeOfIndexedDataMapOfShapePaveBlock() {}
#define TheKey TopoDS_Shape
#define TheKey_hxx <TopoDS_Shape.hxx>
#define TheItem BOPTools_PaveBlock
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_IndexedDataMapOfIndexedMapOfInteger : public TCollection_BasicMap {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_IndexedDataMapOfIndexedMapOfInteger(const Standard_Integer NbBuckets = 1);
+
+
Standard_EXPORT NMTTools_IndexedDataMapOfIndexedMapOfInteger& Assign(const NMTTools_IndexedDataMapOfIndexedMapOfInteger& Other) ;
NMTTools_IndexedDataMapOfIndexedMapOfInteger& operator =(const NMTTools_IndexedDataMapOfIndexedMapOfInteger& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
Standard_EXPORT void Clear() ;
~NMTTools_IndexedDataMapOfIndexedMapOfInteger()
{
Clear();
}
+
+
Standard_EXPORT Standard_Integer Add(const Standard_Integer& K,const TColStd_IndexedMapOfInteger& I) ;
+
+
Standard_EXPORT void Substitute(const Standard_Integer I,const Standard_Integer& K,const TColStd_IndexedMapOfInteger& T) ;
+
+
Standard_EXPORT void RemoveLast() ;
+
+
Standard_EXPORT Standard_Boolean Contains(const Standard_Integer& K) const;
+
+
Standard_EXPORT const Standard_Integer& FindKey(const Standard_Integer I) const;
+
+
Standard_EXPORT const TColStd_IndexedMapOfInteger& FindFromIndex(const Standard_Integer I) const;
const TColStd_IndexedMapOfInteger& operator ()(const Standard_Integer I) const
{
return FindFromIndex(I);
}
+
+
Standard_EXPORT TColStd_IndexedMapOfInteger& ChangeFromIndex(const Standard_Integer I) ;
TColStd_IndexedMapOfInteger& operator ()(const Standard_Integer I)
{
return ChangeFromIndex(I);
}
+
+
Standard_EXPORT Standard_Integer FindIndex(const Standard_Integer& K) const;
+
+
Standard_EXPORT const TColStd_IndexedMapOfInteger& FindFromKey(const Standard_Integer& K) const;
+
+
Standard_EXPORT TColStd_IndexedMapOfInteger& ChangeFromKey(const Standard_Integer& K) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT NMTTools_IndexedDataMapOfIndexedMapOfInteger(const NMTTools_IndexedDataMapOfIndexedMapOfInteger& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_IndexedDataMapOfShapeIndexedMapOfShape : public TCollection_BasicMap {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_IndexedDataMapOfShapeIndexedMapOfShape(const Standard_Integer NbBuckets = 1);
+
+
Standard_EXPORT NMTTools_IndexedDataMapOfShapeIndexedMapOfShape& Assign(const NMTTools_IndexedDataMapOfShapeIndexedMapOfShape& Other) ;
NMTTools_IndexedDataMapOfShapeIndexedMapOfShape& operator =(const NMTTools_IndexedDataMapOfShapeIndexedMapOfShape& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
Standard_EXPORT void Clear() ;
~NMTTools_IndexedDataMapOfShapeIndexedMapOfShape()
{
Clear();
}
+
+
Standard_EXPORT Standard_Integer Add(const TopoDS_Shape& K,const TopTools_IndexedMapOfShape& I) ;
+
+
Standard_EXPORT void Substitute(const Standard_Integer I,const TopoDS_Shape& K,const TopTools_IndexedMapOfShape& T) ;
+
+
Standard_EXPORT void RemoveLast() ;
+
+
Standard_EXPORT Standard_Boolean Contains(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT const TopoDS_Shape& FindKey(const Standard_Integer I) const;
+
+
Standard_EXPORT const TopTools_IndexedMapOfShape& FindFromIndex(const Standard_Integer I) const;
const TopTools_IndexedMapOfShape& operator ()(const Standard_Integer I) const
{
return FindFromIndex(I);
}
+
+
Standard_EXPORT TopTools_IndexedMapOfShape& ChangeFromIndex(const Standard_Integer I) ;
TopTools_IndexedMapOfShape& operator ()(const Standard_Integer I)
{
return ChangeFromIndex(I);
}
+
+
Standard_EXPORT Standard_Integer FindIndex(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT const TopTools_IndexedMapOfShape& FindFromKey(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT TopTools_IndexedMapOfShape& ChangeFromKey(const TopoDS_Shape& K) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT NMTTools_IndexedDataMapOfShapeIndexedMapOfShape(const NMTTools_IndexedDataMapOfShapeIndexedMapOfShape& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_IndexedDataMapOfShapePaveBlock : public TCollection_BasicMap {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_IndexedDataMapOfShapePaveBlock(const Standard_Integer NbBuckets = 1);
+
+
Standard_EXPORT NMTTools_IndexedDataMapOfShapePaveBlock& Assign(const NMTTools_IndexedDataMapOfShapePaveBlock& Other) ;
NMTTools_IndexedDataMapOfShapePaveBlock& operator =(const NMTTools_IndexedDataMapOfShapePaveBlock& Other)
{
return Assign(Other);
}
+
+
Standard_EXPORT void ReSize(const Standard_Integer NbBuckets) ;
+
+
Standard_EXPORT void Clear() ;
~NMTTools_IndexedDataMapOfShapePaveBlock()
{
Clear();
}
+
+
Standard_EXPORT Standard_Integer Add(const TopoDS_Shape& K,const BOPTools_PaveBlock& I) ;
+
+
Standard_EXPORT void Substitute(const Standard_Integer I,const TopoDS_Shape& K,const BOPTools_PaveBlock& T) ;
+
+
Standard_EXPORT void RemoveLast() ;
+
+
Standard_EXPORT Standard_Boolean Contains(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT const TopoDS_Shape& FindKey(const Standard_Integer I) const;
+
+
Standard_EXPORT const BOPTools_PaveBlock& FindFromIndex(const Standard_Integer I) const;
const BOPTools_PaveBlock& operator ()(const Standard_Integer I) const
{
return FindFromIndex(I);
}
+
+
Standard_EXPORT BOPTools_PaveBlock& ChangeFromIndex(const Standard_Integer I) ;
BOPTools_PaveBlock& operator ()(const Standard_Integer I)
{
return ChangeFromIndex(I);
}
+
+
Standard_EXPORT Standard_Integer FindIndex(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT const BOPTools_PaveBlock& FindFromKey(const TopoDS_Shape& K) const;
+
+
Standard_EXPORT BOPTools_PaveBlock& ChangeFromKey(const TopoDS_Shape& K) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT NMTTools_IndexedDataMapOfShapePaveBlock(const NMTTools_IndexedDataMapOfShapePaveBlock& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTTools_IteratorOfCoupleOfShape.cdl
-- Created: Thu Dec 4 16:57:48 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
class IteratorOfCoupleOfShape from NMTTools
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_IteratorOfCoupleOfShape : public BOPTools_IteratorOfCoupleOfShape {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_IteratorOfCoupleOfShape();
+
+
Standard_EXPORT void SetDS(const NMTDS_PShapesDataStructure& pDS) ;
+
+
Standard_EXPORT virtual void Initialize(const TopAbs_ShapeEnum Type1,const TopAbs_ShapeEnum Type2) ;
+
+
Standard_EXPORT virtual void Current(Standard_Integer& Index1,Standard_Integer& Index2,Standard_Boolean& WithSubShape) const;
+
+
Standard_EXPORT virtual Standard_Boolean More() const;
+
+
Standard_EXPORT const NMTDS_ShapesDataStructure& DS() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _Standard_NoSuchObject_HeaderFile
#include <Standard_NoSuchObject.hxx>
#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_ListIteratorOfListOfCommonBlock {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_ListIteratorOfListOfCommonBlock();
+
+
Standard_EXPORT NMTTools_ListIteratorOfListOfCommonBlock(const NMTTools_ListOfCommonBlock& L);
+
+
Standard_EXPORT void Initialize(const NMTTools_ListOfCommonBlock& L) ;
+
Standard_Boolean More() const;
+
+
Standard_EXPORT void Next() ;
+
+
Standard_EXPORT NMTTools_CommonBlock& Value() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_ListIteratorOfListOfCoupleOfShape {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_ListIteratorOfListOfCoupleOfShape();
+
+
Standard_EXPORT NMTTools_ListIteratorOfListOfCoupleOfShape(const NMTTools_ListOfCoupleOfShape& L);
+
+
Standard_EXPORT void Initialize(const NMTTools_ListOfCoupleOfShape& L) ;
+
Standard_Boolean More() const;
+
+
Standard_EXPORT void Next() ;
+
+
Standard_EXPORT NMTTools_CoupleOfShape& Value() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class NMTTools_ListIteratorOfListOfCommonBlock;
+
class NMTTools_ListNodeOfListOfCommonBlock : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
NMTTools_ListNodeOfListOfCommonBlock(const NMTTools_CommonBlock& I,const TCollection_MapNodePtr& n);
+
NMTTools_CommonBlock& Value() const;
-Standard_EXPORT ~NMTTools_ListNodeOfListOfCommonBlock();
+//Standard_EXPORT ~NMTTools_ListNodeOfListOfCommonBlock();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& NMTTools_ListNodeOfListOfCommonBlock_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _NMTTools_ListIteratorOfListOfCommonBlock_HeaderFile
#include <NMTTools_ListIteratorOfListOfCommonBlock.hxx>
#endif
-NMTTools_ListNodeOfListOfCommonBlock::~NMTTools_ListNodeOfListOfCommonBlock() {}
+//NMTTools_ListNodeOfListOfCommonBlock::~NMTTools_ListNodeOfListOfCommonBlock() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(NMTTools_ListNodeOfListOfCommonBlock) ;
}
-Standard_Boolean NMTTools_ListNodeOfListOfCommonBlock::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(NMTTools_ListNodeOfListOfCommonBlock) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_NMTTools_ListNodeOfListOfCommonBlock::~Handle_NMTTools_ListNodeOfListOfCommonBlock() {}
+//Standard_Boolean NMTTools_ListNodeOfListOfCommonBlock::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTTools_ListNodeOfListOfCommonBlock) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTTools_ListNodeOfListOfCommonBlock::~Handle_NMTTools_ListNodeOfListOfCommonBlock() {}
#define Item NMTTools_CommonBlock
#define Item_hxx <NMTTools_CommonBlock.hxx>
#define TCollection_ListNode NMTTools_ListNodeOfListOfCommonBlock
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
class NMTTools_ListIteratorOfListOfCoupleOfShape;
+
class NMTTools_ListNodeOfListOfCoupleOfShape : public TCollection_MapNode {
public:
-
- void* operator new(size_t,void* anAddress)
- {
- return anAddress;
- }
- void* operator new(size_t size)
- {
- return Standard::Allocate(size);
- }
- void operator delete(void *anAddress)
- {
- if (anAddress) Standard::Free((Standard_Address&)anAddress);
- }
// Methods PUBLIC
//
+
NMTTools_ListNodeOfListOfCoupleOfShape(const NMTTools_CoupleOfShape& I,const TCollection_MapNodePtr& n);
+
NMTTools_CoupleOfShape& Value() const;
-Standard_EXPORT ~NMTTools_ListNodeOfListOfCoupleOfShape();
+//Standard_EXPORT ~NMTTools_ListNodeOfListOfCoupleOfShape();
// Type management
//
- Standard_EXPORT friend Handle_Standard_Type& NMTTools_ListNodeOfListOfCoupleOfShape_Type_();
Standard_EXPORT const Handle(Standard_Type)& DynamicType() const;
- Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
+ //Standard_EXPORT Standard_Boolean IsKind(const Handle(Standard_Type)&) const;
protected:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _NMTTools_ListIteratorOfListOfCoupleOfShape_HeaderFile
#include <NMTTools_ListIteratorOfListOfCoupleOfShape.hxx>
#endif
-NMTTools_ListNodeOfListOfCoupleOfShape::~NMTTools_ListNodeOfListOfCoupleOfShape() {}
+//NMTTools_ListNodeOfListOfCoupleOfShape::~NMTTools_ListNodeOfListOfCoupleOfShape() {}
{
static Handle_Standard_Type aType1 = STANDARD_TYPE(TCollection_MapNode);
- if ( aType1.IsNull()) aType1 = STANDARD_TYPE(TCollection_MapNode);
static Handle_Standard_Type aType2 = STANDARD_TYPE(MMgt_TShared);
- if ( aType2.IsNull()) aType2 = STANDARD_TYPE(MMgt_TShared);
static Handle_Standard_Type aType3 = STANDARD_TYPE(Standard_Transient);
- if ( aType3.IsNull()) aType3 = STANDARD_TYPE(Standard_Transient);
static Handle_Standard_Transient _Ancestors[]= {aType1,aType2,aType3,NULL};
{
return STANDARD_TYPE(NMTTools_ListNodeOfListOfCoupleOfShape) ;
}
-Standard_Boolean NMTTools_ListNodeOfListOfCoupleOfShape::IsKind(const Handle(Standard_Type)& AType) const
-{
- return (STANDARD_TYPE(NMTTools_ListNodeOfListOfCoupleOfShape) == AType || TCollection_MapNode::IsKind(AType));
-}
-Handle_NMTTools_ListNodeOfListOfCoupleOfShape::~Handle_NMTTools_ListNodeOfListOfCoupleOfShape() {}
+//Standard_Boolean NMTTools_ListNodeOfListOfCoupleOfShape::IsKind(const Handle(Standard_Type)& AType) const
+//{
+// return (STANDARD_TYPE(NMTTools_ListNodeOfListOfCoupleOfShape) == AType || TCollection_MapNode::IsKind(AType));
+//}
+//Handle_NMTTools_ListNodeOfListOfCoupleOfShape::~Handle_NMTTools_ListNodeOfListOfCoupleOfShape() {}
#define Item NMTTools_CoupleOfShape
#define Item_hxx <NMTTools_CoupleOfShape.hxx>
#define TCollection_ListNode NMTTools_ListNodeOfListOfCoupleOfShape
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_ListOfCommonBlock {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_ListOfCommonBlock();
+
+
Standard_EXPORT void Assign(const NMTTools_ListOfCommonBlock& Other) ;
void operator=(const NMTTools_ListOfCommonBlock& Other)
{
Assign(Other);
}
+
+
Standard_EXPORT Standard_Integer Extent() const;
+
+
Standard_EXPORT void Clear() ;
~NMTTools_ListOfCommonBlock()
{
Clear();
}
+
Standard_Boolean IsEmpty() const;
+
+
Standard_EXPORT void Prepend(const NMTTools_CommonBlock& I) ;
+
+
Standard_EXPORT void Prepend(const NMTTools_CommonBlock& I,NMTTools_ListIteratorOfListOfCommonBlock& theIt) ;
+
+
Standard_EXPORT void Prepend(NMTTools_ListOfCommonBlock& Other) ;
+
+
Standard_EXPORT void Append(const NMTTools_CommonBlock& I) ;
+
+
Standard_EXPORT void Append(const NMTTools_CommonBlock& I,NMTTools_ListIteratorOfListOfCommonBlock& theIt) ;
+
+
Standard_EXPORT void Append(NMTTools_ListOfCommonBlock& Other) ;
+
+
Standard_EXPORT NMTTools_CommonBlock& First() const;
+
+
Standard_EXPORT NMTTools_CommonBlock& Last() const;
+
+
Standard_EXPORT void RemoveFirst() ;
+
+
Standard_EXPORT void Remove(NMTTools_ListIteratorOfListOfCommonBlock& It) ;
+
+
Standard_EXPORT void InsertBefore(const NMTTools_CommonBlock& I,NMTTools_ListIteratorOfListOfCommonBlock& It) ;
+
+
Standard_EXPORT void InsertBefore(NMTTools_ListOfCommonBlock& Other,NMTTools_ListIteratorOfListOfCommonBlock& It) ;
+
+
Standard_EXPORT void InsertAfter(const NMTTools_CommonBlock& I,NMTTools_ListIteratorOfListOfCommonBlock& It) ;
+
+
Standard_EXPORT void InsertAfter(NMTTools_ListOfCommonBlock& Other,NMTTools_ListIteratorOfListOfCommonBlock& It) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT NMTTools_ListOfCommonBlock(const NMTTools_ListOfCommonBlock& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_ListOfCoupleOfShape {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_ListOfCoupleOfShape();
+
+
Standard_EXPORT void Assign(const NMTTools_ListOfCoupleOfShape& Other) ;
void operator=(const NMTTools_ListOfCoupleOfShape& Other)
{
Assign(Other);
}
+
+
Standard_EXPORT Standard_Integer Extent() const;
+
+
Standard_EXPORT void Clear() ;
~NMTTools_ListOfCoupleOfShape()
{
Clear();
}
+
Standard_Boolean IsEmpty() const;
+
+
Standard_EXPORT void Prepend(const NMTTools_CoupleOfShape& I) ;
+
+
Standard_EXPORT void Prepend(const NMTTools_CoupleOfShape& I,NMTTools_ListIteratorOfListOfCoupleOfShape& theIt) ;
+
+
Standard_EXPORT void Prepend(NMTTools_ListOfCoupleOfShape& Other) ;
+
+
Standard_EXPORT void Append(const NMTTools_CoupleOfShape& I) ;
+
+
Standard_EXPORT void Append(const NMTTools_CoupleOfShape& I,NMTTools_ListIteratorOfListOfCoupleOfShape& theIt) ;
+
+
Standard_EXPORT void Append(NMTTools_ListOfCoupleOfShape& Other) ;
+
+
Standard_EXPORT NMTTools_CoupleOfShape& First() const;
+
+
Standard_EXPORT NMTTools_CoupleOfShape& Last() const;
+
+
Standard_EXPORT void RemoveFirst() ;
+
+
Standard_EXPORT void Remove(NMTTools_ListIteratorOfListOfCoupleOfShape& It) ;
+
+
Standard_EXPORT void InsertBefore(const NMTTools_CoupleOfShape& I,NMTTools_ListIteratorOfListOfCoupleOfShape& It) ;
+
+
Standard_EXPORT void InsertBefore(NMTTools_ListOfCoupleOfShape& Other,NMTTools_ListIteratorOfListOfCoupleOfShape& It) ;
+
+
Standard_EXPORT void InsertAfter(const NMTTools_CoupleOfShape& I,NMTTools_ListIteratorOfListOfCoupleOfShape& It) ;
+
+
Standard_EXPORT void InsertAfter(NMTTools_ListOfCoupleOfShape& Other,NMTTools_ListIteratorOfListOfCoupleOfShape& It) ;
// Methods PRIVATE
//
+
+
Standard_EXPORT NMTTools_ListOfCoupleOfShape(const NMTTools_ListOfCoupleOfShape& Other);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTTools_PCurveMaker.cdl
-- Created:
-- Author: Peter KURNEV
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
+//! Class provides computation p-curves for the edges and theirs <br>
+//! split parts <br>
class NMTTools_PCurveMaker {
public:
}
// Methods PUBLIC
//
+
+
+//! Constructor <br>
Standard_EXPORT NMTTools_PCurveMaker(NMTTools_PDSFiller& aFiller);
+
+
+//! Launch the processor <br>
Standard_EXPORT void Do() ;
+
+
+//! Returns TRUE if Ok <br>
Standard_EXPORT Standard_Boolean IsDone() const;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _NMTTools_PCurveMaker_HeaderFile
#include <NMTTools_PCurveMaker.hxx>
#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
-- File: NMTTools_PaveFiller.cdl
-- Created: Fri Dec 5 14:35:00 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
class PaveFiller from NMTTools
---Purpose:
-uses
- ListOfInteger from TColStd,
+uses
+ -- Modified to add new definitions Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ ListOfInteger from TColStd,
+ -- Contribution of Samtech www.samcef.com END
Pnt from gp,
ShapeEnum from TopAbs,
Vertex from TopoDS,
- Face from TopoDS,
+ Face from TopoDS,
+ -- Modified to add new definitions Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ Edge from TopoDS,
+ ListOfShape from TopTools,
+ -- Contribution of Samtech www.samcef.com END
Context from IntTools,
ShrunkRange from IntTools,
-
+
IndexedDataMapOfShapeInteger from BooleanOperations,
InterferencePool from BOPTools,
CommonBlockPool from NMTTools,
CommonBlock from NMTTools,
- ListOfCommonBlock from NMTTools,
- IteratorOfCoupleOfShape from NMTTools,
-
- ShapesDataStructure from NMTDS,
- PShapesDataStructure from NMTDS
-
+ ListOfCommonBlock from NMTTools,
+ -- Modified to add new definitions Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ IndexedDataMapOfIndexedMapOfInteger from NMTTools,
+ -- Contribution of Samtech www.samcef.com END
+ ShapesDataStructure from NMTDS,
+ -- Modified to add new definitions Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ PShapesDataStructure from NMTDS,
+ Iterator from NMTDS
+ -- Contribution of Samtech www.samcef.com END
+
--raises
is
returns PInterferencePool from BOPTools;
--
-- Perform the algo
- Init (me:out)
- is protected;
+ -- Modified to add new method Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ Init (me:out);
+ -- Contribution of Samtech www.samcef.com END
Perform (me:out)
is virtual;
PerformVV (me:out)
- is virtual protected;
+ is virtual ;
PerformVE (me:out)
is virtual protected;
is virtual protected;
PerformNewVertices (me:out)
- is virtual protected;
+ is virtual ;
PrepareEdges (me:out)
is virtual protected;
RealPaveBlock(me:out;
aPB:PaveBlock from BOPTools)
returns PaveBlock from BOPTools;
+ ---C++: return const &
+
+ -- Modified to add new method Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ RealPaveBlock(me:out;
+ aPB:PaveBlock from BOPTools;
+ aLB:out ListOfInteger from TColStd)
+ returns PaveBlock from BOPTools;
---C++: return const &
- --
+ -- Contribution of Samtech www.samcef.com END
+
RealSplitsFace (me:out;
nF2 :Integer from Standard;
aLs :out ListOfPaveBlock from BOPTools);
PrepareSetForFace(me:out;
nF1 :Integer from Standard;
nF2 :Integer from Standard;
- --modified by NIZNHY-PKV Fri Apr 1 11:19:15 2005f
aLPB: ListOfPaveBlock from BOPTools;
- --modified by NIZNHY-PKV Fri Apr 1 10:54:16 2005t
aPSF:out PaveSet from BOPTools);
PutPaveOnCurve(me:out;
aTol: Real from Standard)
returns Integer from Standard;
--- IsExistingPaveBlock (me:out;
--- aPB : PaveBlock from BOPTools;
--- aFF : SSInterference from BOPTools)
--- returns Boolean from Standard;
-
---modified by NIZNHY-PKV Fri Apr 1 09:35:34 2005f
+
IsExistingPaveBlock (me:out;
aPB : PaveBlock from BOPTools;
aLPB: ListOfPaveBlock from BOPTools;
aTol: Real from Standard)
returns Boolean from Standard;
---modified by NIZNHY-PKV Fri Apr 1 09:35:39 2005t
MakePCurves (me:out);
+ -- Modified to add new methods Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ PerformVF1(me:out)
+ is protected;
+
+ MakeAloneVertices(me:out)
+ is protected;
+
+ AloneVertices(me)
+ returns IndexedDataMapOfIndexedMapOfInteger from NMTTools;
+ ---C++: return const &
+ -- Contribution of Samtech www.samcef.com END
+
+ IsExistingPaveBlock (me:out;
+ aPB : PaveBlock from BOPTools;
+ aLPB: ListOfShape from TopTools;
+ aTol: Real from Standard)
+ returns Boolean from Standard;
+
+ --
+ CheckCoincidence (me:out;
+ aPB : PaveBlock from BOPTools;
+ aLPB: ListOfPaveBlock from BOPTools)
+ returns Boolean from Standard;
+ --
+
+ CheckIntermediatePoint(me:out;
+ aPB : PaveBlock from BOPTools;
+ aE : Edge from TopoDS;
+ aTol: Real from Standard)
+ returns Integer from Standard;
+
+ -- Modified to add new method Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ SharedEdges(me:out;
+ nF1 :Integer from Standard;
+ nF2 :Integer from Standard;
+ aLNE :out ListOfInteger from TColStd;
+ aLSE :out ListOfShape from TopTools);
+ -- Contribution of Samtech www.samcef.com END
+
fields
myIntrPool : PInterferencePool from BOPTools is protected;
myDS : PShapesDataStructure from NMTDS is protected;
myIsDone : Boolean from Standard is protected;
myNbSources : Integer from Standard is protected;
- myNbEdges : Integer from Standard is protected;
- myDSIt : IteratorOfCoupleOfShape from NMTTools is protected;
- --
+ myNbEdges : Integer from Standard is protected;
+
+ -- Modified to add new field Thu Sep 14 14:35:18 2006
+ -- Contribution of Samtech www.samcef.com BEGIN
+ myDSIt : Iterator from NMTDS is protected;
+ -- Contribution of Samtech www.samcef.com END
+
myPavePool : PavePool from BOPTools is protected;
myPavePoolNew : PavePool from BOPTools is protected;
myCommonBlockPool : CommonBlockPool from NMTTools is protected;
mySplitShapesPool : SplitShapesPool from BOPTools is protected;
--
myContext : Context from IntTools is protected;
- mySectionAttribute : SSIntersectionAttribute from BOPTools is protected;
+ mySectionAttribute : SSIntersectionAttribute from BOPTools is protected;
+ myAloneVertices : IndexedDataMapOfIndexedMapOfInteger from NMTTools is protected;
end PaveFiller;
#include <BOPTColStd_Failure.hxx>
#include <NMTDS_ShapesDataStructure.hxx>
#include <NMTTools_DEProcessor.hxx>
-//QQ #include "utilities.h"
-
+//
+//
//=======================================================================
// function: NMTTools_PaveFiller::NMTTools_PaveFiller
// purpose:
void NMTTools_PaveFiller::Init()
{
myDSIt.SetDS(myDS);
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ myDSIt.Prepare();
+ // Contribution of Samtech www.samcef.com END
}
+
//=======================================================================
// function: Perform
// purpose:
//=======================================================================
void NMTTools_PaveFiller::Perform()
{
+ myIsDone=Standard_False;
+ //
try {
// 0.
- Init();//myDSIt.SetDS(myDS);
- //
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ Init();
+ // Contribution of Samtech www.samcef.com END
//1.VV
+ //
PerformVV();
PerformNewVertices();
//
// 2.VE
myPavePool.Resize (myNbEdges);
PrepareEdges();
-
PerformVE();
//
// 3.VF
myCommonBlockPool.Resize (myNbEdges);
mySplitShapesPool.Resize (myNbEdges);
myPavePoolNew .Resize (myNbEdges);
-
+
PreparePaveBlocks(TopAbs_VERTEX, TopAbs_EDGE);
PreparePaveBlocks(TopAbs_EDGE, TopAbs_EDGE);
//
// 5.EF
PreparePaveBlocks(TopAbs_EDGE, TopAbs_FACE);
PerformEF();
+ //
RefinePavePool();
//
myPavePoolNew.Destroy();
//
// 6. FF
PerformFF ();
+ //
MakeBlocks();
+ //
MakePCurves();
//
// 7.Postprocessing
NMTTools_DEProcessor aDEP(*this);
aDEP.Do();
//
- myIsDone = Standard_True;
+ // Modified to treat Alone Vertices Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ MakeAloneVertices();
+ // Contribution of Samtech www.samcef.com END
+ //
+ myIsDone=Standard_True;
}
- catch (BOPTColStd_Failure& /*x*/) {
- //QQ MESSAGE(x.Message() << flush);
- myIsDone = Standard_False;
+ catch (BOPTColStd_Failure& ) {
}
}
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#ifndef _Standard_Integer_HeaderFile
#include <Standard_Integer.hxx>
#endif
-#ifndef _NMTTools_IteratorOfCoupleOfShape_HeaderFile
-#include <NMTTools_IteratorOfCoupleOfShape.hxx>
+#ifndef _NMTDS_Iterator_HeaderFile
+#include <NMTDS_Iterator.hxx>
#endif
#ifndef _BOPTools_PavePool_HeaderFile
#include <BOPTools_PavePool.hxx>
#ifndef _BOPTools_SSIntersectionAttribute_HeaderFile
#include <BOPTools_SSIntersectionAttribute.hxx>
#endif
+#ifndef _NMTTools_IndexedDataMapOfIndexedMapOfInteger_HeaderFile
+#include <NMTTools_IndexedDataMapOfIndexedMapOfInteger.hxx>
+#endif
#ifndef _TopAbs_ShapeEnum_HeaderFile
#include <TopAbs_ShapeEnum.hxx>
#endif
class BOPTools_Curve;
class BOPTools_SSInterference;
class gp_Pnt;
+class NMTTools_IndexedDataMapOfIndexedMapOfInteger;
+class TopTools_ListOfShape;
+class TopoDS_Edge;
#ifndef _Standard_HeaderFile
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_PaveFiller {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT NMTTools_PaveFiller();
+
+
Standard_EXPORT NMTTools_PaveFiller(const BOPTools_InterferencePool& aIP);
+
+
Standard_EXPORT virtual void Destroy() ;
Standard_EXPORT virtual ~NMTTools_PaveFiller(){Destroy();}
+
+
Standard_EXPORT void SetInterferencePool(const BOPTools_InterferencePool& aIP) ;
+
+
Standard_EXPORT BOPTools_PInterferencePool InterfPool() ;
+
+
+Standard_EXPORT void Init() ;
+
+
Standard_EXPORT virtual void Perform() ;
+
+
+Standard_EXPORT virtual void PerformVV() ;
+
+
+Standard_EXPORT virtual void PerformNewVertices() ;
+
+
Standard_EXPORT Standard_Boolean IsDone() const;
+
+
Standard_EXPORT NMTDS_PShapesDataStructure DS() ;
+
+
Standard_EXPORT const IntTools_Context& Context() const;
+
+
Standard_EXPORT IntTools_Context& ChangeContext() ;
+
+
Standard_EXPORT const BOPTools_PavePool& PavePool() const;
+
+
Standard_EXPORT BOPTools_PavePool& ChangePavePool() ;
+
+
Standard_EXPORT const NMTTools_CommonBlockPool& CommonBlockPool() const;
+
+
Standard_EXPORT NMTTools_CommonBlockPool& ChangeCommonBlockPool() ;
+
+
Standard_EXPORT const BOPTools_SplitShapesPool& SplitShapesPool() const;
+
+
Standard_EXPORT BOPTools_SplitShapesPool& ChangeSplitShapesPool() ;
+
+
Standard_EXPORT Standard_Integer FindSDVertex(const Standard_Integer nV) const;
+
+
Standard_EXPORT Standard_Integer SplitsInFace(const Standard_Integer aBid,const Standard_Integer nF1,const Standard_Integer nF2,TColStd_ListOfInteger& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsInFace(const Standard_Integer nE1,const Standard_Integer nF2,TColStd_ListOfInteger& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsOnEdge(const Standard_Integer nE1,const Standard_Integer nE2,TColStd_ListOfInteger& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsOnFace(const Standard_Integer nE1,const Standard_Integer nF2,TColStd_ListOfInteger& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsOnFace(const Standard_Integer aBid,const Standard_Integer nF1,const Standard_Integer nF2,TColStd_ListOfInteger& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsInFace(const Standard_Integer aBid,const Standard_Integer nF1,const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsInFace(const Standard_Integer nE1,const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsOnEdge(const Standard_Integer nE1,const Standard_Integer nE2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsOnFace(const Standard_Integer nE1,const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsOnFace(const Standard_Integer aBid,const Standard_Integer nF1,const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsFace(const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT Standard_Integer SplitsFace(const Standard_Integer nF2,TColStd_ListOfInteger& aLs) ;
+
+
Standard_EXPORT Standard_Integer CommonBlocksFace(const Standard_Integer nF,NMTTools_ListOfCommonBlock& aLCB) ;
+
+
Standard_EXPORT void PrepareFace(const Standard_Integer nF,TopoDS_Face& aF) ;
+
+
Standard_EXPORT const BOPTools_PaveBlock& RealPaveBlock(const BOPTools_PaveBlock& aPB) ;
+
+
+Standard_EXPORT const BOPTools_PaveBlock& RealPaveBlock(const BOPTools_PaveBlock& aPB,TColStd_ListOfInteger& aLB) ;
+
+
Standard_EXPORT void RealSplitsFace(const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT Standard_Boolean HasRealSplitsInOnFace(const Standard_Integer nF1,const Standard_Integer nF2) ;
+
+
Standard_EXPORT void RealSplitsInFace(const Standard_Integer aBid,const Standard_Integer nF1,const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT void RealSplitsInFace(const Standard_Integer nE1,const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT void RealSplitsOnEdge(const Standard_Integer nE1,const Standard_Integer nE2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT void RealSplitsOnFace(const Standard_Integer nE1,const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT void RealSplitsOnFace(const Standard_Integer aBid,const Standard_Integer nF1,const Standard_Integer nF2,BOPTools_ListOfPaveBlock& aLs) ;
+
+
Standard_EXPORT void PrepareSetForFace(const Standard_Integer nF1,const Standard_Integer nF2,const BOPTools_ListOfPaveBlock& aLPB,BOPTools_PaveSet& aPSF) ;
+
+
Standard_EXPORT void PutPaveOnCurve(const BOPTools_PaveSet& aPSF,const Standard_Real aTol,BOPTools_Curve& aBC) ;
+
+
Standard_EXPORT void PutBoundPaveOnCurve(BOPTools_Curve& aBC,BOPTools_SSInterference& aFF) ;
+
+
Standard_EXPORT void PutBoundPaveOnCurve(const gp_Pnt& aP,const Standard_Real aT,BOPTools_Curve& aBC,BOPTools_SSInterference& aFF) ;
+
+
Standard_EXPORT Standard_Boolean FindPave(const gp_Pnt& aP,const Standard_Real aTpV,const BOPTools_PaveSet& aPS,BOPTools_Pave& aPV) ;
+
+
Standard_EXPORT Standard_Integer CheckIntermediatePoint(const BOPTools_PaveBlock& aPB,const BOPTools_PaveBlock& aPBR,const Standard_Real aTol) ;
+
+
Standard_EXPORT Standard_Boolean IsExistingPaveBlock(const BOPTools_PaveBlock& aPB,const BOPTools_ListOfPaveBlock& aLPB,const Standard_Real aTol) ;
+
+
Standard_EXPORT void MakePCurves() ;
+Standard_EXPORT const NMTTools_IndexedDataMapOfIndexedMapOfInteger& AloneVertices() const;
+
+
+Standard_EXPORT Standard_Boolean IsExistingPaveBlock(const BOPTools_PaveBlock& aPB,const TopTools_ListOfShape& aLPB,const Standard_Real aTol) ;
+
+
+Standard_EXPORT Standard_Boolean CheckCoincidence(const BOPTools_PaveBlock& aPB,const BOPTools_ListOfPaveBlock& aLPB) ;
+
+
+Standard_EXPORT Standard_Integer CheckIntermediatePoint(const BOPTools_PaveBlock& aPB,const TopoDS_Edge& aE,const Standard_Real aTol) ;
+
+
+Standard_EXPORT void SharedEdges(const Standard_Integer nF1,const Standard_Integer nF2,TColStd_ListOfInteger& aLNE,TopTools_ListOfShape& aLSE) ;
+
+
// Methods PROTECTED
//
-Standard_EXPORT void Init() ;
-Standard_EXPORT virtual void PerformVV() ;
+
+
Standard_EXPORT virtual void PerformVE() ;
+
+
Standard_EXPORT virtual void PerformVF() ;
+
+
Standard_EXPORT virtual void PerformEE() ;
+
+
Standard_EXPORT virtual void PerformEF() ;
+
+
Standard_EXPORT virtual void PerformFF() ;
+
+
Standard_EXPORT void MakeSplitEdges() ;
+
+
Standard_EXPORT virtual void PreparePaveBlocks(const TopAbs_ShapeEnum aType1,const TopAbs_ShapeEnum aType2) ;
+
+
Standard_EXPORT void CorrectShrunkRanges(const Standard_Integer aSide,const BOPTools_Pave& aPave,IntTools_ShrunkRange& aSR) ;
+
+
Standard_EXPORT virtual void PreparePaveBlocks(const Standard_Integer anE) ;
-Standard_EXPORT virtual void PerformNewVertices() ;
+
+
Standard_EXPORT virtual void PrepareEdges() ;
+
+
Standard_EXPORT void SortTypes(Standard_Integer& anInd1,Standard_Integer& anInd2) const;
+
+
Standard_EXPORT Standard_Integer ExpectedPoolLength() const;
+
+
Standard_EXPORT Standard_Boolean IsSuccesstorsComputed(const Standard_Integer iF1,const Standard_Integer iF2) const;
+
+
Standard_EXPORT Standard_Boolean IsBlocksCoinside(const BOPTools_PaveBlock& aPB1,const BOPTools_PaveBlock& aPB2) const;
+
+
Standard_EXPORT void RefinePavePool() ;
+
+
Standard_EXPORT Standard_Integer CheckFacePaves(const TopoDS_Vertex& aV,const Standard_Integer nF) ;
+
+
Standard_EXPORT void ReplaceCommonBlocks(const NMTTools_ListOfCommonBlock& aLCB) ;
+
+
Standard_EXPORT void RemoveCommonBlocks(const NMTTools_ListOfCommonBlock& aLCB) ;
+
+
Standard_EXPORT void SplitCommonBlocks(const NMTTools_ListOfCommonBlock& aLCB) ;
+
+
Standard_EXPORT void SplitCommonBlock(const NMTTools_CommonBlock& aCB,NMTTools_ListOfCommonBlock& aLCB) ;
+
+
Standard_EXPORT void EECommonBlocks(const BOPTools_IDMapOfPaveBlockIMapOfPaveBlock& aM) ;
+
+
Standard_EXPORT void EFCommonBlocks(const BOPTools_IDMapOfPaveBlockIMapOfInteger& aMapCB) ;
+
+
Standard_EXPORT void EENewVertices(const BooleanOperations_IndexedDataMapOfShapeInteger& aM) ;
+
+
Standard_EXPORT void EENewVertices(const TopoDS_Vertex& aV,const BooleanOperations_IndexedDataMapOfShapeInteger& aM) ;
+
+
Standard_EXPORT void EFNewVertices(const BooleanOperations_IndexedDataMapOfShapeInteger& aM) ;
+
+
Standard_EXPORT void EFNewVertices(const TopoDS_Vertex& aV,const BooleanOperations_IndexedDataMapOfShapeInteger& aM) ;
+
+
Standard_EXPORT void UpdateCommonBlocks() ;
+
+
Standard_EXPORT void UpdatePaveBlocks() ;
+
+
Standard_EXPORT Standard_Integer SplitIndex(const BOPTools_PaveBlock& aPB) const;
+
+
Standard_EXPORT void MakeBlocks() ;
+Standard_EXPORT void PerformVF1() ;
+
+
+Standard_EXPORT void MakeAloneVertices() ;
+
+
// Fields PROTECTED
//
BOPTools_PInterferencePool myIntrPool;
Standard_Boolean myIsDone;
Standard_Integer myNbSources;
Standard_Integer myNbEdges;
-NMTTools_IteratorOfCoupleOfShape myDSIt;
+NMTDS_Iterator myDSIt;
BOPTools_PavePool myPavePool;
BOPTools_PavePool myPavePoolNew;
NMTTools_CommonBlockPool myCommonBlockPool;
BOPTools_SplitShapesPool mySplitShapesPool;
IntTools_Context myContext;
BOPTools_SSIntersectionAttribute mySectionAttribute;
+NMTTools_IndexedDataMapOfIndexedMapOfInteger myAloneVertices;
private:
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _BOPTools_InterferencePool_HeaderFile
#include <BOPTools_InterferencePool.hxx>
#endif
#ifndef _gp_Pnt_HeaderFile
#include <gp_Pnt.hxx>
#endif
+#ifndef _NMTTools_IndexedDataMapOfIndexedMapOfInteger_HeaderFile
+#include <NMTTools_IndexedDataMapOfIndexedMapOfInteger.hxx>
+#endif
+#ifndef _TopTools_ListOfShape_HeaderFile
+#include <TopTools_ListOfShape.hxx>
+#endif
+#ifndef _TopoDS_Edge_HeaderFile
+#include <TopoDS_Edge.hxx>
+#endif
#ifndef _NMTTools_PaveFiller_HeaderFile
#include <NMTTools_PaveFiller.hxx>
#endif
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
-// File: NMTTools_PaveFiller_0.cxx
-// Created: Mon Dec 8 11:45:51 2003
+// File: NMTTools_PaveFiller_1.cxx
+// Created: Mon Dec 8 11:47:55 2003
// Author: Peter KURNEV
// <pkv@irinox>
-
#include <NMTTools_PaveFiller.ixx>
#include <TopAbs_ShapeEnum.hxx>
{
Standard_Integer aNbIIs;
Standard_Real aCfPredict=.5;
-
- const BOPTools_ListOfCoupleOfInteger& aLC=myDSIt.ListOfCouple();
- aNbIIs=aLC.Extent();
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ //const BOPTools_ListOfCoupleOfInteger& aLC=myDSIt.ListOfCouple();
+ //aNbIIs=aLC.Extent();
+ aNbIIs=myDSIt.ExpectedLength();
+ // Contribution of Samtech www.samcef.com END
//
if (aNbIIs==1) {
return aNbIIs;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <NMTDS_ShapesDataStructure.hxx>
#include <NMTTools_Tools.hxx>
#include <TopTools_IndexedMapOfShape.hxx>
-
-
//=======================================================================
// function: PerformVV
aWhat=n1;
aWith=n2;
SortTypes(aWhat, aWith);
+ //
if (!bJustAddInterference) {
- const TopoDS_Shape& aS1=myDS->GetShape(aWhat);
- const TopoDS_Shape& aS2=myDS->GetShape(aWith);
+ const TopoDS_Shape aS1=myDS->GetShape(aWhat);//mpv
+ const TopoDS_Shape aS2=myDS->GetShape(aWith);//mpv
+ //
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ if (aS1.IsSame(aS2)) {
+ continue;
+ }
+ // Contribution of Samtech www.samcef.com END
//
const TopoDS_Vertex& aV1=TopoDS::Vertex(aS1);
const TopoDS_Vertex& aV2=TopoDS::Vertex(aS2);
aNbV=aChain.Extent();
for (j=1; j<=aNbV; ++j) {
aIdV=aChain(j);
- const TopoDS_Shape& aV=myDS->Shape(aIdV);
+ const TopoDS_Shape aV=myDS->Shape(aIdV);//mpv
if (!aM.Contains(aV)) {
aM.Add(aV);
aLV.Append(aV);
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <TopoDS.hxx>
#include <TopoDS_Edge.hxx>
#include <TopoDS_Vertex.hxx>
+#include <TopoDS_Iterator.hxx>
#include <BRep_Builder.hxx>
#include <BRep_Tool.hxx>
#include <NMTDS_ShapesDataStructure.hxx>
//
+// Modified Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
#include <BOPTools_IndexedMapOfCoupleOfInteger.hxx>
#include <BOPTools_CoupleOfInteger.hxx>
+#include <BooleanOperations_OnceExplorer.hxx>
+//
+static
+ Standard_Boolean Contains(const TopoDS_Edge& aE,
+ const TopoDS_Vertex& aV);
+// Contribution of Samtech www.samcef.com END
//=======================================================================
// function: PrepareEdges
// purpose:
}
// Edge
aE2=TopoDS::Edge(myDS->Shape(aWith));
- //
if (BRep_Tool::Degenerated(aE2)){
continue;
}
if (iSDV) {
nV1=iSDV;
aV1=TopoDS::Vertex(myDS->Shape(nV1));
+ // Modified to find same domain vertex Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ Standard_Integer nVE, iSDVE, iRet;
+ //
+ BooleanOperations_OnceExplorer aExp(*myDS);
+ iRet=0;
+ aExp.Init(aWith, TopAbs_VERTEX);
+ for (; aExp.More(); aExp.Next()) {
+ nVE=aExp.Current();
+ iSDVE=FindSDVertex(nVE);
+ if (iSDVE==iSDV) {
+ iRet=1;
+ break;
+ }
+ }
+ if (iRet) {
+ continue;
+ }
+ }
+ else {
+ if (Contains(aE2, aV1)) {
+ continue;
+ }
+ // Contribution of Samtech www.samcef.com END
}
//
aFlag=myContext.ComputeVE (aV1, aE2, aT);
//
if (!aFlag) {
- //
// Add Interference to the Pool
BOPTools_VEInterference anInterf (aWhat, aWith, aT);
anIndexIn=aVEs.Append(anInterf);
}
myIsDone=Standard_True;
}
-
-/*
-// A
-//
- // cto900/M2
- // Some of Edges can be [Semi] Infinite. Such Edges have no
- // vertices on correspondant INF ends. So we must provide
- // these vertices formally (to obtain Shrunk Ranges for e.g).
- // In reality this vertex(-es) does not belong to the INF Edge.
- // It just has reference in the DS.
- // PKV Tue Apr 23 10:21:45 2002
- {
- Standard_Real aT1, aT2, aTolE;
- Standard_Boolean bInf1, bInf2;
- gp_Pnt aPx;
- TopoDS_Vertex aVx;
- BRep_Builder aBB;
- BooleanOperations_AncestorsSeqAndSuccessorsSeq anASSeq;
- //
- aTolE=BRep_Tool::Tolerance(aE);
- Handle(Geom_Curve) aC3D=BRep_Tool::Curve (aE, aT1, aT2);
- bInf1=Precision::IsNegativeInfinite(aT1);
- bInf2=Precision::IsPositiveInfinite(aT2);
-
- if (bInf1) {
- aC3D->D0(aT1, aPx);
- aBB.MakeVertex(aVx, aPx, aTolE);
- myDS->InsertShapeAndAncestorsSuccessors(aVx, anASSeq);
- nV=myDS->NumberOfInsertedShapes();
- BOPTools_Pave aPave(nV, aT1);
- aPaveSet.Append (aPave);
- }
-
- if (bInf2) {
- aC3D->D0(aT2, aPx);
- aBB.MakeVertex(aVx, aPx, aTolE);
- myDS->InsertShapeAndAncestorsSuccessors(aVx, anASSeq);
- nV=myDS->NumberOfInsertedShapes();
- BOPTools_Pave aPave(nV, aT2);
- aPaveSet.Append (aPave);
- }
- }
-*/
+// Modified Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+//=======================================================================
+//function : Contains
+//purpose :
+//=======================================================================
+Standard_Boolean Contains(const TopoDS_Edge& aE,
+ const TopoDS_Vertex& aV)
+{
+ Standard_Boolean bRet;
+ TopoDS_Iterator aIt;
+ //
+ bRet=Standard_False;
+ aIt.Initialize(aE);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Shape& aVE=aIt.Value();
+ if (aVE.IsSame(aV)) {
+ bRet=!bRet;
+ break;
+ }
+ }
+ return bRet;
+}
+// Contribution of Samtech www.samcef.com END
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <BOPTools_CArray1OfVSInterference.hxx>
#include <NMTDS_ShapesDataStructure.hxx>
+#include <TopExp_Explorer.hxx>
+// Modified Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+static
+ Standard_Boolean Contains(const TopoDS_Face& aF,
+ const TopoDS_Vertex& aV);
+// Contribution of Samtech www.samcef.com END
//=======================================================================
// function: PerformVF
// purpose:
//
aF2=TopoDS::Face(myDS->Shape(aWith));
//
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ if (Contains(aF2, aV1)) {
+ continue;
+ }
+ // Contribution of Samtech www.samcef.com END
+ //
aFlag=myContext.ComputeVS (aV1, aF2, aU, aV);
//
if (!aFlag) {
}
myIsDone=Standard_True;
}
+// Modified Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+//=======================================================================
+//function : Contains
+//purpose :
+//=======================================================================
+Standard_Boolean Contains(const TopoDS_Face& aF,
+ const TopoDS_Vertex& aV)
+{
+ Standard_Boolean bRet;
+ TopExp_Explorer aExp;
+ //
+ bRet=Standard_False;
+ aExp.Init(aF, TopAbs_VERTEX);
+ for (; aExp.More(); aExp.Next()) {
+ const TopoDS_Shape& aVF=aExp.Current();
+ if (aVF.IsSame(aV)) {
+ bRet=!bRet;
+ break;
+ }
+ }
+ return bRet;
+}
+// Contribution of Samtech www.samcef.com END
#include <NMTTools_CommonBlock.hxx>
#include <NMTTools_ListIteratorOfListOfCommonBlock.hxx>
+// Modified Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+#include <TColStd_ListOfInteger.hxx>
+#include <TColStd_ListIteratorOfListOfInteger.hxx>
+#include <BRepBndLib.hxx>
+#include <BOPTools_CArray1OfVSInterference.hxx>
+#include <BOPTools_VSInterference.hxx>
+// Contribution of Samtech www.samcef.com END
//
static
void VertexParameters(const IntTools_CommonPrt& aCPart,
Standard_Boolean IsOnPave(const Standard_Real& aT1,
const IntTools_Range& aRange,
const Standard_Real& aTolerance);
+static
+ void EECommonBlocks(const BOPTools_IDMapOfPaveBlockIMapOfPaveBlock& aMapCB);
+
static
void ProcessBlock(const BOPTools_PaveBlock& aPB,
const BOPTools_IDMapOfPaveBlockIMapOfPaveBlock& aMapCB,
Standard_Boolean bJustAdd;
Standard_Integer n1, n2, anIndexIn, nE1, nE2, aNbVEs, aBlockLength;
Standard_Integer aTmp, aWhat, aWith, i, aNbCPrts, aDiscretize=30;
+ Standard_Integer aNbLPB1, aNbLPB2;
Standard_Real aTolE1, aTolE2, aDeflection=0.01;
BOPTools_ListIteratorOfListOfPaveBlock anIt1, anIt2;
TopoDS_Edge aEWhat, aEWith;
continue;
}
//
- const TopoDS_Edge& aE1=TopoDS::Edge(myDS->Shape(nE1));
- const TopoDS_Edge& aE2=TopoDS::Edge(myDS->Shape(nE2));
+ const TopoDS_Edge aE1=TopoDS::Edge(myDS->Shape(nE1));//mpv
+ const TopoDS_Edge aE2=TopoDS::Edge(myDS->Shape(nE2));//mpv
+
//
if (BRep_Tool::Degenerated(aE1) || BRep_Tool::Degenerated(aE2)){
continue;
aTolE2=BRep_Tool::Tolerance(aE2);
//
BOPTools_ListOfPaveBlock& aLPB1=mySplitShapesPool(myDS->RefEdge(nE1));
+ BOPTools_ListOfPaveBlock& aLPB2=mySplitShapesPool(myDS->RefEdge(nE2));
+ //
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ aNbLPB1=aLPB1.Extent();
+ aNbLPB2=aLPB2.Extent();
+
+ //if (aE1.IsSame(aE2) && aNbLPB1==1 && aNbLPB2==1) {
+ // continue;
+ //}
+ // Contribution of Samtech www.samcef.com END
//
for (anIt1.Initialize(aLPB1); anIt1.More(); anIt1.Next()) {
BOPTools_PaveBlock& aPB1=anIt1.Value();
const IntTools_Range& aSR1=aShrunkRange1.ShrunkRange();
const Bnd_Box& aBB1=aShrunkRange1.BndBox();
//
- BOPTools_ListOfPaveBlock& aLPB2=mySplitShapesPool(myDS->RefEdge(nE2));
- //
for (anIt2.Initialize(aLPB2); anIt2.More(); anIt2.Next()) {
BOPTools_PaveBlock& aPB2=anIt2.Value();
const IntTools_ShrunkRange& aShrunkRange2=aPB2.ShrunkRange();
//
EENewVertices (aMapVI);
EECommonBlocks(aMapCB);
- //
+ // Modified to invoke new nethod Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ PerformVF1();
+ // Contribution of Samtech www.samcef.com BEGIN
myIsDone=Standard_True;
}
//=======================================================================
aNbEdges=aME.Extent();
for (j=1; j<=aNbEdges; ++j) {
nE=aME(j);
- const TopoDS_Edge& aE=TopoDS::Edge(myDS->Shape(nE));
+ const TopoDS_Edge aE=TopoDS::Edge(myDS->Shape(nE));//mpv
//
aFlag=myContext.ComputeVE (aNewVertex, aE, aT);
//
Standard_Real d1121, d1122, d1222, d1221, aTolSum, aCoeff=1.05;
gp_Pnt aP11, aP12, aP21, aP22;
- const TopoDS_Vertex& aV11=TopoDS::Vertex(myDS->Shape(aPB1.Pave1().Index()));
- const TopoDS_Vertex& aV12=TopoDS::Vertex(myDS->Shape(aPB1.Pave2().Index()));
- const TopoDS_Vertex& aV21=TopoDS::Vertex(myDS->Shape(aPB2.Pave1().Index()));
- const TopoDS_Vertex& aV22=TopoDS::Vertex(myDS->Shape(aPB2.Pave2().Index()));
+ const TopoDS_Vertex aV11=TopoDS::Vertex(myDS->Shape(aPB1.Pave1().Index()));//mpv
+ const TopoDS_Vertex aV12=TopoDS::Vertex(myDS->Shape(aPB1.Pave2().Index()));//mpv
+ const TopoDS_Vertex aV21=TopoDS::Vertex(myDS->Shape(aPB2.Pave1().Index()));//mpv
+ const TopoDS_Vertex aV22=TopoDS::Vertex(myDS->Shape(aPB2.Pave2().Index()));//mpv
aTolV11=BRep_Tool::Tolerance(aV11);
aTolV12=BRep_Tool::Tolerance(aV12);
}
}
}
+ // Modified to provide the order of edges
+ // in common block where the edge with max
+ // tolerance value will be the first
+ // Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ Standard_Integer i, iMax, aNb, aNbCB, nSp;
+ Standard_Real aTolSp, aTolMax;
+ BOPTools_ListOfPaveBlock *pLPBE;
+ //
+ aNb=myDS->NumberOfShapesOfTheObject();
+ for (nE=1; nE<=aNb; ++nE) {
+ const TopoDS_Shape& aE=myDS->Shape(nE);
+ if (aE.ShapeType()!=TopAbs_EDGE) {
+ continue;
+ }
+ //
+ NMTTools_ListOfCommonBlock& aLCBE=myCommonBlockPool(myDS->RefEdge(nE));
+ aNbCB=aLCBE.Extent();
+ if (!aNbCB) {
+ continue;
+ }
+ //
+ anIt.Initialize(aLCBE);
+ for (; anIt.More(); anIt.Next()) {
+ NMTTools_CommonBlock& aCBE=anIt.Value();
+ const BOPTools_ListOfPaveBlock& aLPBE=aCBE.PaveBlocks();
+ //
+ aTolMax=-1.;
+ anItLPE.Initialize(aLPBE);
+ for (i=0; anItLPE.More(); anItLPE.Next(), ++i) {
+ const BOPTools_PaveBlock& aPB=anItLPE.Value();
+ nSp=aPB.OriginalEdge();
+ const TopoDS_Edge& aSp=TopoDS::Edge(myDS->Shape(nSp));
+ aTolSp=BRep_Tool::Tolerance(aSp);
+ if (aTolSp>aTolMax) {
+ iMax=i;
+ aTolSp=aTolMax;
+ }
+ }
+ //
+ BOPTools_ListOfPaveBlock aLPBx;
+ //
+ anItLPE.Initialize(aLPBE);
+ for (i=0; anItLPE.More(); anItLPE.Next(), ++i) {
+ const BOPTools_PaveBlock& aPB=anItLPE.Value();
+ if (i==iMax) {
+ aLPBx.Prepend(aPB);
+ }
+ else {
+ aLPBx.Append(aPB);
+ }
+ }
+ //
+ pLPBE=(BOPTools_ListOfPaveBlock *)&aLPBE;
+ pLPBE->Clear();
+ pLPBE->Append(aLPBx);
+ }//for (; anIt.More(); anIt.Next()) {
+ }//for (nE=1; nE<=aNb; ++nE) {
+ // Contribution of Samtech www.samcef.com END
}
//=======================================================================
// function: RemoveCommonBlocks
ProcessBlock(aPBx, aMapCB, aProcessedBlocks, aChain);
}
}
+// Modified to provide VS interference between
+// vertex as result of EE and a Face of argument
+// Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+//=======================================================================
+// function: PerformVF1
+// purpose:
+//=======================================================================
+ void NMTTools_PaveFiller::PerformVF1()
+{
+ Standard_Integer i, aNbEE, n1, n2, nNewShape, aNbS, nF;
+ Standard_Integer anIndexIn, aFlag;
+ Standard_Real aU, aV;
+ TColStd_ListOfInteger aLFI;
+ TColStd_ListIteratorOfListOfInteger aItLFI;
+ //
+ BOPTools_CArray1OfVSInterference& aVSs=myIntrPool->VSInterferences();
+ BOPTools_CArray1OfEEInterference& aEEs=myIntrPool->EEInterferences();
+ //
+ aNbS=myDS->NumberOfShapesOfTheObject();
+ for (i=1; i<=aNbS; ++i) {
+ const TopoDS_Shape& aF=myDS->Shape(i);
+ if (aF.ShapeType()==TopAbs_FACE) {
+ aLFI.Append(i);
+ }
+ }
+ if (!aLFI.Extent()) {
+ return;
+ }
+ //
+ aNbEE=aEEs.Extent();
+ for (i=1; i<=aNbEE; ++i) {
+ BOPTools_EEInterference& aEE=aEEs(i);
+ aEE.Indices(n1, n2);
+ nNewShape=aEE.NewShape();
+ if (!nNewShape) {
+ continue;
+ }
+ //
+ const TopoDS_Shape& aSnew=myDS->Shape(nNewShape);
+ if (aSnew.ShapeType()!=TopAbs_VERTEX) {
+ continue;
+ }
+ //
+ const TopoDS_Vertex& aVnew=TopoDS::Vertex(aSnew);
+ //
+ Bnd_Box aBV;
+ //
+ BRepBndLib::Add(aVnew, aBV);
+ //
+ aItLFI.Initialize(aLFI);
+ for (; aItLFI.More(); aItLFI.Next()) {
+ nF=aItLFI.Value();
+ //
+ const TopoDS_Face& aF=TopoDS::Face(myDS->Shape(nF));
+ const Bnd_Box& aBF=myDS->GetBoundingBox(nF);
+ if (aBF.IsOut(aBV)) {
+ continue;
+ }
+ //
+ anIndexIn=0;
+ aFlag=myContext.ComputeVS (aVnew, aF, aU, aV);
+ if (!aFlag) {
+ BOPTools_VSInterference anInterf (nNewShape, nF, aU, aV);
+ //
+ anIndexIn=aVSs.Append(anInterf);
+ BOPTools_VSInterference& aVS=aVSs(anIndexIn);
+ aVS.SetNewShape(nNewShape);//->
+ }
+ }
+ }
+}
+// Contribution of Samtech www.samcef.com END
#include <NMTTools_IndexedDataMapOfIndexedMapOfInteger.hxx>
#include <NMTTools_CommonBlockAPI.hxx>
#include <NMTTools_ListOfCommonBlock.hxx>
+#include <TopTools_IndexedMapOfShape.hxx>
+#include <TopExp.hxx>
static
void VertexParameter(const IntTools_CommonPrt& aCPart,
Standard_Boolean IsOnPave(const Standard_Real& aTR,
const IntTools_Range& aCPRange,
const Standard_Real& aTolerance);
-
+//
//=======================================================================
// function: PerformEF
// purpose:
BooleanOperations_IndexedDataMapOfShapeInteger aMapVI;
BOPTools_IDMapOfPaveBlockIMapOfInteger aMapCB;
BOPTools_IMapOfPaveBlock aIMPBx;
-
//
BOPTools_CArray1OfESInterference& aEFs=myIntrPool->ESInterferences();
//
continue;
}
// Edge
- const TopoDS_Edge& aE=TopoDS::Edge(myDS->GetShape(nE));
+ const TopoDS_Edge aE=TopoDS::Edge(myDS->GetShape(nE));//mpv
if (BRep_Tool::Degenerated(aE)){
continue;
}
- aTolE=BRep_Tool::Tolerance(aE);
// Face
- const TopoDS_Face& aF=TopoDS::Face(myDS->GetShape(nF));
+ const TopoDS_Face aF=TopoDS::Face(myDS->GetShape(nF));//mpv
+ //
+ // Modified
+ // to avoid intersection between face and edge from that face
+ // Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ TopTools_IndexedMapOfShape aME;
+ //
+ TopExp::MapShapes(aF, TopAbs_EDGE, aME);
+ if (aME.Contains(aE)) {
+ continue;
+ }
+ // Contribution of Samtech www.samcef.com END
+ //
aTolF=BRep_Tool::Tolerance(aF);
+
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ aTolE=BRep_Tool::Tolerance(aE);
+ // Contribution of Samtech www.samcef.com END
+
const Bnd_Box& aBBF=myDS->GetBoundingBox(nF);
//
// Process each PaveBlock on edge nE
aNbEdges=aME.Extent();
for (j=1; j<=aNbEdges; ++j) {
nE=aME(j);
- const TopoDS_Edge& aE=TopoDS::Edge(myDS->Shape(nE));
+ const TopoDS_Edge aE=TopoDS::Edge(myDS->Shape(nE));//mpv
//
aFlag=myContext.ComputeVE (aNewVertex, aE, aT);
//
aNbV=aMVF.Extent();
for (i=1; i<=aNbV; ++i) {
nVF=aMVF(i);
- const TopoDS_Vertex& aVF=TopoDS::Vertex(myDS->Shape(nVF));
+ const TopoDS_Vertex aVF=TopoDS::Vertex(myDS->Shape(nVF));//mpv
iFlag=IntTools_Tools::ComputeVV(aNewVertex, aVF);
if (!iFlag) {
return nVF;
#include <TColStd_MapOfInteger.hxx>
#include <Geom2d_Curve.hxx>
-#include <Geom2d_TrimmedCurve.hxx>
#include <Geom_TrimmedCurve.hxx>
#include <GeomAdaptor_Curve.hxx>
#include <BRep_Builder.hxx>
#include <BRep_Tool.hxx>
#include <BRepBndLib.hxx>
-#include <BRepLib.hxx>
#include <TopTools_IndexedMapOfShape.hxx>
#include <NMTDS_ShapesDataStructure.hxx>
#include <NMTTools_IndexedDataMapOfShapePaveBlock.hxx>
#include <NMTTools_CommonBlockAPI.hxx>
+#include <Geom2d_Curve.hxx>
#include <NMTTools_Tools.hxx>
+#include <BRepLib.hxx>
+#include <Geom2d_TrimmedCurve.hxx>
+//
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
+#include <TopTools_ListOfShape.hxx>
+#include <TopTools_ListIteratorOfListOfShape.hxx>
+#include <TopoDS_Vertex.hxx>
+#include <TopoDS.hxx>
+#include <TopoDS_Edge.hxx>
+#include <TColStd_ListOfInteger.hxx>
static
Standard_Boolean IsPairFound(const Standard_Integer nF1,
Standard_Boolean IsFound(const TColStd_IndexedMapOfInteger& aMapWhat,
const TColStd_IndexedMapOfInteger& aMapWith);
+// Modified Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+static
+ void SharedEdges1(const TopoDS_Face& aF1,
+ const TopoDS_Face& aF2,
+ TopTools_ListOfShape& aLS);
+// Contribution of Samtech www.samcef.com END
//=======================================================================
// function: PerformFF
continue;
}
//
- const TopoDS_Face& aF1=TopoDS::Face(myDS->Shape(nF1));
- const TopoDS_Face& aF2=TopoDS::Face(myDS->Shape(nF2));
+ const TopoDS_Face aF1=TopoDS::Face(myDS->Shape(nF1));//mpv
+ const TopoDS_Face aF2=TopoDS::Face(myDS->Shape(nF2));//mpv
//
// FF
bToApproxC3d = mySectionAttribute.Approximation();
{
myIsDone=Standard_False;
//
- Standard_Boolean bIsExistingPaveBlock, bIsValidIn2D;
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ Standard_Boolean bIsExistingPaveBlock, bIsValidIn2D, bIsCoincided;
+ // Contribution of Samtech www.samcef.com END
+ //
Standard_Integer i, aNbFFs, nF1, nF2, aBid=0;
Standard_Integer nV1, nV2, j, aNbCurves;
Standard_Real aTolR3D, aTol2D, aT1, aT2, aTolPPC=Precision::PConfusion();
//
// Faces
aFFi.Indices(nF1, nF2);
- const TopoDS_Face& aF1=TopoDS::Face(myDS->Shape(nF1));
- const TopoDS_Face& aF2=TopoDS::Face(myDS->Shape(nF2));
+ const TopoDS_Face aF1=TopoDS::Face(myDS->Shape(nF1));//mpv
+ const TopoDS_Face aF2=TopoDS::Face(myDS->Shape(nF2));//mpv
+ //
+ BOPTools_ListOfPaveBlock aLPB;
+ //
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ RealSplitsInFace (aBid, nF1, nF2, aLPB);
+ RealSplitsInFace (aBid, nF2, nF1, aLPB);
+ RealSplitsOnFace (aBid, nF1, nF2, aLPB);
+ //
+ anIt.Initialize(aLPB);
+ for (; anIt.More(); anIt.Next()) {
+ const BOPTools_PaveBlock& aPB=anIt.Value();
+ aFFi.AppendBlock(aPB);
+ }
+ //
+ TopTools_ListOfShape aLSE;
+ TColStd_ListOfInteger aLNE;
+ SharedEdges(nF1, nF2, aLNE, aLSE);
+ aFFi.SetSharedEdges(aLNE);
//
- BOPTools_ListOfPaveBlock aLPB, aLPBC;
+ //
+ BOPTools_SequenceOfCurves& aSCvs=aFFi.Curves();
+ aNbCurves=aSCvs.Length();
+ if (!aNbCurves) {
+ continue;
+ }
+ //
+ BOPTools_ListOfPaveBlock aLPBC;
+ // Contribution of Samtech www.samcef.com END
//
{
Standard_Integer nFj1, nFj2, nE;
}
}
//
- //
- RealSplitsInFace (aBid, nF1, nF2, aLPB);
- RealSplitsInFace (aBid, nF2, nF1, aLPB);
- RealSplitsOnFace (aBid, nF1, nF2, aLPB);
- //
- anIt.Initialize(aLPB);
- for (; anIt.More(); anIt.Next()) {
- const BOPTools_PaveBlock& aPB=anIt.Value();
- aFFi.AppendBlock(aPB);
- }
- //
- BOPTools_SequenceOfCurves& aSCvs=aFFi.Curves();
- aNbCurves=aSCvs.Length();
- if (!aNbCurves) {
- continue;
- }
- //
aTolR3D=aFFi.TolR3D();
aTol2D=(aTolR3D < 1.e-3) ? 1.e-3 : aTolR3D;
//
BOPTools_PaveSet aPSF;
//
PrepareSetForFace (nF1, nF2, aLPBC, aPSF);
- //PrepareSetForFace (nF1, nF2, aPSF);
//
// Put Paves On Curves
for (j=1; j<=aNbCurves; ++j) {
// 1
const BOPTools_ListOfPaveBlock& aLPBFF=aFFi.PaveBlocks();
bIsExistingPaveBlock=IsExistingPaveBlock(aPBNew, aLPBFF, aTolR3D);
- //bIsExistingPaveBlock=IsExistingPaveBlock(aPBNew, aFFi);
if (bIsExistingPaveBlock) {
continue;
}
+ //
+ // Modified
+ // to provide checking of coincidence between aPBNew
+ // and each blocks of list aLPBFF
+ // Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ bIsCoincided=CheckCoincidence(aPBNew, aLPBFF);
+ if(bIsCoincided) {
+ continue;
+ }
+ // Contribution of Samtech www.samcef.com END
+ //
// 2
bIsExistingPaveBlock=IsExistingPaveBlock(aPBNew, aLPBC, aTolR3D);
if (bIsExistingPaveBlock) {
continue;
}
+ //
+ // Modified
+ // to provide checking whether aPBNew already exists in list
+ // of section edges aLSE
+ // Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ // 3
+ bIsExistingPaveBlock=IsExistingPaveBlock(aPBNew, aLSE, aTolR3D);
+ if (bIsExistingPaveBlock) {
+ continue;
+ }
+ // Contribution of Samtech www.samcef.com END
+ //
// Checking of validity in 2D
//
bIsValidIn2D=myContext.IsValidBlockForFaces(aT1, aT2, aIC, aF1, aF2, aTol2D);
// Make Section Edge
TopoDS_Edge aES;
//
- const TopoDS_Vertex& aV1=TopoDS::Vertex(myDS->Shape(nV1));
- const TopoDS_Vertex& aV2=TopoDS::Vertex(myDS->Shape(nV2));
+ const TopoDS_Vertex aV1=TopoDS::Vertex(myDS->Shape(nV1));//mpv
+ const TopoDS_Vertex aV2=TopoDS::Vertex(myDS->Shape(nV2));//mpv
//
BOPTools_Tools::MakeSectEdge (aIC, aV1, aT1, aV2, aT2, aES);
//
for (j=1; j<=aNbSE; ++j) {
const BOPTools_PaveBlock& aPBSE=aMEPB(j);
nV1=aPBSE.Pave1().Index();
- const TopoDS_Shape& aV1=myDS->Shape(nV1);
+ const TopoDS_Shape aV1=myDS->Shape(nV1);//mpv
if (aV1.IsSame(aV)) {
aMNewOld.Add(i, nV1);
break;
}
nV2=aPBSE.Pave2().Index();
- const TopoDS_Shape& aV2=myDS->Shape(nV2);
+ const TopoDS_Shape aV2=myDS->Shape(nV2);//mpv
if (aV2.IsSame(aV)) {
aMNewOld.Add(i, nV2);
break;
BooleanOperations_AncestorsSeqAndSuccessorsSeq anASSeq;
//
nV1=aPBSE.Pave1().Index();
- const TopoDS_Shape& aV1=myDS->Shape(nV1);
+ const TopoDS_Shape aV1=myDS->Shape(nV1);//mpv
nV2=aPBSE.Pave2().Index();
- const TopoDS_Shape& aV2=myDS->Shape(nV2);
+ const TopoDS_Shape aV2=myDS->Shape(nV2);//mpv
//
anASSeq.SetNewSuccessor(nV1);
anASSeq.SetNewOrientation(aV1.Orientation());
//
nF1=aPBSE.Face1();
nF2=aPBSE.Face2();
- //
//modified by NIZNHY-PKV Thu Jan 26 10:17:04 2006f
//const TopoDS_Face& aF1=TopoDS::Face(myDS->Shape(nF1));
//const TopoDS_Face& aF2=TopoDS::Face(myDS->Shape(nF2));
BOPTools_PaveBlock aPB=aIt.Value();
//
////modified by NIZNHY-PKV Thu Jan 26 10:16:36 2006f
- const TopoDS_Face& aF1=TopoDS::Face(myDS->Shape(nF1));
- const TopoDS_Face& aF2=TopoDS::Face(myDS->Shape(nF2));
+ const TopoDS_Face aF1=TopoDS::Face(myDS->Shape(nF1));
+ const TopoDS_Face aF2=TopoDS::Face(myDS->Shape(nF2));
////modified by NIZNHY-PKV Thu Jan 26 10:16:39 2006t
//
if (aCBAPI.IsCommonBlock(aPB)) {
const TopoDS_Edge& aEx=TopoDS::Edge(tDS.Shape(mE));
aTolEx=BRep_Tool::Tolerance(aEx);
//
- // <- Block A was here
+ // Commented out by EAP in the frame of PAL9151
+ //
+// Standard_Boolean bHasPCOnF, bFound;
+// Standard_Integer nF, k, nEOrx, nF1x, nF2x;
+// Standard_Real aTolEx, aT1x, aT2x;
+// BOPTools_ListIteratorOfListOfPaveBlock aItPBx;
//
+// for (k=0; k<2; ++k) {
+// nF=(!k) ? nF1 : nF2;
+// const TopoDS_Face& aF=TopoDS::Face(myDS->Shape(nF));
+// //
+// bHasPCOnF=BOPTools_Tools2D::HasCurveOnSurface(aEx, aF);
+// if (bHasPCOnF) {
+// continue;
+// }
+// //
+// bFound=Standard_False;
+// aItPBx.Initialize(aLPBx);
+// for (; aItPBx.More(); aItPBx.Next()) {
+// BOPTools_PaveBlock& aPBx=aIt.Value();
+// nEOrx=aPBx.OriginalEdge();
+// const TopoDS_Shape& aEOrx=tDS.Shape(nEOrx);
+// BOPTools_PaveBlock& aPBSEx=aMEPB.ChangeFromKey(aEOrx);
+// aT1x=aPBSEx.Pave1().Param();
+// aT2x=aPBSEx.Pave2().Param();
+// const IntTools_Curve& aICx=aPBSEx.Curve();
+// //
+// nF1x=aPBSEx.Face1();
+// nF2x=aPBSEx.Face2();
+// //
+// if (nF1x==nF) {
+// Handle(Geom2d_Curve) aC2D1x=aICx.FirstCurve2d();
+// Handle(Geom2d_TrimmedCurve)aC2D1xT =new Geom2d_TrimmedCurve(aC2D1x, aT1x, aT2x);
+// aBB.UpdateEdge(aEx, aC2D1xT, aF, aTolEx);
+// bFound=!bFound;
+// break;
+// }
+// //
+// if (nF2x==nF) {
+// Handle(Geom2d_Curve) aC2D2x=aICx.SecondCurve2d();
+// Handle(Geom2d_TrimmedCurve)aC2D2xT =new Geom2d_TrimmedCurve(aC2D2x, aT1x, aT2x);
+// aBB.UpdateEdge(aEx, aC2D2xT, aF, aTolEx);
+// bFound=!bFound;
+// break;
+// }
+// }
+// if (bFound){
+// BRepLib::SameParameter(aEx, aTolEx, Standard_True);
+// }
+// }
+ //
+ // The code till the if block end is restored from V2_2_2 revision
+ //
aF1FWD=aF1;
aF1FWD.Orientation(TopAbs_FORWARD);
NMTTools_Tools::MakePCurve(aEx, aF1FWD, aC2D1, aTolEx);
aT1=aPave1.Param();
mV1=aPave1.Index(); // index in tDS
nV1=aMNewOld.FindFromKey(mV1); // index in myDS
- const TopoDS_Shape& aV1=myDS->Shape(nV1);
+ const TopoDS_Shape aV1=myDS->Shape(nV1);//mpv
//
const BOPTools_Pave& aPave2=aPB.Pave2();
aT2=aPave2.Param();
mV2=aPave2.Index();
nV2=aMNewOld.FindFromKey(mV2);
- const TopoDS_Shape& aV2=myDS->Shape(nV2);
+ const TopoDS_Shape aV2=myDS->Shape(nV2);//mpv
//
if (!aMNewOld.Contains(mE)) {
// add new SE to the myDS
BOPTools_SSInterference& aFF=aFFs(i);
aFF.Indices(nF1, nF2);
//
- const TopoDS_Face& aF1=TopoDS::Face(myDS->Shape(nF1));
- const TopoDS_Face& aF2=TopoDS::Face(myDS->Shape(nF2));
+ const TopoDS_Face aF1=TopoDS::Face(myDS->Shape(nF1));//mpv
+ const TopoDS_Face aF2=TopoDS::Face(myDS->Shape(nF2));//mpv
//
aF1FWD=aF1;
aF1FWD.Orientation(TopAbs_FORWARD);
for (; anIt.More(); anIt.Next()) {
const BOPTools_PaveBlock& aPB=anIt.Value();
nE=aPB.Edge();
- const TopoDS_Edge& aE=TopoDS::Edge(myDS->Shape(nE));
+ const TopoDS_Edge aE=TopoDS::Edge(myDS->Shape(nE));//mpv
BOPTools_Tools2D::BuildPCurveForEdgeOnFace(aE, aF1FWD);
BOPTools_Tools2D::BuildPCurveForEdgeOnFace(aE, aF2FWD);
return bFlag;
}
//=======================================================================
+// function: IsExistingPaveBlock
+// purpose:
+//=======================================================================
+ Standard_Boolean NMTTools_PaveFiller::IsExistingPaveBlock(const BOPTools_PaveBlock& aPBNew,
+ const TopTools_ListOfShape& aLSE,
+ const Standard_Real aTolR3D)
+{
+ Standard_Boolean bFlag;
+ Standard_Integer aNbSE, iC;
+ TopTools_ListIteratorOfListOfShape anIt;
+ //
+ bFlag=Standard_False;
+ //
+ aNbSE=aLSE.Extent();
+ if (!aNbSE) {
+ return bFlag;
+ }
+ //
+ anIt.Initialize(aLSE);
+ for (; anIt.More(); anIt.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(anIt.Value());
+ iC=CheckIntermediatePoint(aPBNew, aE, aTolR3D);
+ if (!iC) {
+ return !bFlag;
+ }
+ }
+ return bFlag;
+}
+//=======================================================================
// function: CheckIntermediatePoint
// purpose:
//=======================================================================
const Standard_Real aTolC)
{
- Standard_Real aT11, aT12, aTM, aTmp;
Standard_Integer iVM, nE2;
+ //
+ nE2=aPBR.Edge();
+ const TopoDS_Edge aE2=TopoDS::Edge(myDS->Shape(nE2));//mpv
+ iVM=CheckIntermediatePoint(aPB, aE2, aTolC);
+ //
+ return iVM;
+}
+//=======================================================================
+// function: CheckIntermediatePoint
+// purpose:
+//=======================================================================
+ Standard_Integer NMTTools_PaveFiller::CheckIntermediatePoint(const BOPTools_PaveBlock& aPB,
+ const TopoDS_Edge& aE2,
+ const Standard_Real aTolC)
+{
+ Standard_Real aT11, aT12, aTM, aTmp;
+ Standard_Integer iVM;
gp_Pnt aPM;
BRep_Builder aBB;
TopoDS_Vertex aVM;
//
aBB.MakeVertex (aVM, aPM, aTolC);
//
- //Edge
- nE2=aPBR.Edge();
- const TopoDS_Edge& aE2=TopoDS::Edge(myDS->GetShape(nE2));
- // VE
iVM=myContext.ComputeVE(aVM, aE2, aTmp);
//
return iVM;
aFFi.Indices(nF1, nF2);
aTolR3D=aFFi.TolR3D();
//
- const TopoDS_Face& aF1=TopoDS::Face(myDS->GetShape(nF1));
- const TopoDS_Face& aF2=TopoDS::Face(myDS->GetShape(nF2));
+ const TopoDS_Face aF1=TopoDS::Face(myDS->GetShape(nF1));//mpv
+ const TopoDS_Face aF2=TopoDS::Face(myDS->GetShape(nF2));//mpv
//
bVF=myContext.IsValidPointForFaces (aP1, aF1, aF2, aTolR3D);
if (bVF) {
aPave.SetParam(aT);
aFFiPS.Append(aPave);
//
- const TopoDS_Vertex& aV=TopoDS::Vertex(myDS->Shape(nV));
+ const TopoDS_Vertex aV=TopoDS::Vertex(myDS->Shape(nV));//mpv
BOPTools_Tools::UpdateVertex (aIC, aT, aV);
}
aPave.SetParam(aT);
aCPS.Append(aPave);
//
- const TopoDS_Vertex& aV=TopoDS::Vertex(myDS->Shape(nV));
+ const TopoDS_Vertex aV=TopoDS::Vertex(myDS->Shape(nV));//mpv
BOPTools_Tools::UpdateVertex (aIC, aT, aV);
}
}
for (; anIt.More(); anIt.Next()) {
const BOPTools_Pave& aPC=anIt.Value();
nV=aPC.Index();
- const TopoDS_Vertex& aV=TopoDS::Vertex(myDS->Shape(nV));
+ const TopoDS_Vertex aV=TopoDS::Vertex(myDS->Shape(nV));//mpv
bIsVertex=IntTools_Tools::IsVertex (aP, aTolPV, aV);
if (bIsVertex) {
aPave=aPC;
const BOPTools_Pave& aPave=anIt.Value();
//
nV=aPave.Index();
- const TopoDS_Vertex& aV=TopoDS::Vertex(myDS->Shape(nV));
+ const TopoDS_Vertex aV=TopoDS::Vertex(myDS->Shape(nV));//mpv
//
Bnd_Box aBBV;
BRepBndLib::Add(aV, aBBV);
}
return bFlag;
}
-//
-// Block A
-//
- //
- // Commented out by EAP in the frame of PAL9151
- //
-// Standard_Boolean bHasPCOnF, bFound;
-// Standard_Integer nF, k, nEOrx, nF1x, nF2x;
-// Standard_Real aTolEx, aT1x, aT2x;
-// BOPTools_ListIteratorOfListOfPaveBlock aItPBx;
- //
-// for (k=0; k<2; ++k) {
-// nF=(!k) ? nF1 : nF2;
-// const TopoDS_Face& aF=TopoDS::Face(myDS->Shape(nF));
-// //
-// bHasPCOnF=BOPTools_Tools2D::HasCurveOnSurface(aEx, aF);
-// if (bHasPCOnF) {
-// continue;
-// }
-// //
-// bFound=Standard_False;
-// aItPBx.Initialize(aLPBx);
-// for (; aItPBx.More(); aItPBx.Next()) {
-// BOPTools_PaveBlock& aPBx=aIt.Value();
-// nEOrx=aPBx.OriginalEdge();
-// const TopoDS_Shape& aEOrx=tDS.Shape(nEOrx);
-// BOPTools_PaveBlock& aPBSEx=aMEPB.ChangeFromKey(aEOrx);
-// aT1x=aPBSEx.Pave1().Param();
-// aT2x=aPBSEx.Pave2().Param();
-// const IntTools_Curve& aICx=aPBSEx.Curve();
-// //
-// nF1x=aPBSEx.Face1();
-// nF2x=aPBSEx.Face2();
-// //
-// if (nF1x==nF) {
-// Handle(Geom2d_Curve) aC2D1x=aICx.FirstCurve2d();
-// Handle(Geom2d_TrimmedCurve)aC2D1xT =new Geom2d_TrimmedCurve(aC2D1x, aT1x, aT2x);
-// aBB.UpdateEdge(aEx, aC2D1xT, aF, aTolEx);
-// bFound=!bFound;
-// break;
-// }
-// //
-// if (nF2x==nF) {
-// Handle(Geom2d_Curve) aC2D2x=aICx.SecondCurve2d();
-// Handle(Geom2d_TrimmedCurve)aC2D2xT =new Geom2d_TrimmedCurve(aC2D2x, aT1x, aT2x);
-// aBB.UpdateEdge(aEx, aC2D2xT, aF, aTolEx);
-// bFound=!bFound;
-// break;
-// }
-// }
-// if (bFound){
-// BRepLib::SameParameter(aEx, aTolEx, Standard_True);
-// }
-// }
- //
- // The code till the if block end is restored from V2_2_2 revision
+// Modified Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+//=======================================================================
+//function : SharedEdges1
+//purpose :
+//=======================================================================
+void SharedEdges1(const TopoDS_Face& aF1,
+ const TopoDS_Face& aF2,
+ TopTools_ListOfShape& aLS)
+{
+ Standard_Integer i, aNbE, aNbF;;
+ TopTools_IndexedDataMapOfShapeListOfShape aMEF;
+ //
+ TopExp::MapShapesAndAncestors(aF1, TopAbs_EDGE, TopAbs_FACE, aMEF);
+ TopExp::MapShapesAndAncestors(aF2, TopAbs_EDGE, TopAbs_FACE, aMEF);
+ //
+ aNbE=aMEF.Extent();
+ for (i=1; i<=aNbE; ++i) {
+ const TopTools_ListOfShape& aLF=aMEF.FindFromIndex(i);
+ aNbF=aLF.Extent();
+ if (aNbF>1) {
+ if (aNbF==2) {
+ const TopoDS_Shape& aF1x=aLF.First();
+ const TopoDS_Shape& aF2x=aLF.Last();
+ if (aF1x.IsSame(aF2x)) {
+ continue;
+ }
+ }
+ const TopoDS_Shape& aE=aMEF.FindKey(i);
+ aLS.Append (aE);
+ }
+ }
+}
+//=======================================================================
+// function: CheckCoincidence
+// purpose:
+//=======================================================================
+ Standard_Boolean NMTTools_PaveFiller::CheckCoincidence(const BOPTools_PaveBlock& aPBNew,
+ const BOPTools_ListOfPaveBlock& aLPBFF)
+
+{
+ Standard_Boolean bRet;
+ Standard_Real aTE;
+ Standard_Integer nV11, nV12, nV21, nV22, iVV, iVE, nE2;
+ Standard_Integer iV, iCount, iCountExt;
+ // V11
+ const BOPTools_Pave& aPave11=aPBNew.Pave1();
+ nV11=aPave11.Index();
+ const TopoDS_Vertex& aV11=TopoDS::Vertex(myDS->Shape(nV11));
+
+ // V12
+ const BOPTools_Pave& aPave12=aPBNew.Pave2();
+ nV12=aPave12.Index();
+ const TopoDS_Vertex& aV12=TopoDS::Vertex(myDS->Shape(nV12));
+ //
+ iCountExt=1;
+ iCount=0;
+ BOPTools_ListIteratorOfListOfPaveBlock anIt(aLPBFF);
+
+ //
+ for (; anIt.More(); anIt.Next()) {
+ iCount=0;
+ //
+ const BOPTools_PaveBlock& aPBR=anIt.Value();
+ // V21
+ const BOPTools_Pave& aPave21=aPBR.Pave1();
+ nV21=aPave21.Index();
+ const TopoDS_Vertex& aV21=TopoDS::Vertex(myDS->Shape(nV21));
+ // V22
+ const BOPTools_Pave& aPave22=aPBR.Pave2();
+ nV22=aPave22.Index();
+ const TopoDS_Vertex& aV22=TopoDS::Vertex(myDS->Shape(nV22));
+ // E2
+ nE2=aPBR.Edge();
+ const TopoDS_Edge& aE2=TopoDS::Edge(myDS->Shape(nE2));
+ //
+ // VV
+ iV=0;
+ iVV=IntTools_Tools::ComputeVV (aV11, aV21);
+ if (!iVV) {
+ iCount++;
+ iV++;
+ if (iCount>iCountExt) {
+ break;
+ }
+ }
+ //
+ iVV=IntTools_Tools::ComputeVV (aV11, aV22);
+ if (!iVV) {
+ iCount++;
+ iV++;
+ if (iCount>iCountExt) {
+ break;
+ }
+ }
+ // VE
+ if (!iV) {
+ iVE=myContext.ComputeVE (aV11, aE2, aTE);
+ if (!iVE) {
+ iCount++;
+ if (iCount>iCountExt) {
+ break;
+ }
+ }
+ }
+ // VV
+ iV=0;
+ iVV=IntTools_Tools::ComputeVV (aV12, aV21);
+ if (!iVV) {
+ iCount++;
+ iV++;
+ if (iCount>iCountExt) {
+ break;
+ }
+ }
+ //
+ iVV=IntTools_Tools::ComputeVV (aV12, aV22);
+ if (!iVV) {
+ iCount++;
+ iV++;
+ if (iCount>iCountExt) {
+ break;
+ }
+ }
+ // VE
+ if (!iV) {
+ iVE=myContext.ComputeVE (aV12, aE2, aTE);
+ if (!iVE) {
+ iCount++;
+ if (iCount>iCountExt) {
+ break;
+ }
+ }
+ }
+ } // next aPBR
+ bRet=(Standard_Boolean)(iCount>iCountExt);
+ return bRet;
+}
+//
+// Contribution of Samtech www.samcef.com END
#include <TopExp.hxx>
#include <TColStd_IndexedMapOfInteger.hxx>
+//
+#include <IntTools_SequenceOfPntOn2Faces.hxx>
+#include <IntTools_PntOnFace.hxx>
+#include <IntTools_PntOn2Faces.hxx>
+#include <BOPTools_Tools.hxx>
+#include <TopTools_DataMapOfShapeListOfInteger.hxx>
+#include <TColStd_ListOfInteger.hxx>
+#include <TopoDS_Compound.hxx>
+#include <BRep_Builder.hxx>
+#include <BOPTools_CArray1OfVVInterference.hxx>
+#include <BOPTools_VVInterference.hxx>
+#include <TopTools_DataMapOfShapeShape.hxx>
+#include <TopTools_DataMapOfShapeListOfInteger.hxx>
+#include <TopTools_DataMapIteratorOfDataMapOfShapeListOfInteger.hxx>
+#include <TColStd_MapOfInteger.hxx>
+#include <TColStd_ListIteratorOfListOfInteger.hxx>
+#include <TopTools_DataMapOfIntegerShape.hxx>
+#include <Bnd_HArray1OfBox.hxx>
+#include <Bnd_BoundSortBox.hxx>
+#include <Bnd_Box.hxx>
+#include <BRepBndLib.hxx>
+#include <TopTools_DataMapIteratorOfDataMapOfIntegerShape.hxx>
+#include <TopTools_DataMapOfShapeInteger.hxx>
+#include <TopTools_DataMapIteratorOfDataMapOfShapeInteger.hxx>
+#include <TopTools_DataMapOfShapeInteger.hxx>
+#include <BooleanOperations_AncestorsSeqAndSuccessorsSeq.hxx>
+
+// Modified Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+static
+ void FuseVertices(const TopoDS_Shape& aCompound,
+ TopTools_DataMapOfShapeShape& aDMVV);
+// Contribution of Samtech www.samcef.com END
+
//=======================================================================
// function: MakeSplitEdges
// purpose:
for(i=1; i<=aNbF; ++i) {
nF=aMF(i);
iRankF=myDS->Rank(nF);
- const TopoDS_Shape& aF=myDS->Shape(nF);
+ const TopoDS_Shape aF=myDS->Shape(nF);//mpv
aExp.Init(aF, TopAbs_EDGE);
for(; aExp.More(); aExp.Next()) {
aE=TopoDS::Edge(aExp.Current());
}
}
}
+// Modified
+// to treat Alone Vertices between faces
+// Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+//=======================================================================
+// function: MakeAloneVertices
+// purpose:
+//=======================================================================
+ void NMTTools_PaveFiller::MakeAloneVertices()
+{
+ Standard_Integer i, aNbFFs, nF1, nF2, j, aNbPnts, nFx, aNbV;
+ Standard_Real aTolF1, aTolF2, aTolSum, aTolV;
+ TColStd_ListIteratorOfListOfInteger aIt;
+ TColStd_ListOfInteger aLI;
+ TopoDS_Vertex aV;
+ TopoDS_Compound aCompound;
+ BRep_Builder aBB;
+ TopTools_DataMapOfShapeListOfInteger aDMVFF, aDMVFF1;
+ TopTools_DataMapIteratorOfDataMapOfShapeListOfInteger aItDMVFF;
+ TopTools_DataMapOfShapeShape aDMVV;
+ TopTools_DataMapOfIntegerShape aDMIV;
+ TopTools_DataMapOfShapeInteger aDMVI;
+ TopTools_DataMapIteratorOfDataMapOfShapeInteger aItDMVI;
+ TopTools_DataMapIteratorOfDataMapOfIntegerShape aItDMIV;
+ //
+ aBB.MakeCompound(aCompound);
+ //
+ myAloneVertices.Clear();
+ //
+ BOPTools_CArray1OfSSInterference& aFFs=myIntrPool->SSInterferences();
+ //
+ // 1. Collect alone vertices from FFs
+ aNbV=0;
+ aNbFFs=aFFs.Extent();
+ for (i=1; i<=aNbFFs; ++i) {
+ BOPTools_SSInterference& aFFi=aFFs(i);
+ aFFi.Indices(nF1, nF2);
+ //
+ const TopoDS_Face aF1=TopoDS::Face(myDS->Shape(nF1));//mpv
+ const TopoDS_Face aF2=TopoDS::Face(myDS->Shape(nF2));//mpv
+ //
+ aTolF1=BRep_Tool::Tolerance(aF1);
+ aTolF2=BRep_Tool::Tolerance(aF2);
+ aTolSum=aTolF1+aTolF2;
+ //
+ aLI.Clear();
+ aLI.Append(nF1);
+ aLI.Append(nF2);
+ //
+ const IntTools_SequenceOfPntOn2Faces& aSeqAlonePnts=aFFi.AlonePnts();
+ aNbPnts=aSeqAlonePnts.Length();
+ for (j=1; j<=aNbPnts; ++j) {
+ const gp_Pnt& aP=aSeqAlonePnts(j).P1().Pnt();
+ BOPTools_Tools::MakeNewVertex(aP, aTolSum, aV);
+ aDMVFF.Bind(aV, aLI);
+ aBB.Add(aCompound, aV);
+ ++aNbV;
+ }
+ }
+ if (!aNbV) {
+ return;
+ }
+ //
+ // 2. Try to fuse alone vertices themselves;
+ FuseVertices(aCompound, aDMVV);
+ //
+ // if some are fused, replace them by new ones
+ aItDMVFF.Initialize(aDMVFF);
+ for (; aItDMVFF.More(); aItDMVFF.Next()) {
+ const TopoDS_Shape& aVx=aItDMVFF.Key();
+ const TColStd_ListOfInteger& aLIx=aItDMVFF.Value();
+ //
+ if (!aDMVV.IsBound(aVx)) {
+ aDMVFF1.Bind(aVx, aLIx);
+ }
+ else {
+ const TopoDS_Shape& aVy=aDMVV.Find(aVx);
+
+ if (aDMVFF1.IsBound(aVy)) {
+ TColStd_ListOfInteger& aLIy=aDMVFF1.ChangeFind(aVy);
+ aIt.Initialize(aLIx);
+ for(; aIt.More(); aIt.Next()) {
+ nFx=aIt.Value();
+ aLIy.Append(nFx);
+ }
+ }
+ else {
+ aDMVFF1.Bind(aVy, aLIx);
+ }
+ }
+ }
+ aDMVFF.Clear();
+ //
+ // refine lists of faces in aDMVFF1;
+ aItDMVFF.Initialize(aDMVFF1);
+ for (; aItDMVFF.More(); aItDMVFF.Next()) {
+ TColStd_MapOfInteger aMIy;
+ TColStd_ListOfInteger aLIy;
+ //
+ const TopoDS_Shape& aVx=aItDMVFF.Key();
+ TColStd_ListOfInteger& aLIx=aDMVFF1.ChangeFind(aVx);
+ aIt.Initialize(aLIx);
+ for(; aIt.More(); aIt.Next()) {
+ nFx=aIt.Value();
+ if (aMIy.Add(nFx)) {
+ aLIy.Append(nFx);
+ }
+ }
+ aLIx.Clear();
+ aLIx.Append(aLIy);
+ }
+ //==================================
+ //
+ // 3. Collect vertices from DS
+ Standard_Integer aNbS, nV, nVSD, aNbVDS, i1, i2, aNbVSD;
+ //
+ aNbS=myDS->NumberOfShapesOfTheObject();
+ // old shapes
+ for (i=1; i<=aNbS; ++i) {
+ const TopoDS_Shape& aS=myDS->Shape(i);
+ if (aS.ShapeType() != TopAbs_VERTEX){
+ continue;
+ }
+ //
+ nVSD=FindSDVertex(i);
+ nV=(nVSD) ? nVSD : i;
+ const TopoDS_Shape& aVx=myDS->Shape(nV);
+ if (!aDMVI.IsBound(aVx)) {
+ aDMVI.Bind(aVx, nV);
+ }
+ }
+ // new shapes
+ i1=myDS->NumberOfSourceShapes()+1;
+ i2=myDS->NumberOfInsertedShapes();
+ for (i=i1; i<=i2; ++i) {
+ const TopoDS_Shape aS=myDS->Shape(i);//mpv
+ if (aS.ShapeType() != TopAbs_VERTEX){
+ continue;
+ }
+ if (!aDMVI.IsBound(aS)) {
+ aDMVI.Bind(aS, i);
+ }
+ }
+ //
+ // 4. Initialize BoundSortBox on aDMVI
+ //
+ Handle(Bnd_HArray1OfBox) aHAB;
+ Bnd_BoundSortBox aBSB;
+ //
+ aNbVDS=aDMVI.Extent();
+ aHAB=new Bnd_HArray1OfBox(1, aNbVDS);
+ //
+ aItDMVI.Initialize(aDMVI);
+ for (i=1; aItDMVI.More(); aItDMVI.Next(), ++i) {
+ Bnd_Box aBox;
+ //
+ nV=aItDMVI.Value();
+ aV=TopoDS::Vertex(aItDMVI.Key());
+ aTolV=BRep_Tool::Tolerance(aV);
+ aBox.SetGap(aTolV);
+ BRepBndLib::Add(aV, aBox);
+ aHAB->SetValue(i, aBox);
+ //
+ aDMIV.Bind(i, aV);
+ }
+ aBSB.Initialize(aHAB);
+ //
+ // 5. Compare
+ aItDMVFF.Initialize(aDMVFF1);
+ for (; aItDMVFF.More(); aItDMVFF.Next()) {
+ Bnd_Box aBoxV;
+ //
+ const TColStd_ListOfInteger& aLIFF=aItDMVFF.Value();
+ aV=TopoDS::Vertex(aItDMVFF.Key());
+ //
+ aTolV=BRep_Tool::Tolerance(aV);
+ aBoxV.SetGap(aTolV);
+ BRepBndLib::Add(aV, aBoxV);
+ //
+ const TColStd_ListOfInteger& aLIVSD=aBSB.Compare(aBoxV);
+ aNbVSD=aLIVSD.Extent();
+ if (aNbVSD==0) {
+ // add new vertex in DS and update map myAloneVertices
+ BooleanOperations_AncestorsSeqAndSuccessorsSeq anASSeq;
+ //
+ myDS->InsertShapeAndAncestorsSuccessors(aV, anASSeq);
+ nV=myDS->NumberOfInsertedShapes();
+ //
+ aIt.Initialize(aLIFF);
+ for (; aIt.More(); aIt.Next()) {
+ nFx=aIt.Value();
+ if (myAloneVertices.Contains(nFx)) {
+ TColStd_IndexedMapOfInteger& aMVx=myAloneVertices.ChangeFromKey(nFx);
+ aMVx.Add(nV);
+ }
+ else {
+ TColStd_IndexedMapOfInteger aMVx;
+ aMVx.Add(nV);
+ myAloneVertices.Add(nFx, aMVx);
+ }
+ }
+ }
+ }
+}
+//=======================================================================
+// function: AloneVertices
+// purpose:
+//=======================================================================
+ const NMTTools_IndexedDataMapOfIndexedMapOfInteger& NMTTools_PaveFiller::AloneVertices()const
+{
+ return myAloneVertices;
+}
+//=======================================================================
+// function: FuseVertices
+// purpose:
+//=======================================================================
+void FuseVertices(const TopoDS_Shape& aCompound,
+ TopTools_DataMapOfShapeShape& aDMVV)
+{
+ Standard_Integer i, aNbVV, n1, n2, nX;
+ NMTDS_ShapesDataStructure tDS;
+ //
+ tDS.SetCompositeShape(aCompound);
+ tDS.Init();
+ //
+ BOPTools_InterferencePool tInterfPool(tDS);
+ NMTTools_PaveFiller tPaveFiller(tInterfPool);
+ //
+ tPaveFiller.Init();
+ //
+ tPaveFiller.PerformVV();
+ tPaveFiller.PerformNewVertices();
+ //
+ const BOPTools_CArray1OfVVInterference& aVVt=tInterfPool.VVInterfs();
+ //
+ aNbVV=aVVt.Extent();
+ for (i=1; i<=aNbVV; ++i) {
+ const BOPTools_VVInterference& aVV=aVVt(i);
+ aVV.Indices(n1, n2);
+ nX=aVV.NewShape();
+ if (nX) {
+ const TopoDS_Shape& aV1=tDS.Shape(n1);
+ const TopoDS_Shape& aV2=tDS.Shape(n2);
+ const TopoDS_Shape& aVx=tDS.Shape(nX);
+ aDMVV.Bind(aV1, aVx);
+ aDMVV.Bind(aV2, aVx);
+ }
+ }
+}
+// Contribution of Samtech www.samcef.com END
#include <NMTTools_PaveFiller.ixx>
+#include <TColStd_MapOfInteger.hxx>
#include <TColStd_ListOfInteger.hxx>
#include <TColStd_ListIteratorOfListOfInteger.hxx>
#include <NMTTools_CommonBlock.hxx>
#include <NMTTools_CommonBlockAPI.hxx>
+
+// Modified to add new method Thu Sep 14 14:35:18 2006
+// Contribution of Samtech www.samcef.com BEGIN
+//=======================================================================
+// function: SharedEdges
+// purpose:
+//=======================================================================
+ void NMTTools_PaveFiller::SharedEdges(const Standard_Integer nF1,
+ const Standard_Integer nF2,
+ TColStd_ListOfInteger& aLNE,
+ TopTools_ListOfShape& aLSE)
+{
+ Standard_Integer nE1, nE2;
+ TColStd_MapOfInteger aM1;
+ //
+ BooleanOperations_ShapesDataStructure *pDS=myDS;
+ BooleanOperations_OnceExplorer aExp(*pDS);
+ //
+ aExp.Init(nF1, TopAbs_EDGE);
+ for (; aExp.More(); aExp.Next()) {
+ nE1=aExp.Current();
+ aM1.Add(nE1);
+ }
+
+ aExp.Init(nF2, TopAbs_EDGE);
+ for (; aExp.More(); aExp.Next()) {
+ nE2=aExp.Current();
+ if (aM1.Contains(nE2)) {
+ aLNE.Append(nE2);
+ const TopoDS_Shape& aE2=myDS->Shape(nE2);
+ aLSE.Append(aE2);
+ }
+ }
+}
+// Contribution of Samtech www.samcef.com END
+//
+//=======================================================================
+// function: RealPaveBlock
+// purpose:
+//=======================================================================
+ const BOPTools_PaveBlock& NMTTools_PaveFiller::RealPaveBlock(const BOPTools_PaveBlock& aPB,
+ TColStd_ListOfInteger& aLB)
+{
+ Standard_Integer nE, nSpx;
+ BOPTools_ListIteratorOfListOfPaveBlock aItPBx;
+ //
+ aLB.Clear();
+ nE=aPB.OriginalEdge();
+ const NMTTools_ListOfCommonBlock& aLCBE=myCommonBlockPool(myDS->RefEdge(nE));
+ NMTTools_CommonBlockAPI aCBAPI(aLCBE);
+ if (aCBAPI.IsCommonBlock(aPB)) {
+ NMTTools_CommonBlock& aCB=aCBAPI.CommonBlock(aPB);
+ //
+ const BOPTools_ListOfPaveBlock& aLPBx=aCB.PaveBlocks();
+ aItPBx.Initialize(aLPBx);
+ for (; aItPBx.More(); aItPBx.Next()) {
+ const BOPTools_PaveBlock& aPBx=aItPBx.Value();
+ nSpx=aPBx.Edge();
+ aLB.Append(nSpx);
+ }
+ //
+ const BOPTools_PaveBlock& aPBx=aCB.PaveBlock1();
+ return aPBx;
+ }
+ return aPB;
+}
+//
//=======================================================================
// function: RealPaveBlock
// purpose:
-// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
-//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
+-- Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+-- CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+--
+-- This library is free software; you can redistribute it and/or
+-- modify it under the terms of the GNU Lesser General Public
+-- License as published by the Free Software Foundation; either
+-- version 2.1 of the License.
+--
+-- This library is distributed in the hope that it will be useful
+-- but WITHOUT ANY WARRANTY; without even the implied warranty of
+-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+-- Lesser General Public License for more details.
+--
+-- You should have received a copy of the GNU Lesser General Public
+-- License along with this library; if not, write to the Free Software
+-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+--
-- See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+--
+
-- File: NMTTools_Tools.cdl
-- Created: Mon Dec 8 10:32:34 2003
-- Author: Peter KURNEV
-- <pkv@irinox>
----Copyright: Matra Datavision 2003
class Tools from NMTTools
#include <BRepLib.hxx>
#include <BOPTools_Tools3D.hxx>
#include <TopExp_Explorer.hxx>
+//
+#include <TopTools_MapOfShape.hxx>
+#include <TopTools_MapIteratorOfMapOfShape.hxx>
static
void ProcessBlock(const Standard_Integer iV,
IntTools_Context& aCtx)
{
Standard_Boolean bFlag;
- Standard_Integer i, aNbE1, aNbE2;
-
- TopTools_IndexedMapOfShape aME1, aME2;
- TopoDS_Edge aEF1, aEF2;
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
+ Standard_Integer aNbE1, aNbE2;
+ Standard_Real aTolF1, aTolF2, aTol;
+ gp_Pnt2d aP2D;
+ gp_Pnt aP;
TopoDS_Face aF1, aF2;
+ TopExp_Explorer aExp;
+ TopTools_MapOfShape aME1, aME2;
+ TopTools_MapIteratorOfMapOfShape aIt;
+ //
+ bFlag=Standard_False;
+ // Contribution of Samtech www.samcef.com END
//
aF1=aF1x;
aF1.Orientation(TopAbs_FORWARD);
aF2=aF2y;
aF2.Orientation(TopAbs_FORWARD);
//
- TopExp::MapShapes(aF1, TopAbs_EDGE, aME1);
- TopExp::MapShapes(aF2, TopAbs_EDGE, aME2);
+ // Modified Thu Sep 14 14:35:18 2006
+ // Contribution of Samtech www.samcef.com BEGIN
//
- bFlag=Standard_False;
+ // 1
+ aExp.Init(aF1, TopAbs_EDGE);
+ for (; aExp.More(); aExp.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(aExp.Current());
+ if (!BRep_Tool::Degenerated(aE)) {
+ aME1.Add(aE);
+ }
+ }
+ //
+ aExp.Init(aF2, TopAbs_EDGE);
+ for (; aExp.More(); aExp.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(aExp.Current());
+ if (!BRep_Tool::Degenerated(aE)) {
+ if (!aME1.Contains(aE)) {
+ return bFlag;
+ }
+ aME2.Add(aE);
+ }
+ }
+ //
+ // Contribution of Samtech www.samcef.com END
//
aNbE1=aME1.Extent();
aNbE2=aME2.Extent();
return bFlag;
}
//
- for (i=1; i<=aNbE1; ++i) {
- const TopoDS_Edge& aE1=TopoDS::Edge(aME1(i));
- if (BRep_Tool::Degenerated(aE1)) {
- // not try to compare deg edges because it
- // can not have same TShape on different faces at all
- continue;
- }
- if (!aME2.Contains(aE1)) {
- return bFlag;
- }
- }
- //
- Standard_Real aTolF1, aTolF2, aTol;
- gp_Pnt2d aP2D;
- gp_Pnt aP;
- TopExp_Explorer anExp;
- //
- aTolF1=BRep_Tool::Tolerance(aF1);
- aTolF2=BRep_Tool::Tolerance(aF2);
- aTol=aTolF1+aTolF2;
- //
- anExp.Init(aF1, TopAbs_EDGE);
- for (; anExp.More(); anExp.Next()) {
- const TopoDS_Edge& aE1=TopoDS::Edge(anExp.Current());
- if (!BRep_Tool::Degenerated(aE1)) {
- BOPTools_Tools3D::PointNearEdge(aE1, aF1, aP2D, aP);
- bFlag=aCtx.IsValidPointForFace(aP, aF2, aTol);
- break;
- }
- }
- return bFlag;
- /*
- //
- Standard_Real aU1, aU2, aV1, aV2;
- Standard_Real dU, dV, aU, aV;
- Standard_Integer aNbP=5, aNbP1, j;
- gp_Pnt2d aP2D;
- gp_Pnt aP;
- //
+ // 2
aTolF1=BRep_Tool::Tolerance(aF1);
aTolF2=BRep_Tool::Tolerance(aF2);
aTol=aTolF1+aTolF2;
//
- BRepTools::UVBounds(aF1, aU1, aU2, aV1, aV2);
- Handle(Geom_Surface) aS1=BRep_Tool::Surface(aF1);
- //
- aNbP1=aNbP+1;
- dU=(aU2-aU1)/aNbP1;
- dV=(aV2-aV1)/aNbP1;
- //
- for (i=1; i<=aNbP; ++i) {
- aU=aU1+i*dU;
- for (j=1; j<=aNbP; ++j) {
- aV=aV1+j*dV;
- aP2D.SetCoord(aU, aV);
- //
- if(aCtx.IsPointInFace(aF1, aP2D)) {
- aP=aS1->Value(aU, aV);
- bFlag=aCtx.IsValidPointForFace(aP, aF2, aTol);
- if (!bFlag) {
- return bFlag;
- }
- }
- }
+ aIt.Initialize(aME1);
+ for (; aIt.More(); aIt.Next()) {
+ const TopoDS_Edge& aE=TopoDS::Edge(aIt.Key());
+ BOPTools_Tools3D::PointNearEdge(aE, aF1, aP2D, aP);
+ bFlag=aCtx.IsValidPointForFace(aP, aF2, aTol);
+ break;
}
- */
//
return bFlag;
}
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
#include <Standard_Macro.hxx>
#endif
+
class NMTTools_Tools {
public:
}
// Methods PUBLIC
//
+
+
Standard_EXPORT static void MakeNewVertex(const TopTools_ListOfShape& aLV,TopoDS_Vertex& aNewVertex) ;
+
+
Standard_EXPORT static void FindChains(const BOPTools_CArray1OfVVInterference& aVVs,BOPTColStd_IndexedDataMapOfIntegerIndexedMapOfInteger& aMCX) ;
+
+
Standard_EXPORT static void FindChains(const BOPTools_CArray1OfSSInterference& aVVs,BOPTColStd_IndexedDataMapOfIntegerIndexedMapOfInteger& aMCX) ;
+
+
Standard_EXPORT static void FindChains(const BOPTColStd_IndexedDataMapOfIntegerIndexedMapOfInteger& aMCV,BOPTColStd_IndexedDataMapOfIntegerIndexedMapOfInteger& aMCX) ;
+
+
Standard_EXPORT static Standard_Boolean IsSplitInOnFace(const TopoDS_Edge& aE,const TopoDS_Face& aF,IntTools_Context& aCtx) ;
+
+
Standard_EXPORT static Standard_Boolean AreFacesSameDomain(const TopoDS_Face& aF1,const TopoDS_Face& aF2,IntTools_Context& aCtx) ;
+
+
Standard_EXPORT static void FindChains(const NMTTools_ListOfCoupleOfShape& aLCS,NMTTools_IndexedDataMapOfShapeIndexedMapOfShape& aM) ;
+
+
Standard_EXPORT static void FindChains(const NMTTools_IndexedDataMapOfShapeIndexedMapOfShape& aM1,NMTTools_IndexedDataMapOfShapeIndexedMapOfShape& aM2) ;
+
+
Standard_EXPORT static void MakePCurve(const TopoDS_Edge& aE,const TopoDS_Face& aF,const Handle(Geom2d_Curve)& aC2D,const Standard_Real aTolR2D) ;
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
// Copyright (C) 2005 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
-//
+//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
+// License as published by the Free Software Foundation; either
// version 2.1 of the License.
-//
-// This library is distributed in the hope that it will be useful
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+//
+// This library is distributed in the hope that it will be useful
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
-//
+
#ifndef _TopTools_ListOfShape_HeaderFile
#include <TopTools_ListOfShape.hxx>
#endif