Mercurial > mxd2map
comparison src/java/de/intevation/mxd/writer/MapScriptWriter.java @ 107:196abb30c0d2
another merge with raimund
author | Stephan Holl <stephan.holl@intevation.de> |
---|---|
date | Tue, 07 Jun 2011 15:52:45 +0200 |
parents | d6d2a4058ebf |
children | 3ca2ec55fb3b |
comparison
equal
deleted
inserted
replaced
106:609c234e8e23 | 107:196abb30c0d2 |
---|---|
207 //Create all found class objects and write the symbols and styles for | 207 //Create all found class objects and write the symbols and styles for |
208 //each class. | 208 //each class. |
209 for(int i = 0; i < list.getLength(); i++) { | 209 for(int i = 0; i < list.getLength(); i++) { |
210 Element classElement = (Element)list.item(i); | 210 Element classElement = (Element)list.item(i); |
211 classObj co = new classObj(layer); | 211 classObj co = new classObj(layer); |
212 co.setName(classElement.getAttribute("name")); | 212 String name = classElement.getAttribute("name"); |
213 if (name.equals("")) { | |
214 name = layerElement.getAttribute("name"); | |
215 if (list.getLength() > 1) { | |
216 name += "-" + i; | |
217 } | |
218 } | |
219 co.setName (name); | |
213 if(classElement.hasAttribute("field_count")) { | 220 if(classElement.hasAttribute("field_count")) { |
214 int count = | 221 int count = |
215 Integer.parseInt(classElement.getAttribute("field_count")); | 222 Integer.parseInt(classElement.getAttribute("field_count")); |
216 String exp = ""; | 223 String exp = ""; |
217 for(int j = 0; j < count; j++) { | 224 for(int j = 0; j < count; j++) { |