1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D -->
3 // File: FeaturesPlugin_Group.h
4 // Created: 08 Oct 2014
5 // Author: Sergey BELASH
7 #ifndef FEATURESPLUGIN_GROUP_H_
8 #define FEATURESPLUGIN_GROUP_H_
10 #include "FeaturesPlugin.h"
11 #include <ModelAPI_Feature.h>
12 #include <GeomAPI_Shape.h>
14 /**\class FeaturesPlugin_Group
16 * \brief Feature for selection of sub-shapes of some shapes.
18 * All selected sub-shapes must be of equal type (vertex, edge, face, etc) but may
19 * be selected on different objects.
21 class FeaturesPlugin_Group : public ModelAPI_Feature
25 inline static const std::string& ID()
27 static const std::string MY_GROUP_ID("Group");
30 /// attribute name of selected entities list
31 inline static const std::string& LIST_ID()
33 static const std::string MY_GROUP_LIST_ID("group_list");
34 return MY_GROUP_LIST_ID;
37 /// Returns the kind of a feature
38 FEATURESPLUGIN_EXPORT virtual const std::string& getKind()
40 static std::string MY_KIND = FeaturesPlugin_Group::ID();
44 /// Creates a new part document if needed
45 FEATURESPLUGIN_EXPORT virtual void execute();
47 /// Request for initialization of data model of the feature: adding all attributes
48 FEATURESPLUGIN_EXPORT virtual void initAttributes();
50 /// Result of groups is created on the fly and don't stored to the document
51 FEATURESPLUGIN_EXPORT virtual bool isPersistentResult() {return true;}
53 /// Use plugin manager for features creation
54 FeaturesPlugin_Group();