1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D -->
3 // File: Model_ResultValidators.h
4 // Created: 27 Feb 2015
5 // Author: Natalia ERMOLAEVA
7 #ifndef SketchPlugin_ExternalValidator_H
8 #define SketchPlugin_ExternalValidator_H
10 #include <SketchPlugin.h>
11 #include <ModelAPI_AttributeValidator.h>
13 /**\class SketchPlugin_ExternalValidator
15 * \brief Validator for the points selection
17 * Allows to select points only.
19 class SketchPlugin_ExternalValidator : public ModelAPI_AttributeValidator
22 /// returns true if the feature of attribute do not contain external features in the given attribute and
23 /// among attributes listed in the arguments
24 /// \param theAttribute an attribute to check
25 /// \param theArguments a filter parameters
26 /// \param theError error message
27 SKETCHPLUGIN_EXPORT virtual bool isValid(const AttributePtr& theAttribute,
28 const std::list<std::string>& theArguments,
29 Events_InfoMessage& theError) const;
32 /// returns true if the feature of the attribute is external
33 /// \param theAttribute an attribute to check
34 bool isExternalAttribute(const AttributePtr& theAttribute) const;