annotate src/java/de/intevation/mxd/reader/MarkerSymbolReader.java @ 149:07e2033dd60e

Merged with Stephans commit.
author Raimund Renkert <rrenkert@intevation.de>
date Wed, 29 Jun 2011 17:59:52 +0200
parents fb93f20478cc
children f4eb506499f5
rev   line source
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
1 package de.intevation.mxd.reader;
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
2
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
3 import java.lang.Exception;
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
4
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
5 import org.w3c.dom.Element;
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
6
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
7 import org.apache.log4j.Logger;
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
8
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
9 import com.esri.arcgis.display.ISymbol;
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
10 import com.esri.arcgis.display.IMarkerSymbol;
71
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
11 import com.esri.arcgis.display.SimpleMarkerSymbol;
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
12 import com.esri.arcgis.display.ArrowMarkerSymbol;
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
13 import com.esri.arcgis.display.CharacterMarkerSymbol;
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
14 import com.esri.arcgis.display.PictureMarkerSymbol;
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
15 import com.esri.arcgis.display.MultiLayerMarkerSymbol;
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
16
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
17 /**
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
18 * Wrapper for marker symbol reader.
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
19 *
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
20 * @author <a href="mailto:raimund.renkert@intevation.de">Raimund Renkert</a>
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
21 */
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
22 public class MarkerSymbolReader
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
23 extends AbstractSymbolReader {
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
24
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
25 /**
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
26 * The logger.
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
27 */
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
28 private static final Logger logger =
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
29 Logger.getLogger(MarkerSymbolReader.class);
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
30
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
31 private ISymbol symbol;
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
32 private IMarkerSymbol markerSymbol;
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
33
71
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
34 public MarkerSymbolReader(ISymbol symbol)
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
35 throws Exception {
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
36 logger.debug("contructor(ISymbol)");
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
37 this.symbol = symbol;
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
38 this.markerSymbol = null;
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
39 }
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
40
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
41 public MarkerSymbolReader(IMarkerSymbol symbol)
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
42 throws Exception {
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
43 logger.debug("contructor(ISymbol)");
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
44 this.markerSymbol = symbol;
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
45 this.symbol = null;
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
46 }
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
47
71
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
48 public MarkerSymbolReader() {
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
49 logger.debug("contructor()");
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
50 this.symbol = null;
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
51 this.markerSymbol = null;
71
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
52 }
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
53
115
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
54 public Element read() {
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
55 logger.debug("read()");
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
56 ISymbolReader sreader = null;
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
57
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
58 if(symbol != null) {
115
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
59 try {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
60 if(symbol instanceof SimpleMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
61 sreader = new SimpleMarkerSymbolReader(symbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
62 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
63 else if(symbol instanceof ArrowMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
64 sreader = new ArrowMarkerSymbolReader(symbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
65 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
66 else if(symbol instanceof CharacterMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
67 sreader = new CharacterMarkerSymbolReader(symbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
68 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
69 else if(symbol instanceof PictureMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
70 sreader = new PictureMarkerSymbolReader(symbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
71 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
72 else if(symbol instanceof MultiLayerMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
73 sreader = new MultiLayerMarkerSymbolReader(symbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
74 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
75 else {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
76 logger.debug("The reader for type " + symbol.getClass().toString() +
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
77 " is not implemented!");
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
78 return parent;
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
79 }
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
80 }
115
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
81 catch(Exception e) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
82 logger.error(
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
83 "Could not read the symbol " +
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
84 symbol.getClass().toString());
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
85 return parent;
115
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
86
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
87 }
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
88 }
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
89 else if(markerSymbol != null) {
115
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
90 try {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
91 if(markerSymbol instanceof SimpleMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
92 sreader = new SimpleMarkerSymbolReader(markerSymbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
93 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
94 else if(markerSymbol instanceof ArrowMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
95 sreader = new ArrowMarkerSymbolReader(markerSymbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
96 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
97 else if(markerSymbol instanceof CharacterMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
98 sreader = new CharacterMarkerSymbolReader(markerSymbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
99 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
100 else if(markerSymbol instanceof PictureMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
101 sreader = new PictureMarkerSymbolReader(markerSymbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
102 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
103 else if(markerSymbol instanceof MultiLayerMarkerSymbol) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
104 sreader = new MultiLayerMarkerSymbolReader(markerSymbol);
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
105 }
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
106 else {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
107 logger.debug("The reader for type " + symbol.getClass().toString() +
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
108 " is not implemented!");
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
109 return parent;
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
110 }
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
111 }
115
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
112 catch(Exception e) {
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
113 logger.error(
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
114 "Could not read the symbol " +
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
115 symbol.getClass().toString());
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
116 return parent;
115
fb93f20478cc Improved exception handling for symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 75
diff changeset
117
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
118 }
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
119 }
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
120 if (sreader != null) {
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
121 sreader.setParent(parent);
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
122 sreader.setUtil(util);
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
123 sreader.read();
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
124 }
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
125 return parent;
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
126 }
71
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
127
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
128 public void setSymbol(ISymbol sym) {
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
129 this.symbol = sym;
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
130 this.markerSymbol = null;
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
131 }
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
132
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
133 public void setSymbol(IMarkerSymbol sym) {
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
134 this.markerSymbol = sym;
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
135 this.symbol = null;
71
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
136 }
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
137
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
138 public boolean canRead(ISymbol sym) {
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
139 if(sym instanceof SimpleMarkerSymbol ||
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
140 sym instanceof ArrowMarkerSymbol ||
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
141 sym instanceof PictureMarkerSymbol ||
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
142 sym instanceof CharacterMarkerSymbol ||
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
143 sym instanceof MultiLayerMarkerSymbol) {
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
144 return true;
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
145 }
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
146 else {
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
147 return false;
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
148 }
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
149 }
260748e3d08f Added wrapper for line symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 70
diff changeset
150
75
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
151 public boolean canRead(IMarkerSymbol sym) {
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
152 if(sym instanceof SimpleMarkerSymbol ||
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
153 sym instanceof ArrowMarkerSymbol ||
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
154 sym instanceof PictureMarkerSymbol ||
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
155 sym instanceof CharacterMarkerSymbol ||
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
156 sym instanceof MultiLayerMarkerSymbol) {
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
157 return true;
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
158 }
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
159 else {
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
160 return false;
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
161 }
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
162 }
9ea64427ac7e Added marker fill symbol reader.
Raimund Renkert <rrenkert@intevation.de>
parents: 74
diff changeset
163
70
6d181c02efce Added wrapper for marker symbol reader and extracted methods from symbol
Raimund Renkert <rrenkert@intevation.de>
parents:
diff changeset
164 }
This site is hosted by Intevation GmbH (Datenschutzerklärung und Impressum | Privacy Policy and Imprint)