Salome HOME
Task #3016: 3.2 To add a mode «through all» for features RevolutionCut and RevolutionFuse
[modules/shaper.git] / src / FeaturesPlugin / FeaturesPlugin_Symmetry.h
index edb152dd117499dc8af9c0bf6746c5efb2379327..fb4b47da8a49e6fb11dabf1decabbad37500fdea 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2014-2017  CEA/DEN, EDF R&D
+// Copyright (C) 2014-2019  CEA/DEN, EDF R&D
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 //
 // You should have received a copy of the GNU Lesser General Public
 // License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
 //
-// See http://www.salome-platform.org/ or
-// email : webmaster.salome@opencascade.com<mailto:webmaster.salome@opencascade.com>
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 //
 
 #ifndef FEATURESPLUGIN_SYMMETRY_H_
@@ -26,6 +25,7 @@
 #include <ModelAPI_Feature.h>
 
 #include <GeomAlgoAPI_Symmetry.h>
+#include <GeomAlgoAPI_MakeShapeList.h>
 
 class GeomAPI_Trsf;
 
@@ -39,7 +39,7 @@ class FeaturesPlugin_Symmetry : public ModelAPI_Feature
   /// Symmetry kind.
   inline static const std::string& ID()
   {
-    static const std::string MY_SYMMETRY_ID("MirrorCopy");
+    static const std::string MY_SYMMETRY_ID("Symmetry");
     return MY_SYMMETRY_ID;
   }
 
@@ -99,6 +99,13 @@ class FeaturesPlugin_Symmetry : public ModelAPI_Feature
     return MY_PLANE_OBJECT_ID;
   }
 
+  /// Attribute name of keeping original shape.
+  inline static const std::string& KEEP_ORIGINAL_RESULT()
+  {
+    static const std::string MY_KEEP_ORIGINAL_RESULT_ID("keep_original");
+    return MY_KEEP_ORIGINAL_RESULT_ID;
+  }
+
   /// \return the kind of a feature.
   FEATURESPLUGIN_EXPORT virtual const std::string& getKind()
   {
@@ -129,13 +136,8 @@ private:
   /// Perform symmetry with respect to a plane.
   void performSymmetryByPlane();
 
-  /// Perform the naming
-  void loadNamingDS(GeomAlgoAPI_Symmetry& theSymmetryAlgo,
-                    std::shared_ptr<ModelAPI_ResultBody> theResultBody,
-                    std::shared_ptr<GeomAPI_Shape> theBaseShape);
-
   /// Create new result on given shapes and the index of result
-  void buildResult(GeomAlgoAPI_Symmetry& theSymmetryAlgo,
+  void buildResult(std::shared_ptr<GeomAlgoAPI_Symmetry>& theSymmetryAlgo,
                    std::shared_ptr<GeomAPI_Shape> theBaseShape,
                    int theResultIndex);