Mercurial > mxd2map
comparison src/java/de/intevation/mxd/reader/MultiLayerFillSymbolReader.java @ 79:5becdfe6ebae
merged with raimunds stuff
author | Stephan Holl <stephan.holl@intevation.de> |
---|---|
date | Fri, 27 May 2011 12:54:55 +0200 |
parents | 9ea64427ac7e |
children | 83932f18dddc |
comparison
equal
deleted
inserted
replaced
78:df17d4c2f9eb | 79:5becdfe6ebae |
---|---|
85 * Reads the symbol attributes. | 85 * Reads the symbol attributes. |
86 * | 86 * |
87 * @return The XML node. | 87 * @return The XML node. |
88 */ | 88 */ |
89 public Element read() | 89 public Element read() |
90 throws IOException { | 90 throws Exception { |
91 logger.debug("read()"); | 91 logger.debug("read()"); |
92 for(int i = 0; i < symbol.getLayerCount(); i++) { | 92 for(int i = 0; i < symbol.getLayerCount(); i++) { |
93 try { | 93 ISymbol sym = (ISymbol)symbol.getLayer(i); |
94 ISymbol sym = (ISymbol)symbol.getLayer(i); | |
95 | 94 |
96 if(sym instanceof SimpleFillSymbol) { | 95 FillSymbolReader fsr = new FillSymbolReader(); |
97 ISymbolReader sreader = new SimpleFillSymbolReader(sym); | 96 if(fsr.canRead(sym)) { |
98 sreader.setParent(renderer); | 97 fsr.setSymbol(sym); |
99 sreader.setUtil(util); | 98 fsr.setParent(renderer); |
100 sreader.read(); | 99 fsr.setUtil(util); |
101 } | 100 fsr.read(); |
102 else { | |
103 logger.debug("The type of " + sym.getClass().toString() + | |
104 " is not implemented!"); | |
105 } | |
106 } | 101 } |
107 catch(Exception e) { | 102 else { |
108 e.printStackTrace(); | 103 logger.debug("The type of " + sym.getClass().toString() + |
109 return null; | 104 " is not implemented!"); |
110 } | 105 } |
111 } | 106 } |
112 return renderer; | 107 return renderer; |
113 } | 108 } |
114 } | 109 } |