// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public // License as published by the Free Software Foundation; either // version 2.1 of the License. // // This library is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU // Lesser General Public License for more details. // // You should have received a copy of the GNU Lesser General Public // License along with this library; if not, write to the Free Software // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com // %ExportedHeaderCode #include %End class HYDROData_Calculation : HYDROData_Object { %TypeHeaderCode #include %End %ConvertToSubClassCode switch ( sipCpp->GetKind() ) { case KIND_CALCULATION: sipClass = sipClass_HYDROData_Calculation; break; default: // We don't recognise the type. sipClass = NULL; } %End public: /** * Split reference geometry objects to non-intersected regions. */ void SplitGeometryObjects(); /** * Returns number of geometry objects for calculation case. */ int NbGeometryObjects() const; /** * dd new one geometry object for calculation case. */ void AddGeometryObject( HYDROData_Object theRegion ) [void (const Handle_HYDROData_Object&)]; %MethodCode Handle(HYDROData_Object) aGeomObj = Handle(HYDROData_Object)::DownCast( createHandle( a0 ) ); if ( !aGeomObj.IsNull() ) { Py_BEGIN_ALLOW_THREADS sipSelfWasArg ? sipCpp->HYDROData_Calculation::AddGeometryObject( aGeomObj ) : sipCpp->AddGeometryObject( aGeomObj ); Py_END_ALLOW_THREADS } %End /** * Replace the geometry object for calculation case. */ void SetGeometryObject( const int theIndex, HYDROData_Object theObject ) [void (const int, const Handle_HYDROData_Object&)]; %MethodCode Handle(HYDROData_Object) aGeomObj = Handle(HYDROData_Object)::DownCast( createHandle( a1 ) ); if ( !aGeomObj.IsNull() ) { Py_BEGIN_ALLOW_THREADS sipSelfWasArg ? sipCpp->HYDROData_Calculation::SetGeometryObject( a0, aGeomObj ) : sipCpp->SetGeometryObject( a0, aGeomObj ); Py_END_ALLOW_THREADS } %End /** * Sets the geometry object for calculation case. */ //void SetGeometryObjects( const HYDROData_SequenceOfObjects& theObjects ); /** * Returns geometry object of calculation case by index. */ HYDROData_Object GetGeometryObject( const int theIndex ) const [Handle_HYDROData_Object (const int)]; %MethodCode Handle(HYDROData_Object) aGeomObj; Py_BEGIN_ALLOW_THREADS aGeomObj = sipSelfWasArg ? sipCpp->HYDROData_Calculation::GetGeometryObject( a0 ) : sipCpp->GetGeometryObject( a0 ); Py_END_ALLOW_THREADS sipRes = (HYDROData_Object*)createPointer( aGeomObj ); %End /** * Returns all geometry objects of calculation case. */ //HYDROData_SequenceOfObjects GetGeometryObjects() const; /** * Removes all geometry objects from calculation case. */ void RemoveGeometryObjects(); /** * Add new one region for calculation case. * The new region is not added into the list of reference regions. */ HYDROData_Region AddNewRegion() [Handle_HYDROData_Region ()]; %MethodCode Handle(HYDROData_Region) aNewRegion; Py_BEGIN_ALLOW_THREADS aNewRegion = sipSelfWasArg ? sipCpp->HYDROData_Calculation::AddNewRegion() : sipCpp->AddNewRegion(); Py_END_ALLOW_THREADS sipRes = (HYDROData_Region*)createPointer( aNewRegion ); %End /** * Removes all child regions from calculation case. */ void RemoveChildRegions(); /** * Returns number of reference regions for calculation case. */ int NbRegions() const; /** * Add new one reference region for calculation case. */ void AddRegion( HYDROData_Region theRegion ) [void (const Handle_HYDROData_Region&)]; %MethodCode Handle(HYDROData_Region) aRegion = Handle(HYDROData_Region)::DownCast( createHandle( a0 ) ); if ( !aRegion.IsNull() ) { Py_BEGIN_ALLOW_THREADS sipSelfWasArg ? sipCpp->HYDROData_Calculation::AddRegion( aRegion ) : sipCpp->AddRegion( aRegion ); Py_END_ALLOW_THREADS } %End /** * Replace the reference region for calculation case. */ void SetRegion( const int theIndex, HYDROData_Region theRegion ) [void (const int, const Handle_HYDROData_Region&)]; %MethodCode Handle(HYDROData_Region) aRegion = Handle(HYDROData_Region)::DownCast( createHandle( a1 ) ); if ( !aRegion.IsNull() ) { Py_BEGIN_ALLOW_THREADS sipSelfWasArg ? sipCpp->HYDROData_Calculation::SetRegion( a0, aRegion ) : sipCpp->SetRegion( a0, aRegion ); Py_END_ALLOW_THREADS } %End /** * Inserts the reference region for calculation case before given index. */ void InsertRegion( const int theBeforeIndex, HYDROData_Region theRegion ) [void (const int, const Handle_HYDROData_Region&)]; %MethodCode Handle(HYDROData_Region) aRegion = Handle(HYDROData_Region)::DownCast( createHandle( a1 ) ); if ( !aRegion.IsNull() ) { Py_BEGIN_ALLOW_THREADS sipSelfWasArg ? sipCpp->HYDROData_Calculation::InsertRegion( a0, aRegion ) : sipCpp->InsertRegion( a0, aRegion ); Py_END_ALLOW_THREADS } %End /** * Sets reference regions for calculation case. */ //void SetRegions( const HYDROData_SequenceOfObjects& theRegions ); /** * Returns reference region of calculation case by index. */ HYDROData_Region GetRegion( const int theIndex ) const [Handle_HYDROData_Region (const int)]; %MethodCode Handle(HYDROData_Region) aRefRegion; Py_BEGIN_ALLOW_THREADS aRefRegion = sipSelfWasArg ? sipCpp->HYDROData_Calculation::GetRegion( a0 ) : sipCpp->GetRegion( a0 ); Py_END_ALLOW_THREADS sipRes = (HYDROData_Region*)createPointer( aRefRegion ); %End /** * Returns all reference regions of calculation case. */ //void HYDROData_SequenceOfObjects GetRegions() const; /** * Removes reference region from calculation case. */ void RemoveRegion( HYDROData_Region theRegion ) [void (const Handle_HYDROData_Region&)]; %MethodCode Handle(HYDROData_Region) aRegion = Handle(HYDROData_Region)::DownCast( createHandle( a0 ) ); if ( !aRegion.IsNull() ) { Py_BEGIN_ALLOW_THREADS sipSelfWasArg ? sipCpp->HYDROData_Calculation::RemoveRegion( aRegion ) : sipCpp->RemoveRegion( aRegion ); Py_END_ALLOW_THREADS } %End /** * Removes region from calculation case by it index. */ void RemoveRegion( const int theIndex ); /** * Removes all reference regions from calculation case. */ void RemoveRegions(); protected: /** * Creates new object in the internal data structure. Use higher level objects * to create objects with real content. */ HYDROData_Calculation(); /** * Destructs properties of the object and object itself, removes it from the document. */ ~HYDROData_Calculation(); };