Salome HOME
Fix for naming in Build features.
[modules/shaper.git] / src / SketchAPI / SketchAPI_Projection.h
1 // Name   : SketchAPI_Projection.h
2 // Purpose: 
3 //
4 // History:
5 // 16/06/16 - Sergey POKHODENKO - Creation of the file
6
7 #ifndef SRC_SKETCHAPI_SKETCHAPI_PROJECTION_H_
8 #define SRC_SKETCHAPI_SKETCHAPI_PROJECTION_H_
9
10 //--------------------------------------------------------------------------------------
11 #include "SketchAPI.h"
12
13 #include <SketchPlugin_Projection.h>
14
15 #include "SketchAPI_SketchEntity.h"
16 //--------------------------------------------------------------------------------------
17 class ModelHighAPI_Selection;
18 //--------------------------------------------------------------------------------------
19 /**\class SketchAPI_Projection
20  * \ingroup CPPHighAPI
21  * \brief Interface for Projection feature
22  */
23 class SketchAPI_Projection : public SketchAPI_SketchEntity
24 {
25 public:
26   /// Constructor without values
27   SKETCHAPI_EXPORT
28   explicit SketchAPI_Projection(const std::shared_ptr<ModelAPI_Feature> & theFeature);
29   /// Constructor with values
30   SKETCHAPI_EXPORT
31   SketchAPI_Projection(const std::shared_ptr<ModelAPI_Feature> & theFeature,
32                        const ModelHighAPI_Selection & theExternalFeature);
33   /// Constructor with values
34   SKETCHAPI_EXPORT
35   SketchAPI_Projection(const std::shared_ptr<ModelAPI_Feature> & theFeature,
36                        const std::string & theExternalName);
37   /// Destructor
38   SKETCHAPI_EXPORT
39   virtual ~SketchAPI_Projection();
40
41   INTERFACE_3(SketchPlugin_Projection::ID(),
42               externalFeature, SketchPlugin_Projection::EXTERNAL_FEATURE_ID(), ModelAPI_AttributeSelection, /** External feature */,
43               projectedFeature, SketchPlugin_Projection::PROJECTED_FEATURE_ID(), ModelAPI_AttributeRefAttr, /** Projected feature */,
44               external, SketchPlugin_Projection::EXTERNAL_ID(), ModelAPI_AttributeSelection, /** External */
45   )
46
47   /// Set external feature
48   SKETCHAPI_EXPORT
49   void setExternalFeature(const ModelHighAPI_Selection & theExternalLine);
50
51   /// Set by external name
52   SKETCHAPI_EXPORT
53   void setByExternalName(const std::string & theExternalName);
54
55   /// Dump wrapped feature
56   SKETCHAPI_EXPORT
57   virtual void dump(ModelHighAPI_Dumper& theDumper) const;
58 };
59
60 //! Pointer on Projection object
61 typedef std::shared_ptr<SketchAPI_Projection> ProjectionPtr;
62
63 //--------------------------------------------------------------------------------------
64 //--------------------------------------------------------------------------------------
65 #endif /* SRC_SKETCHAPI_SKETCHAPI_PROJECTION_H_ */