- /// \brief Verifies the constraint is complex, i.e. it needs another constraints to be created before
- static bool isComplexConstraint(FeaturePtr theConstraint);
+ /// \brief Check the group has conflicting constraints
+ inline bool isFailed() const
+ {
+ return !myConflictingConstraints.empty();
+ }
/** \brief Adds or updates a constraint in the group
* \param[in] theConstraint constraint to be changed
/** \brief Adds or updates a constraint in the group
* \param[in] theConstraint constraint to be changed
/** \brief Updates the data corresponding the specified feature moved in GUI.
* Additional Fixed constraints are created.
* \param[in] theFeature the feature to be updated
/** \brief Updates the data corresponding the specified feature moved in GUI.
* Additional Fixed constraints are created.
* \param[in] theFeature the feature to be updated
/** \brief Verifies the feature attributes are used in this group
* \param[in] theFeature constraint or any other object for verification of interaction
/** \brief Verifies the feature attributes are used in this group
* \param[in] theFeature constraint or any other object for verification of interaction
- * \return \c true if workplane updated successfully, \c false if workplane parameters are not consistent
+ * \return \c true if workplane updated successfully,
+ * \c false if workplane parameters are not consistent
- /** \brief Cut from the group several subgroups, which are not connected to the current one by any constraint
+ /** \brief Cut from the group several subgroups, which are not connected to
+ * the current one by any constraint
* \param[out] theCuts enlarge this list by newly created groups
*/
void splitGroup(std::list<SketchSolver_Group*>& theCuts);
* \param[out] theCuts enlarge this list by newly created groups
*/
void splitGroup(std::list<SketchSolver_Group*>& theCuts);
- /// \brief Update just changed constraints
- void updateConstraints();
+ /// \brief Notify all interested constraints that coincidence appears or removed
+ /// \param[in] theCoincidence coincidence constraint
+ void notifyCoincidenceChanged(SolverConstraintPtr theCoincidence);
CompositeFeaturePtr mySketch; ///< Sketch is equivalent to workplane
ConstraintConstraintMap myConstraints; ///< List of constraints
std::set<SolverConstraintPtr> myTempConstraints; ///< List of temporary constraints
CompositeFeaturePtr mySketch; ///< Sketch is equivalent to workplane
ConstraintConstraintMap myConstraints; ///< List of constraints
std::set<SolverConstraintPtr> myTempConstraints; ///< List of temporary constraints
- std::map<AttributePtr, SolverConstraintPtr> myParametricConstraints; ///< List of parametric constraints
- std::set<ConstraintPtr> myChangedConstraints; ///< List of just updated constraints
+
+ /// List of parametric constraints
+ std::map<AttributePtr, SolverConstraintPtr> myParametricConstraints;
StoragePtr myStorage; ///< Container for the set of SolveSpace constraints and their entities
SolverPtr mySketchSolver; ///< Solver for set of equations obtained by constraints
StoragePtr myStorage; ///< Container for the set of SolveSpace constraints and their entities
SolverPtr mySketchSolver; ///< Solver for set of equations obtained by constraints
- bool myPrevSolved; ///< Indicates that previous solving was done correctly
+ /// Result of previous solution of the set of constraints
+ SketchSolver_SolveStatus myPrevResult;
+ std::set<ObjectPtr> myConflictingConstraints; ///< List of conflicting constraints