Salome HOME
updated copyright message
[modules/shaper.git] / src / SketchSolver / SketchSolver_Storage.h
index f4f6e7254cd7a504a1f11a8679dca39809ef6707..2819132579238eddfe5ff85874f323a4d9be0e03 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2014-2017  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
 //
 // You should have received a copy of the GNU Lesser General Public
 // 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 SketchSolver_Storage_H_
@@ -57,10 +56,10 @@ public:
   virtual void addConstraint(ConstraintPtr        theConstraint,
                              ConstraintWrapperPtr theSolverConstraint);
 
-  /// \brief Add list of temporary constraints which will be destroyed
+  /// \brief Add a movement constraint which will be destroyed
   ///        after the next solving of the set of constraints.
   /// \param theSolverConstraint [in]  solver's constraint
-  virtual void addTemporaryConstraint(const ConstraintWrapperPtr& theSolverConstraint) = 0;
+  virtual void addMovementConstraint(const ConstraintWrapperPtr& theSolverConstraint) = 0;
 
   /// \brief Change mapping feature from SketchPlugin and
   ///        the entity applicable for corresponding solver.
@@ -129,6 +128,14 @@ public:
   /// \brief Return list of conflicting constraints
   std::set<ObjectPtr> getConflictingConstraints(SolverPtr theSolver) const;
 
+  /// \brief Return list of features which are not fully constrained
+  virtual void getUnderconstrainedGeometry(std::set<ObjectPtr>& theFeatures) const = 0;
+
+  /// \brief Verify, the sketch contains degenerated geometry
+  ///        after resolving the set of constraints
+  /// \return STATUS_OK if the geometry is valid, STATUS_DEGENERATED otherwise.
+  virtual PlaneGCSSolver_Solver::SolveStatus checkDegeneratedGeometry() const = 0;
+
   /// \brief Update SketchPlugin features after resolving constraints
   virtual void refresh() const = 0;
 
@@ -146,6 +153,11 @@ public:
   /// \brief Notify all subscribers about update of the feature
   void notify(const FeaturePtr& theFeature) const;
 
+  /// \brief Make parametrization of arcs consistent.
+  ///        Forward arcs should have the last parameter greater than the first parameter.
+  ///        Reversed arcs should have the last parameter lesser than the first parameter.
+  virtual void adjustParametrizationOfArcs() = 0;
+
 protected:
   /// \brief Convert result to feature or attribute if theResult is linked to center of circle/arc
   static void resultToFeatureOrAttribute(const ObjectPtr& theResult,