Salome HOME
Merge branch 'Pre_2.8.0_development'
[modules/shaper.git] / src / SketchPlugin / SketchPlugin_Validators.h
index 398fd16baf5c29f8f1b2f9368b92fc5eca8b52a7..ccfe6432824aaef8313f9d54c8e26a5ef0e1ddea 100644 (file)
@@ -427,4 +427,24 @@ class SketchPlugin_ArcEndPointIntersectionValidator: public ModelAPI_AttributeVa
                        Events_InfoMessage& theError) const;
 };
 
+/**\class SketchPlugin_HasNoConstraint
+ * \ingroup Validators
+ * \brief Validator for checking whether the feature has constraint.
+ *
+ * Checks that feature of the attribute does not have constraint with some kinds.
+ * The kinds of constraints should be described in parameters of the validator
+ * Validator processes the ModelAPI_AttributeRefAttr attribute kind
+ */
+class SketchPlugin_HasNoConstraint: public ModelAPI_AttributeValidator
+{
+ public:
+  //! returns true if attribute is valid
+  //! \param theAttribute the checked attribute
+  //! \param theArguments arguments of the attribute
+  //! \param theError error message
+  virtual bool isValid(const AttributePtr& theAttribute,
+                       const std::list<std::string>& theArguments,
+                       Events_InfoMessage& theError) const;
+};
+
 #endif