Salome HOME
Adding test for bos #41748 [CEA] Issue in interpolation edition
[modules/shaper.git] / src / ModelHighAPI / ModelHighAPI_Selection.h
index 52b9b40507d353641166c721ad8a7b333ce5d544..dc27c474fce58e15dbb22f2446401bc859c29afe 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2014-2019  CEA/DEN, EDF R&D
+// Copyright (C) 2014-2024  CEA, EDF
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
@@ -32,13 +32,14 @@ class GeomAPI_Pnt;
 class GeomAPI_Shape;
 class ModelAPI_AttributeSelection;
 class ModelAPI_AttributeSelectionList;
+class ModelAPI_FiltersFeature;
 class ModelAPI_Result;
 //--------------------------------------------------------------------------------------
 typedef std::pair<std::shared_ptr<ModelAPI_Result>, std::shared_ptr<GeomAPI_Shape> >
   ResultSubShapePair;
-typedef std::pair<std::string, std::string> TypeSubShapeNamePair;
+typedef std::pair<std::string, std::wstring> TypeSubShapeNamePair;
 typedef std::pair<std::string, std::shared_ptr<GeomAPI_Pnt> > TypeInnerPointPair;
-typedef std::pair<std::string, std::pair<std::string, int> > TypeWeakNamingPair;
+typedef std::pair<std::string, std::pair<std::wstring, int> > TypeWeakNamingPair;
 //--------------------------------------------------------------------------------------
 /**\class ModelHighAPI_Selection
  * \ingroup CPPHighAPI
@@ -52,7 +53,8 @@ public:
     VT_ResultSubShapePair,
     VT_TypeSubShapeNamePair,
     VT_TypeInnerPointPair,
-    VT_WeakNamingPair
+    VT_WeakNamingPair,
+    VT_Filtering
   };
 
 public:
@@ -68,7 +70,7 @@ public:
   /// Constructor for sub-shape by the textual Name
   MODELHIGHAPI_EXPORT
   ModelHighAPI_Selection(const std::string& theType,
-                         const std::string& theSubShapeName);
+                         const std::wstring& theSubShapeName);
 
   /// Constructor for sub-shape by inner point coordinates
   MODELHIGHAPI_EXPORT
@@ -84,7 +86,7 @@ public:
   /// Constructor for sub-shape by weak naming identifier
   MODELHIGHAPI_EXPORT
     ModelHighAPI_Selection(const std::string& theType,
-      const std::string& theContextName, const int theIndex);
+      const std::wstring& theContextName, const int theIndex);
 
   /// Destructor
   MODELHIGHAPI_EXPORT
@@ -124,15 +126,15 @@ public:
 
   /// Shortcut for result()->data()->setName()
   MODELHIGHAPI_EXPORT
-  void setName(const std::string& theName);
+  void setName(const std::wstring& theName);
 
   /// Shortcut for result()->data()->name()
   MODELHIGHAPI_EXPORT
-  std::string name() const;
+  std::wstring name() const;
 
   /// Change result's color
   MODELHIGHAPI_EXPORT
-  void setColor(int theRed, int theGreen, int theBlue);
+  void setColor(int theRed = 0, int theGreen = 0, int theBlue = 0, bool random = false);
 
   /// Change result's deflection
   MODELHIGHAPI_EXPORT
@@ -150,12 +152,13 @@ public:
   MODELHIGHAPI_EXPORT
   ModelHighAPI_Selection subResult(int theIndex) const;
 
-private:
+protected:
   VariantType myVariantType;
   ResultSubShapePair myResultSubShapePair;
   TypeSubShapeNamePair myTypeSubShapeNamePair;
   TypeInnerPointPair myTypeInnerPointPair;
   TypeWeakNamingPair myWeakNamingPair;
+  std::shared_ptr<ModelAPI_FiltersFeature> myFilterFeature;
 };
 
 //--------------------------------------------------------------------------------------