- /// \brief Change mapping attribute of a feature and the entity applicable for corresponding solver.
- /// \param theAttribute [in] original attribute
- /// \param theSolverEntity [in] solver's entity, created outside
- SKETCHSOLVER_EXPORT
- void addEntity(AttributePtr theAttribute,
- EntityWrapperPtr theSolverEntity);
-
-//// /// \brief Change mapping scalar attribute and the parameter applicable for corresponding solver.
-//// /// \param theValue [in] original attribute
-//// /// \param theSolverParam [in] solver's parameter, created outside
-//// SKETCHSOLVER_EXPORT
-//// void addParameter(AttributeDoublePtr theValue,
-//// ParameterWrapperPtr theSolverParam);
-
- /// \brief Update constraint's data
- /// \return \c true if any value is updated
- virtual bool update(ConstraintWrapperPtr& theConstraint) = 0;
- /// \brief Update entity's data
- /// \return \c true if any value is updated
- virtual bool update(EntityWrapperPtr& theEntity) = 0;
- /// \brief Update parameter's data
- /// \return \c true if the value of parameter is updated
- virtual bool update(ParameterWrapperPtr& theParameter) = 0;
-
- /// \brief Remove constraint
- /// \return \c true if the constraint and all its parameters are removed successfully
- virtual bool remove(ConstraintWrapperPtr theConstraint) = 0;
- /// \brief Remove entity
- /// \return \c true if the entity and all its parameters are removed successfully
- virtual bool remove(EntityWrapperPtr theEntity) = 0;
- /// \brief Remove parameter
- /// \return \c true if the parameter has been removed
- virtual bool remove(ParameterWrapperPtr theParameter) = 0;
-
- /// \brief Update the group for the given entity, its sub-entities and parameters
- virtual void changeGroup(EntityWrapperPtr theEntity, const GroupID& theGroup) = 0;
- /// \brief Update the group for the given parameter
- virtual void changeGroup(ParameterWrapperPtr theParam, const GroupID& theGroup) = 0;
+ /// \brief Subscribe for updates of features
+ /// \param theSubscriber [in] object which wants to revceive notifications
+ /// \param theGroup [in] group of updates features to be send
+ void subscribeUpdates(SketchSolver_Constraint* theSubscriber, const std::string& theGroup) const;
+ /// \brief Unsubscribe for updates of features
+ /// \param theSubscriber [in] object which does not want to revceive notifications anymore
+ void unsubscribeUpdates(SketchSolver_Constraint* theSubscriber) const;