1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
3 // File: ConstructionPlugin_Point.h
5 // Author: Mikhail PONIKAROV
7 #ifndef ConstructionPlugin_Point_H_
8 #define ConstructionPlugin_Point_H_
10 #include "ConstructionPlugin.h"
11 #include <ModelAPI_Feature.h>
12 #include <ModelAPI_Result.h>
14 /**\class ConstructionPlugin_Point
16 * \brief Feature for creation of the new part in PartSet.
18 class ConstructionPlugin_Point : public ModelAPI_Feature
21 /// Returns the kind of a feature
22 CONSTRUCTIONPLUGIN_EXPORT virtual const std::string& getKind();
24 inline static const std::string& ID()
26 static const std::string CONSTRUCTION_POINT_KIND("Point");
27 return CONSTRUCTION_POINT_KIND;
30 /// attribute name for X coordinate
31 inline static const std::string& X()
33 static const std::string POINT_ATTR_X("x");
36 /// attribute name for Y coordinate
37 inline static const std::string& Y()
39 static const std::string POINT_ATTR_Y("y");
42 /// attribute name for Z coordinate
43 inline static const std::string& Z()
45 static const std::string POINT_ATTR_Z("z");
49 /// Creates a new part document if needed
50 CONSTRUCTIONPLUGIN_EXPORT virtual void execute();
52 /// Request for initialization of data model of the feature: adding all attributes
53 CONSTRUCTIONPLUGIN_EXPORT virtual void initAttributes();
55 /// Construction result is allways recomuted on the fly
56 CONSTRUCTIONPLUGIN_EXPORT virtual bool isPersistentResult() {return false;}
58 /// Use plugin manager for features creation
59 ConstructionPlugin_Point();