Salome HOME
Dump Python in the High Level Parameterized Geometry API (issue #1648)
[modules/shaper.git] / src / ModelHighAPI / ModelHighAPI_Tools.h
1 // Name   : ModelHighAPI_Tools.h
2 // Purpose: 
3 //
4 // History:
5 // 07/06/16 - Sergey POKHODENKO - Creation of the file
6
7 #ifndef SRC_MODELHIGHAPI_MODELHIGHAPI_TOOLS_H_
8 #define SRC_MODELHIGHAPI_MODELHIGHAPI_TOOLS_H_
9
10 //--------------------------------------------------------------------------------------
11 #include "ModelHighAPI.h"
12
13 #include <GeomAPI_Shape.h>
14
15 #include <list>
16 #include <memory>
17 #include <string>
18 //--------------------------------------------------------------------------------------
19 class GeomAPI_Dir;
20 class GeomAPI_Pnt;
21 class GeomAPI_Pnt2d;
22 //--------------------------------------------------------------------------------------
23 class GeomDataAPI_Dir;
24 class GeomDataAPI_Point;
25 class GeomDataAPI_Point2D;
26 //--------------------------------------------------------------------------------------
27 class ModelAPI_AttributeBoolean;
28 class ModelAPI_AttributeDocRef;
29 class ModelAPI_AttributeDouble;
30 class ModelAPI_AttributeIntArray;
31 class ModelAPI_AttributeInteger;
32 class ModelAPI_AttributeRefAttr;
33 class ModelAPI_AttributeRefAttrList;
34 class ModelAPI_AttributeReference;
35 class ModelAPI_AttributeRefList;
36 class ModelAPI_AttributeSelection;
37 class ModelAPI_AttributeSelectionList;
38 class ModelAPI_AttributeString;
39 class ModelAPI_Object;
40 //--------------------------------------------------------------------------------------
41 class ModelHighAPI_Double;
42 class ModelHighAPI_Integer;
43 class ModelHighAPI_RefAttr;
44 class ModelHighAPI_Reference;
45 class ModelHighAPI_Selection;
46 //--------------------------------------------------------------------------------------
47 MODELHIGHAPI_EXPORT
48 void fillAttribute(const std::shared_ptr<GeomAPI_Pnt2d> & theValue,
49                    const std::shared_ptr<GeomDataAPI_Point2D> & theAttribute);
50
51 MODELHIGHAPI_EXPORT
52 void fillAttribute(const std::shared_ptr<GeomDataAPI_Point2D> & theAttribute,
53                    double theX, double theY);
54
55 MODELHIGHAPI_EXPORT
56 void fillAttribute(const std::shared_ptr<GeomAPI_Dir> & theValue,
57                    const std::shared_ptr<GeomDataAPI_Dir> & theAttribute);
58
59 MODELHIGHAPI_EXPORT
60 void fillAttribute(const std::shared_ptr<GeomAPI_Pnt> & theValue,
61                    const std::shared_ptr<GeomDataAPI_Point> & theAttribute);
62
63 //--------------------------------------------------------------------------------------
64 MODELHIGHAPI_EXPORT
65 void fillAttribute(bool theValue,
66                    const std::shared_ptr<ModelAPI_AttributeBoolean> & theAttribute);
67
68 MODELHIGHAPI_EXPORT
69 void fillAttribute(const ModelHighAPI_Double & theValue,
70                    const std::shared_ptr<ModelAPI_AttributeDouble> & theAttribute);
71
72 MODELHIGHAPI_EXPORT
73 void fillAttribute(double theValue,
74                    const std::shared_ptr<ModelAPI_AttributeDouble> & theAttribute);
75
76 MODELHIGHAPI_EXPORT
77 void fillAttribute(const ModelHighAPI_Integer & theValue,
78                    const std::shared_ptr<ModelAPI_AttributeInteger> & theAttribute);
79
80 MODELHIGHAPI_EXPORT
81 void fillAttribute(int theValue,
82                    const std::shared_ptr<ModelAPI_AttributeInteger> & theAttribute);
83
84 MODELHIGHAPI_EXPORT
85 void fillAttribute(const ModelHighAPI_RefAttr & theValue,
86                    const std::shared_ptr<ModelAPI_AttributeRefAttr> & theAttribute);
87
88 MODELHIGHAPI_EXPORT
89 void fillAttribute(const std::list<ModelHighAPI_RefAttr> & theValue,
90                    const std::shared_ptr<ModelAPI_AttributeRefAttrList> & theAttribute);
91
92 MODELHIGHAPI_EXPORT
93 void fillAttribute(const ModelHighAPI_Reference & theValue,
94                    const std::shared_ptr<ModelAPI_AttributeReference> & theAttribute);
95
96 MODELHIGHAPI_EXPORT
97 void fillAttribute(const std::list<ModelHighAPI_Reference> & theValue,
98                    const std::shared_ptr<ModelAPI_AttributeRefList> & theAttribute);
99
100 MODELHIGHAPI_EXPORT
101 void fillAttribute(const std::shared_ptr<ModelAPI_Object> & theValue,
102                    const std::shared_ptr<ModelAPI_AttributeReference> & theAttribute);
103
104 MODELHIGHAPI_EXPORT
105 void fillAttribute(const std::list<std::shared_ptr<ModelAPI_Object> > & theValue,
106                    const std::shared_ptr<ModelAPI_AttributeRefList> & theAttribute);
107
108 MODELHIGHAPI_EXPORT
109 void fillAttribute(const std::list<ModelHighAPI_Selection> & theValue,
110                    const std::shared_ptr<ModelAPI_AttributeRefList> & theAttribute);
111
112 MODELHIGHAPI_EXPORT
113 void fillAttribute(const ModelHighAPI_Selection & theValue,
114                    const std::shared_ptr<ModelAPI_AttributeSelection> & theAttribute);
115
116 MODELHIGHAPI_EXPORT
117 void fillAttribute(const std::list<ModelHighAPI_Selection> & theValue,
118                    const std::shared_ptr<ModelAPI_AttributeSelectionList> & theAttribute);
119
120 MODELHIGHAPI_EXPORT
121 void fillAttribute(const std::string & theValue,
122                    const std::shared_ptr<ModelAPI_AttributeString> & theAttribute);
123 MODELHIGHAPI_EXPORT
124 void fillAttribute(const char * theValue,
125                    const std::shared_ptr<ModelAPI_AttributeString> & theAttribute);
126
127 MODELHIGHAPI_EXPORT
128 GeomAPI_Shape::ShapeType shapeTypeByStr(std::string theShapeTypeStr);
129
130 MODELHIGHAPI_EXPORT
131 GeomAPI_Shape::ShapeType getShapeType(const ModelHighAPI_Selection& theSelection);
132
133 //--------------------------------------------------------------------------------------
134 //--------------------------------------------------------------------------------------
135 #endif /* SRC_MODELHIGHAPI_MODELHIGHAPI_TOOLS_H_ */