- #include "GeomAPI_Interface.h"
- #include "GeomAPI_Shape.h"
- #include "ModelAPI.h"
- #include "ModelAPI_Document.h"
- #include "ModelAPI_Session.h"
- #include "ModelAPI_Object.h"
- #include "ModelAPI_Feature.h"
- #include "ModelAPI_Plugin.h"
- #include "ModelAPI_CompositeFeature.h"
- #include "ModelAPI_Data.h"
- #include "ModelAPI_Attribute.h"
- #include "ModelAPI_AttributeDocRef.h"
- #include "ModelAPI_AttributeDouble.h"
- #include "ModelAPI_AttributeInteger.h"
- #include "ModelAPI_AttributeString.h"
- #include "ModelAPI_AttributeReference.h"
- #include "ModelAPI_AttributeRefAttr.h"
- #include "ModelAPI_AttributeSelection.h"
- #include "ModelAPI_AttributeSelectionList.h"
- #include "ModelAPI_AttributeValidator.h"
- #include "ModelAPI_Validator.h"
- #include "ModelAPI_FeatureValidator.h"
- #include "ModelAPI_AttributeRefList.h"
- #include "ModelAPI_AttributeBoolean.h"
- #include "ModelAPI_Result.h"
- #include "ModelAPI_ResultConstruction.h"
- #include "ModelAPI_ResultBody.h"
- #include "ModelAPI_ResultPart.h"
- #include "ModelAPI_ResultParameters.h"
- #include "ModelAPI_ResultGroup.h"
- #include "ModelAPI_Tools.h"
-
- template<class T1, class T2>
- std::shared_ptr<T1> shared_ptr_cast(std::shared_ptr<T2> theObject)
- {
- return std::dynamic_pointer_cast<T1>(theObject);
- }
-
+ #include "ModelAPI_swig.h"
+
+ // fix for SWIG v4.1.1
+ #if PY_VERSION_HEX >= 0x03020000
+ # define SWIGPY_SLICEOBJECT PyObject
+ #else
+ # define SWIGPY_SLICEOBJECT PySliceObject
+ #endif
+
+ // fix for SWIG v2.0.4
+ #define SWIGPY_SLICE_ARG(obj) ((SWIGPY_SLICEOBJECT*)(obj))
+ #define SWIGPY_UNICODE_ARG(obj) ((PyObject*) (obj))