Salome HOME
updated copyright message
[modules/shaper.git] / src / GeomAPI / GeomAPI_ShapeHierarchy.h
index b1492fe8cb002c60900000e3e84aabaec55106a6..9977e7ee948c13d6d36b886016214c4c03d35a61 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2014-2020  CEA/DEN, EDF R&D
+// Copyright (C) 2014-2023  CEA, EDF
 //
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
@@ -60,6 +60,9 @@ public:
   /// Return parent shape for the given, or empty if it is a high-level shape.
   /// By default, the parent and all its subshapes are marked as processed for further skip.
   GEOMAPI_EXPORT GeomShapePtr parent(const GeomShapePtr& theShape, bool theMarkProcessed = true);
+  /// Get root shape for the specified sub-shape.
+  /// By default, the parent and all its subshapes are marked as processed for further skip.
+  GEOMAPI_EXPORT GeomShapePtr root(const GeomShapePtr& theShape, bool theMarkProcessed = true);
 
   /// Mark the shape as already processed
   GEOMAPI_EXPORT void markProcessed(const GeomShapePtr& theShape);
@@ -85,6 +88,8 @@ public:
 
   /// Return list of objects
   const ListOfShape& objects() const { return myObjects; }
+  /// Return list of low-level objects for the parent shape
+  GEOMAPI_EXPORT const ListOfShape& objects(GeomShapePtr theParent) const;
   /// Separate objects of the given range of types and all other objects
   GEOMAPI_EXPORT void objectsByType(ListOfShape& theShapesByType, ListOfShape& theOtherShapes,
       const GeomAPI_Shape::ShapeType theMinType = GeomAPI_Shape::COMPOUND,