]> SALOME platform Git repositories - modules/shaper.git/blob - src/SketchPlugin/SketchPlugin_Validators.h
Salome HOME
8a5a82bb04a3f30f5bd76b90361a60548f778c28
[modules/shaper.git] / src / SketchPlugin / SketchPlugin_Validators.h
1 // File:        SketchPlugin_Validators.h
2 // Created:     01 Aug 2014
3 // Author:      Vitaly SMETANNIKOV
4
5 #ifndef SketchPlugin_Validators_H
6 #define SketchPlugin_Validators_H
7
8 #include "SketchPlugin.h"
9 #include <ModelAPI_RefAttrValidator.h>
10
11 class SketchPlugin_DistanceAttrValidator : public ModelAPI_RefAttrValidator
12 {
13  public:
14   //! returns true if attribute is valid
15   //! \param theAttribute the checked attribute
16   //! \param theArguments arguments of the attribute
17   virtual bool isValid(
18     const AttributePtr& theAttribute, const std::list<std::string>& theArguments) const;
19   //! Returns true if object is good for the feature attribute
20   virtual bool isValid(const FeaturePtr& theFeature, const std::list<std::string>& theArguments,
21                        const ObjectPtr& theObject) const;
22
23 };
24
25 /**
26  * It must be bigger than 1.e-5
27  */
28 class SketchPlugin_RadiusValidator : public ModelAPI_AttributeValidator
29 {
30  public:
31   //! returns true if attribute is valid
32   //! \param theAttribute the checked attribute
33   //! \param theArguments arguments of the attribute
34   virtual bool isValid(
35     const AttributePtr& theAttribute, const std::list<std::string>& theArguments) const;
36
37 };
38
39 #endif