Salome HOME
Issue #1860: fix end lines with spaces
[modules/shaper.git] / src / FeaturesAPI / FeaturesAPI_RemoveSubShapes.h
1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D -->
2
3 // File:        FeaturesAPI_RemoveSubShapes.h
4 // Created:     09 June 2016
5 // Author:      Dmitry Bobylev
6
7 #ifndef FeaturesAPI_RemoveSubShapes_H_
8 #define FeaturesAPI_RemoveSubShapes_H_
9
10 #include "FeaturesAPI.h"
11
12 #include <FeaturesPlugin_RemoveSubShapes.h>
13
14 #include <ModelHighAPI_Interface.h>
15 #include <ModelHighAPI_Macro.h>
16
17 class ModelHighAPI_Dumper;
18 class ModelHighAPI_Selection;
19
20 /// \class FeaturesAPI_RemoveSubShapes
21 /// \ingroup CPPHighAPI
22 /// \brief Interface for RemoveSubShapes feature.
23 class FeaturesAPI_RemoveSubShapes: public ModelHighAPI_Interface
24 {
25 public:
26   /// Constructor without values.
27   FEATURESAPI_EXPORT
28   explicit FeaturesAPI_RemoveSubShapes(const std::shared_ptr<ModelAPI_Feature>& theFeature);
29
30   /// Constructor with values.
31   FEATURESAPI_EXPORT
32   explicit FeaturesAPI_RemoveSubShapes(const std::shared_ptr<ModelAPI_Feature>& theFeature,
33                                        const ModelHighAPI_Selection& theBase);
34
35   /// Destructor.
36   FEATURESAPI_EXPORT
37   virtual ~FeaturesAPI_RemoveSubShapes();
38
39   INTERFACE_2(FeaturesPlugin_RemoveSubShapes::ID(),
40               base, FeaturesPlugin_RemoveSubShapes::BASE_SHAPE_ID(),
41               ModelAPI_AttributeSelection, /** Base */,
42               subshapes, FeaturesPlugin_RemoveSubShapes::SUBSHAPES_ID(),
43               ModelAPI_AttributeSelectionList, /** Subshapes */)
44
45   /// Modify objects attribute of the feature.
46   FEATURESAPI_EXPORT
47   void setBase(const ModelHighAPI_Selection& theBase);
48
49   /// Modify tools attribute of the feature.
50   FEATURESAPI_EXPORT
51   void setSubShapesToKeep(const std::list<ModelHighAPI_Selection>& theSubShapes);
52
53   /// Dump wrapped feature
54   FEATURESAPI_EXPORT
55   virtual void dump(ModelHighAPI_Dumper& theDumper) const;
56 };
57
58 /// Pointer on RemoveSubShapes object.
59 typedef std::shared_ptr<FeaturesAPI_RemoveSubShapes> RemoveSubShapesPtr;
60
61 /// \ingroup CPPHighAPI
62 /// \brief Create RemoveSubShapes feature.
63 FEATURESAPI_EXPORT
64 RemoveSubShapesPtr addRemoveSubShapes(const std::shared_ptr<ModelAPI_Document>& thePart,
65                                       const ModelHighAPI_Selection& theBase);
66
67 #endif // FeaturesAPI_RemoveSubShapes_H_