- QStringList aResList;
-
- Handle(HYDROData_Document) aDocument = HYDROData_Document::Document( myLab );
- if ( aDocument.IsNull() )
- return aResList;
-
- QString aDocName = aDocument->GetDocPyName();
- QString aZoneName = GetName();
-
- aResList << QString( "%1 = %2.CreateObject( %3 );" )
- .arg( aZoneName ).arg( aDocName ).arg( PYTHON_ZONE_ID );
- aResList << QString( "%1.SetName( \"%2\" );" )
- .arg( aZoneName ).arg( aZoneName );
- aResList << QString( "" );
-
- HYDROData_SequenceOfObjects aGeomObjects = GetGeometryObjects();
- HYDROData_SequenceOfObjects::Iterator aGeomObjsIter( aGeomObjects );
- for ( ; aGeomObjsIter.More(); aGeomObjsIter.Next() )
- {
- Handle(HYDROData_Object) aRefGeomObj =
- Handle(HYDROData_Object)::DownCast( aGeomObjsIter.Value() );
- if ( !aRefGeomObj.IsNull() )
- setPythonReferenceObject( theTreatedObjects, aResList, aRefGeomObj, "AddGeometryObject" );
- }
-
- // How can we get the shape? Mb Update() method to intersect the shapes of reference objects?
- // TODO: TopoDS_Shape aRefShape = GetShape();