1 // Copyright (C) 2014-2015 EDF-R&D
2 // This library is free software; you can redistribute it and/or
3 // modify it under the terms of the GNU Lesser General Public
4 // License as published by the Free Software Foundation; either
5 // version 2.1 of the License, or (at your option) any later version.
7 // This library is distributed in the hope that it will be useful,
8 // but WITHOUT ANY WARRANTY; without even the implied warranty of
9 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
10 // Lesser General Public License for more details.
12 // You should have received a copy of the GNU Lesser General Public
13 // License along with this library; if not, write to the Free Software
14 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
16 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 #include "HYDROData_Polyline3D.h"
23 class HYDROData_Polyline3D : public HYDROData_Object
26 #include "HYDROData_Polyline3D.h"
31 * Returns default filling color for new 3D polyline.
33 virtual QColor DefaultFillingColor() const;
36 * Returns default border color for new 3D polyline.
38 virtual QColor DefaultBorderColor() const;
42 // Public methods to work with 3D polyline
45 * Sets reference x,y polyline object for 3D polyline.
47 bool SetPolylineXY( HYDROData_PolylineXY thePolyline,
48 const bool theIsUpdateProfile = true )
49 [bool ( const opencascade::handle<HYDROData_PolylineXY>&,
52 Handle(HYDROData_PolylineXY) aRef =
53 Handle(HYDROData_PolylineXY)::DownCast( createHandle( a0 ) );
56 Py_BEGIN_ALLOW_THREADS
57 sipRes = sipSelfWasArg ? sipCpp->HYDROData_Polyline3D::SetPolylineXY( aRef, a1 ):
58 sipCpp->SetPolylineXY( aRef, a1 );
64 * Returns reference x,y polyline object of 3D polyline.
66 HYDROData_PolylineXY GetPolylineXY() const
67 [opencascade::handle<HYDROData_PolylineXY> ()];
69 Handle(HYDROData_PolylineXY) aRef;
71 Py_BEGIN_ALLOW_THREADS
72 aRef = sipSelfWasArg ? sipCpp->HYDROData_Polyline3D::GetPolylineXY() :
73 sipCpp->GetPolylineXY();
76 sipRes = (HYDROData_PolylineXY*)createPointer( aRef );
80 * Remove reference x,y polyline object from 3D polyline.
82 void RemovePolylineXY();
86 * Sets reference u,z profile object for 3D polyline.
88 bool SetProfileUZ( HYDROData_ProfileUZ theProfile )
89 [bool ( const opencascade::handle<HYDROData_ProfileUZ>& )];
91 Handle(HYDROData_ProfileUZ) aRef =
92 Handle(HYDROData_ProfileUZ)::DownCast( createHandle( a0 ) );
95 Py_BEGIN_ALLOW_THREADS
96 sipRes = sipSelfWasArg ? sipCpp->HYDROData_Polyline3D::SetProfileUZ( aRef ):
97 sipCpp->SetProfileUZ( aRef );
103 * Returns reference u,z profile object of 3D polyline.
105 HYDROData_ProfileUZ GetProfileUZ() const
106 [Hopencascade::handle<HYDROData_ProfileUZ> ()];
108 Handle(HYDROData_ProfileUZ) aRef;
110 Py_BEGIN_ALLOW_THREADS
111 aRef = sipSelfWasArg ? sipCpp->HYDROData_Polyline3D::GetProfileUZ() :
112 sipCpp->GetProfileUZ();
115 sipRes = (HYDROData_ProfileUZ*)createPointer( aRef );
119 * Remove reference u,z profile object from 3D polyline.
121 virtual void RemoveProfileUZ();
125 * Set reference bathymetry object for geometry object.
126 * Reimplemented to remove reference u,z profile.
128 bool SetAltitudeObject( HYDROData_IAltitudeObject theAltitude )
129 [bool ( const opencascade::handle<HYDROData_IAltitudeObject>& )];
131 Handle(HYDROData_IAltitudeObject) aRef =
132 Handle(HYDROData_IAltitudeObject)::DownCast( createHandle( a0 ) );
133 if ( !aRef.IsNull() )
135 Py_BEGIN_ALLOW_THREADS
136 sipRes = sipSelfWasArg ? sipCpp->HYDROData_Polyline3D::SetAltitudeObject( aRef ):
137 sipCpp->SetAltitudeObject( aRef );
143 * Clear the reference bathymetry object for geometry object.
144 * Reimplemented to remove child u,z profile.
146 void RemoveAltitudeObject();
150 * Returns the child u,z profile which has been generated from bathymetry.
152 HYDROData_ProfileUZ GetChildProfileUZ( const bool theIsCreate = true ) const
153 [opencascade::handle<HYDROData_ProfileUZ> ( const bool = true )];
155 Handle(HYDROData_ProfileUZ) aRef;
157 Py_BEGIN_ALLOW_THREADS
158 aRef = sipSelfWasArg ? sipCpp->HYDROData_Polyline3D::GetChildProfileUZ( a0 ) :
159 sipCpp->GetChildProfileUZ( a0 );
162 sipRes = (HYDROData_ProfileUZ*)createPointer( aRef );
167 * Sets the child u,z profile for polyline.
169 void SetChildProfileUZ( HYDROData_ProfileUZ theProfile ) [void ( const opencascade::handle<HYDROData_ProfileUZ>& )];
171 Handle(HYDROData_ProfileUZ) aRef =
172 Handle(HYDROData_ProfileUZ)::DownCast( createHandle( a0 ) );
173 if ( !aRef.IsNull() )
175 Py_BEGIN_ALLOW_THREADS
176 sipSelfWasArg ? sipCpp->HYDROData_Polyline3D::SetChildProfileUZ( aRef ):
177 sipCpp->SetChildProfileUZ( aRef );
185 * Creates new object in the internal data structure. Use higher level objects
186 * to create objects with real content.
188 HYDROData_Polyline3D();
191 * Destructs properties of the object and object itself, removes it from the document.
193 virtual ~HYDROData_Polyline3D();