From 0f6ec612cfe3cc787576f913690f239b0cb88f8d Mon Sep 17 00:00:00 2001 From: curt Date: Sat, 27 Mar 1999 05:31:24 +0000 Subject: [PATCH] Make 0 the default area type since this corresponds well with the conventions used by the triangulator. --- Polygon/names.cxx | 15 ++++++++++++--- Polygon/names.hxx | 36 ++++++++++++++++++++++++------------ 2 files changed, 36 insertions(+), 15 deletions(-) diff --git a/Polygon/names.cxx b/Polygon/names.cxx index eabd8697e..d3d190612 100644 --- a/Polygon/names.cxx +++ b/Polygon/names.cxx @@ -30,7 +30,9 @@ // return area type from text name AreaType get_area_type( string area ) { - if ( area == "AirportKeep" ) { + if ( area == "Default" ) { + return DefaultArea; + } else if ( area == "AirportKeep" ) { return AirportKeepArea; } else if ( area == "AirportIgnore" ) { return AirportIgnoreArea; @@ -42,7 +44,8 @@ AreaType get_area_type( string area ) { return OceanArea; } else if ( area == "Lake" ) { return LakeArea; - } else if ( area == "Lake Dry" ) { + } else if ( (area == "Lake Dry") + || (area == "DryLake") ) { return DryLakeArea; } else if ( (area == "Lake Intermittent") || (area == "IntermittentLake") ) { @@ -74,7 +77,9 @@ AreaType get_area_type( string area ) { // return text from of area name string get_area_name( AreaType area ) { - if ( area == AirportKeepArea ) { + if ( area == DefaultArea ) { + return "Default"; + } else if ( area == AirportKeepArea ) { return "AirportKeep"; } else if ( area == AirportIgnoreArea ) { return "AirportIgnore"; @@ -110,6 +115,10 @@ string get_area_name( AreaType area ) { // $Log$ +// Revision 1.6 1999/03/27 05:31:24 curt +// Make 0 the default area type since this corresponds well with the conventions +// used by the triangulator. +// // Revision 1.5 1999/03/22 23:49:29 curt // Moved AreaType get_shapefile_type(GDBFile *dbf, int rec) to where it // belongs in ShapeFile/ diff --git a/Polygon/names.hxx b/Polygon/names.hxx index 78c85d339..0a919a5ed 100644 --- a/Polygon/names.hxx +++ b/Polygon/names.hxx @@ -26,22 +26,30 @@ #define _NAMES_HXX +#include + +#include STL_STRING + +FG_USING_STD(string); + + // Posible shape file types. Note the order of these is important and // defines the priority of these shapes if they should intersect. The // smaller the number, the higher the priority. enum AreaType { - AirportKeepArea = 0, - AirportIgnoreArea = 1, - OceanArea = 2, - LakeArea = 3, - DryLakeArea = 4, - IntLakeArea = 5, - ReservoirArea = 6, - IntReservoirArea = 7, - StreamArea = 8, - CanalArea = 9, - GlacierArea = 10, - MarshArea = 11, + DefaultArea = 0, + AirportKeepArea = 1, + AirportIgnoreArea = 2, + OceanArea = 3, + LakeArea = 4, + DryLakeArea = 5, + IntLakeArea = 6, + ReservoirArea = 7, + IntReservoirArea = 8, + StreamArea = 9, + CanalArea = 10, + GlacierArea = 11, + MarshArea = 12, VoidArea = 9997, NullArea = 9998, UnknownArea = 9999 @@ -59,6 +67,10 @@ string get_area_name( AreaType area ); // $Log$ +// Revision 1.5 1999/03/27 05:31:25 curt +// Make 0 the default area type since this corresponds well with the conventions +// used by the triangulator. +// // Revision 1.4 1999/03/22 23:49:30 curt // Moved AreaType get_shapefile_type(GDBFile *dbf, int rec) to where it // belongs in ShapeFile/ -- 2.39.5