From ff248302b676957c7858a76e309256236fe8aad4 Mon Sep 17 00:00:00 2001 From: rkv Date: Wed, 8 Jan 2014 09:11:40 +0000 Subject: [PATCH] SIP: HYDROData_Profile is included. --- src/HYDROPy/HYDROData_Document.sip | 10 ++++++++++ src/HYDROPy/HYDROData_Profile.sip | 26 ++++++++++---------------- 2 files changed, 20 insertions(+), 16 deletions(-) diff --git a/src/HYDROPy/HYDROData_Document.sip b/src/HYDROPy/HYDROData_Document.sip index d1639754..a5c3872e 100644 --- a/src/HYDROPy/HYDROData_Document.sip +++ b/src/HYDROPy/HYDROData_Document.sip @@ -72,11 +72,21 @@ class HYDROData_Document aRes = new HYDROData_Bathymetry( *dynamic_cast( theObject ) ); break; } + case KIND_OBSTACLE_ALTITUDE: + { + aRes = new HYDROData_ObstacleAltitude( *dynamic_cast( theObject ) ); + break; + } case KIND_IMMERSIBLE_ZONE: { aRes = new HYDROData_ImmersibleZone( *dynamic_cast( theObject ) ); break; } + case KIND_PROFILE: + { + aRes = new HYDROData_Profile( *dynamic_cast( theObject ) ); + break; + } case KIND_PROFILEUZ: { aRes = new HYDROData_ProfileUZ( *dynamic_cast( theObject ) ); diff --git a/src/HYDROPy/HYDROData_Profile.sip b/src/HYDROPy/HYDROData_Profile.sip index e25057b4..6b11c594 100644 --- a/src/HYDROPy/HYDROData_Profile.sip +++ b/src/HYDROPy/HYDROData_Profile.sip @@ -175,24 +175,18 @@ public: * \param theFileName the path to file * \return \c number of successfully imported profiles */ - /*static int ImportFromFile( HYDROData_Document theDoc, + static int ImportFromFile( HYDROData_Document theDoc, const TCollection_AsciiString& theFileName, NCollection_Sequence& theBadProfilesIds ) - [int ImportFromFile( const Handle(HYDROData_Document)& , - const TCollection_AsciiString& , - NCollection_Sequence& )]; - MethodCode - Handle(HYDROData_Document) aRef = - Handle(HYDROData_Document)::DownCast( createHandle( a0 ) ); - if ( !aRef.IsNull() ) - { - Py_BEGIN_ALLOW_THREADS - sipRes = sipSelfWasArg ? sipCpp->HYDROData_Profile::ImportFromFile( aRef, a1, a2 ): - sipCpp->ImportFromFile( aRef, a1, a2 ); - Py_END_ALLOW_THREADS - } - End -*/ + [int ( const Handle_HYDROData_Document& , + const TCollection_AsciiString& , + NCollection_Sequence& )]; + %MethodCode + Py_BEGIN_ALLOW_THREADS + sipRes = HYDROData_Profile::ImportFromFile( a0, *a1, a2 ); + Py_END_ALLOW_THREADS + %End + /** * Imports Profile data from file. * \param theFileName the path to file -- 2.39.2