X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FHYDROData%2FHYDROData_Iterator.cxx;h=3277b3f52d2fb549e39b5dc27d453ba9399244dd;hb=bd81def133c235351f4c18834c6660450f16b9ee;hp=f1dde62f1b67520606ec235e12bf5fa933df22b3;hpb=4564a2513ac7a519741895560f26d7eef1d1400d;p=modules%2Fhydro.git diff --git a/src/HYDROData/HYDROData_Iterator.cxx b/src/HYDROData/HYDROData_Iterator.cxx index f1dde62f..3277b3f5 100644 --- a/src/HYDROData/HYDROData_Iterator.cxx +++ b/src/HYDROData/HYDROData_Iterator.cxx @@ -1,3 +1,20 @@ +// Copyright (C) 2014-2015 EDF-R&D +// 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, or (at your option) any later version. +// +// 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 +// #include "HYDROData_Iterator.h" @@ -6,27 +23,37 @@ #include "HYDROData_CalculationCase.h" #include "HYDROData_Channel.h" #include "HYDROData_Confluence.h" -#include "HYDROData_DummyObject3D.h" #include "HYDROData_Digue.h" -#include "HYDROData_EdgesGroup.h" +#include "HYDROData_DummyObject3D.h" #include "HYDROData_Image.h" #include "HYDROData_ImmersibleZone.h" +#include "HYDROData_LandCoverMap.h" #include "HYDROData_Obstacle.h" +#include "HYDROData_ObstacleAltitude.h" +#include "HYDROData_ChannelAltitude.h" #include "HYDROData_Polyline3D.h" #include "HYDROData_PolylineXY.h" #include "HYDROData_Profile.h" #include "HYDROData_ProfileUZ.h" -#include "HYDROData_VisualState.h" #include "HYDROData_Region.h" #include "HYDROData_River.h" +#include "HYDROData_ShapesGroup.h" +#include "HYDROData_SplitShapesGroup.h" #include "HYDROData_Stream.h" +#include "HYDROData_StreamAltitude.h" +#include "HYDROData_VisualState.h" #include "HYDROData_Zone.h" +#include "HYDROData_StricklerTable.h" +#include "HYDROData_DTM.h" #include #include #include +#define _DEVDEBUG_ +#include "HYDRO_trace.hxx" + //! Returns label by root objects kind and the kind of the object static TDF_Label GetLabelByKind(TDF_Label theRoot, ObjectKind theKind) { @@ -79,7 +106,7 @@ Handle(HYDROData_Entity) HYDROData_Iterator::CreateObject( TDF_Label& the Handle(TDataStd_NamedData) aNamedData; theNewLabel.FindAttribute( TDataStd_NamedData::GetID(), aNamedData ); - aNamedData->SetInteger( "ObjectKind", theObjectKind ); + aNamedData->SetInteger( "ObjectKind", theObjectKind ); //??CAF return Object( theNewLabel ); } @@ -106,27 +133,36 @@ Handle(HYDROData_Entity) HYDROData_Iterator::Object( const TDF_Label& theLabel ) switch( aKind ) { - case KIND_IMAGE: aResult = new HYDROData_Image(); break; - case KIND_POLYLINE: aResult = new HYDROData_Polyline3D(); break; - case KIND_BATHYMETRY: aResult = new HYDROData_Bathymetry(); break; - case KIND_ALTITUDE: aResult = new HYDROData_AltitudeObject(); break; - case KIND_IMMERSIBLE_ZONE: aResult = new HYDROData_ImmersibleZone(); break; - case KIND_RIVER: aResult = new HYDROData_River(); break; - case KIND_STREAM: aResult = new HYDROData_Stream(); break; - case KIND_CONFLUENCE: aResult = new HYDROData_Confluence(); break; - case KIND_CHANNEL: aResult = new HYDROData_Channel(); break; - case KIND_OBSTACLE: aResult = new HYDROData_Obstacle(); break; - case KIND_DIGUE: aResult = new HYDROData_Digue(); break; - case KIND_PROFILE: aResult = new HYDROData_Profile(); break; - case KIND_PROFILEUZ: aResult = new HYDROData_ProfileUZ(); break; - case KIND_POLYLINEXY: aResult = new HYDROData_PolylineXY(); break; - case KIND_CALCULATION: aResult = new HYDROData_CalculationCase(); break; - case KIND_REGION: aResult = new HYDROData_Region(); break; - case KIND_ZONE: aResult = new HYDROData_Zone(); break; - case KIND_VISUAL_STATE: aResult = new HYDROData_VisualState(); break; - case KIND_DUMMY_3D: aResult = new HYDROData_DummyObject3D(); break; - case KIND_EDGES_GROUP: aResult = new HYDROData_EdgesGroup(); break; - default: break; + DEBTRACE("HYDROData_Iterator::Object " << aKind); + case KIND_IMAGE: aResult = new HYDROData_Image(); break; + case KIND_POLYLINE: aResult = new HYDROData_Polyline3D(); break; + case KIND_BATHYMETRY: aResult = new HYDROData_Bathymetry(); break; + case KIND_ALTITUDE: aResult = new HYDROData_AltitudeObject(); break; + case KIND_IMMERSIBLE_ZONE: aResult = new HYDROData_ImmersibleZone(); break; + case KIND_RIVER: aResult = new HYDROData_River(); break; + case KIND_STREAM: aResult = new HYDROData_Stream(); break; + case KIND_CONFLUENCE: aResult = new HYDROData_Confluence(); break; + case KIND_CHANNEL: aResult = new HYDROData_Channel(); break; + case KIND_OBSTACLE: aResult = new HYDROData_Obstacle(); break; + case KIND_DIGUE: aResult = new HYDROData_Digue(); break; + case KIND_PROFILE: aResult = new HYDROData_Profile(); break; + case KIND_PROFILEUZ: aResult = new HYDROData_ProfileUZ(); break; + case KIND_POLYLINEXY: aResult = new HYDROData_PolylineXY(); break; + case KIND_CALCULATION: aResult = new HYDROData_CalculationCase(); break; + case KIND_REGION: aResult = new HYDROData_Region(); break; + case KIND_ZONE: aResult = new HYDROData_Zone(); break; + case KIND_VISUAL_STATE: aResult = new HYDROData_VisualState(); break; + case KIND_DUMMY_3D: aResult = new HYDROData_DummyObject3D(); break; + case KIND_SHAPES_GROUP: aResult = new HYDROData_ShapesGroup(); break; + case KIND_SPLIT_GROUP: aResult = new HYDROData_SplitShapesGroup(); break; + case KIND_STREAM_ALTITUDE: aResult = new HYDROData_StreamAltitude(); break; + case KIND_OBSTACLE_ALTITUDE: aResult = new HYDROData_ObstacleAltitude(); break; + case KIND_STRICKLER_TABLE: aResult = new HYDROData_StricklerTable(); break; + case KIND_LAND_COVER_OBSOLETE: break; + case KIND_CHANNEL_ALTITUDE: aResult = new HYDROData_ChannelAltitude(); break; + case KIND_LAND_COVER_MAP: aResult = new HYDROData_LandCoverMap(); break; + case KIND_DTM: aResult = new HYDROData_DTM(); break; + default: break; } if ( !aResult.IsNull() )