diff src/java/de/intevation/mxd/reader/MapReader.java @ 57:8da6555f1c12

Set the projection "EPSG:31467" and units "METERS" as default values.
author Raimund Renkert <rrenkert@intevation.de>
date Tue, 17 May 2011 13:00:10 +0200
parents ef7ca23c4233
children 9f74f4d36822
line wrap: on
line diff
--- a/src/java/de/intevation/mxd/reader/MapReader.java	Tue May 17 11:55:03 2011 +0200
+++ b/src/java/de/intevation/mxd/reader/MapReader.java	Tue May 17 13:00:10 2011 +0200
@@ -95,7 +95,7 @@
             case   5: s_units = "miles"; break;
             case   6: s_units = "nauticalmiles"; break;
             case   2: s_units = "points"; break;
-            default : s_units = "not supported"; break;
+            default : s_units = "meters"; break;
         }
         mapElement.setAttribute("units", s_units);
 
@@ -117,7 +117,12 @@
         }
         else if(sr instanceof UnknownCoordinateSystem) {
             UnknownCoordinateSystem ucs = (UnknownCoordinateSystem)sr;
-            mapElement.setAttribute("projection", sr.getName());
+            if (sr.getName().equals("Unknown")) {
+                mapElement.setAttribute ("projection", "EPSG:31467");
+            }
+            else {
+                mapElement.setAttribute("projection", sr.getName());
+            }
         }
         else{
             throw new IOException("Unknown SpatialReference: " +
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)