From: mzn Date: Tue, 17 Dec 2013 12:27:08 +0000 (+0000) Subject: Feature #233: Export of groups. X-Git-Tag: BR_hydro_v_0_6~59 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=e37d8777251c5302dc7a0fe67c6416d69ca81397;p=modules%2Fhydro.git Feature #233: Export of groups. Add HYDROData_CalculationCase::Export( GEOM::GEOM_Gen_var, SALOMEDS::Study_ptr theStudy ) method stub. --- diff --git a/src/HYDROData/HYDROData_CalculationCase.cxx b/src/HYDROData/HYDROData_CalculationCase.cxx index 1f74601d..04163f3a 100644 --- a/src/HYDROData/HYDROData_CalculationCase.cxx +++ b/src/HYDROData/HYDROData_CalculationCase.cxx @@ -651,12 +651,24 @@ bool HYDROData_CalculationCase::Export( GEOM::GEOM_Gen_var theGeomEngine, SALOMEDS::Study_ptr theStudy ) { // Get faces - // TODO + // TODO to be revised TopTools_ListOfShape aFaces; + HYDROData_SequenceOfObjects aCaseRegions = GetRegions(); + HYDROData_SequenceOfObjects::Iterator aRegionIter( aCaseRegions ); + for ( ; aRegionIter.More(); aRegionIter.Next() ) { + Handle(HYDROData_Region) aRegion = + Handle(HYDROData_Region)::DownCast( aRegionIter.Value() ); + if( aRegion.IsNull() ) { + continue; + } + + TopoDS_Shape aRegionShape = aRegion->GetShape(); + aFaces.Append( aRegionShape ); + } // Get groups - // TODO - HYDROData_SequenceOfObjects aSplittedGroups; + // TODO to be revised + HYDROData_SequenceOfObjects aSplittedGroups = GetSplittedGroups(); return Export( theGeomEngine, theStudy, aFaces, aSplittedGroups ); }