]> SALOME platform Git repositories - modules/shaper.git/blobdiff - src/SketchSolver/SketchSolver_Constraint.h
Salome HOME
SketchSolver library refactoring
[modules/shaper.git] / src / SketchSolver / SketchSolver_Constraint.h
index b7925d66c9c400190818c55426f0709d29d8efcf..6a57f6b2182def8f4382a7d02a3a602f509bbc3f 100644 (file)
@@ -76,6 +76,11 @@ protected:
   /// \param[out] theAttributes list of attributes to be filled
   virtual void getAttributes(double& theValue, std::vector<Slvs_hEntity>& theAttributes);
 
+  /// \brief This method is used in derived objects to check consistence of constraint.
+  ///        E.g. the distance between line and point may be signed.
+  virtual void adjustConstraint()
+  {}
+
   /// \brief Create or change SlveSpace entity according to the given attribute
   /// \param[in]  theAttribute  reference to the entity to be changed
   /// \param[out] theType       type of created entity
@@ -109,22 +114,6 @@ typedef std::shared_ptr<SketchSolver_Constraint> SolverConstraintPtr;
 
 
 
-/** \class   SketchSolver_ConstraintDistance
- *  \ingroup Plugins
- *  \brief   Convert distance constraint to SolveSpace structure
- */
-class SketchSolver_ConstraintDistance : public SketchSolver_Constraint
-{
-public:
-  SketchSolver_ConstraintDistance(ConstraintPtr theConstraint) :
-      SketchSolver_Constraint(theConstraint)
-  {}
-
-  virtual int getType() const
-  { return SLVS_C_PT_PT_DISTANCE; }
-};
-
-
 /** \class   SketchSolver_ConstraintParallel
  *  \ingroup Plugins
  *  \brief   Convert Parallel constraint to SolveSpace structure