Salome HOME
Merge branch 'master' of newgeom:newgeom
[modules/shaper.git] / src / SketchPlugin / SketchPlugin_ConstraintCoincidence.h
1 // File:    SketchPlugin_ConstraintCoincidence.h
2 // Created: 08 May 2014
3 // Author:  Artem ZHIDKOV
4
5 #ifndef SketchPlugin_ConstraintCoincidence_HeaderFile
6 #define SketchPlugin_ConstraintCoincidence_HeaderFile
7
8 #include "SketchPlugin.h"
9 #include "SketchPlugin_Constraint.h"
10 #include <SketchPlugin_Sketch.h>
11 #include <list>
12
13 /** \class SketchPlugin_ConstraintCoincidence
14  *  \ingroup DataModel
15  *  \brief Feature for creation of a new constraint which defines equivalence of two points
16  *
17  *  These constraint has two attributes:
18  *  SketchPlugin_Constraint::ENTITY_A() and SketchPlugin_Constraint::ENTITY_B()
19  */
20 class SketchPlugin_ConstraintCoincidence: public SketchPlugin_Constraint
21 {
22 public:
23   /// Parallel constraint kind
24   inline static const std::string& ID()
25   {
26     static const std::string MY_CONSTRAINT_COINCIDENCE_ID("SketchConstraintCoincidence");
27     return MY_CONSTRAINT_COINCIDENCE_ID;
28   }
29   /// \brief Returns the kind of a feature
30   SKETCHPLUGIN_EXPORT virtual const std::string& getKind() 
31   {static std::string MY_KIND = SketchPlugin_ConstraintCoincidence::ID(); return MY_KIND;}
32
33   /// \brief Creates a new part document if needed
34   SKETCHPLUGIN_EXPORT virtual void execute();
35
36   /// \brief Request for initialization of data model of the feature: adding all attributes
37   SKETCHPLUGIN_EXPORT virtual void initAttributes();
38
39   /// \brief Use plugin manager for features creation
40   SketchPlugin_ConstraintCoincidence();
41 };
42
43 #endif