Salome HOME
Merge branch 'BR_H2018_3' into BR_2018_V8_5
[modules/hydro.git] / src / HYDROData / HYDROData_SplitToZonesTool.h
index eaa58208496cd17581c277b36cf2792c8fcd9427..b4e092eb87402a0704d875eba352d34f29ab248c 100644 (file)
 #include <TopoDS_Face.hxx>
 #include <TopTools_ShapeMapHasher.hxx>
 #include <NCollection_IndexedMap.hxx>
-#include <NCollection_IndexedDataMap.hxx>
+#include <TopTools_IndexedDataMapOfShapeShape.hxx>
+#include <TopTools_IndexedDataMapOfShapeListOfShape.hxx>
 #include <TopTools_ListOfShape.hxx>
 #include <QStringList>
+#include <NCollection_DataMap.hxx>
 
-class Handle(HYDROData_PolylineXY);
+class HYDROData_PolylineXY;
 
 /**
  * \class HYDROData_SplitToZonesTool
@@ -50,7 +52,8 @@ public:
     {
       Data_None,
       Data_Zone,
-      Data_Edge
+      Data_Edge,
+      Data_IntEdge
     };
 
     TopoDS_Shape    Shape;
@@ -87,10 +90,27 @@ public:
 
   static SplitDataList       Split( const HYDROData_SequenceOfObjects&  theObjectList,
                                     const HYDROData_SequenceOfObjects&  theGroupsList,
-                                    const Handle(HYDROData_PolylineXY)& thePolyline );
+                                    const Handle(HYDROData_PolylineXY)& thePolyline,
+                                    const HYDROData_SequenceOfObjects& InterPolys );
 
   static SplitDataList       Split( const HYDROData_SequenceOfObjects&  theObjectList );
 
+  static void AddInternalEdges(HYDROData_DataMapOfShapeListOfShape& DM,
+                               const HYDROData_SequenceOfObjects& thePolylines,
+                               NCollection_DataMap<TopoDS_Shape, Handle(HYDROData_PolylineXY), TopTools_ShapeMapHasher>* OutNE);
+
+  static void CutFaceByEdges(const TopoDS_Face& in, 
+                             TopTools_ListOfShape& out, 
+                             const HYDROData_SequenceOfObjects& thePolylines,
+                             NCollection_DataMap<TopoDS_Shape, Handle(HYDROData_PolylineXY), TopTools_ShapeMapHasher>* OutNE,
+                             TopTools_IndexedDataMapOfShapeListOfShape* OutOrSh2M);
+
+  static int CutByEdges(const TopoDS_Shape& InSh, const TopTools_ListOfShape& InW,
+                        TopTools_ListOfShape& outShs,
+                        bool OutShapeAsRes,
+                        TopTools_IndexedDataMapOfShapeShape* OutNE2OE,
+                        TopTools_IndexedDataMapOfShapeListOfShape* OInSH2MSH);
+
   static void SetFileNames(const QString& theNameBefore, const QString& theNameAfter);
 
 private:
@@ -98,7 +118,7 @@ private:
   /**
    * Split input faces.
    */
-  static Standard_Integer SplitFaces(const TopoDS_Compound& theComp, HYDROData_Transform& theTool);
+  static bool SplitFaces(const TopoDS_Compound& theComp, HYDROData_Transform& theTool);
 };
 
 #ifdef WIN32