Revision 44617 trunk/org.gvsig.desktop/org.gvsig.desktop.compat.cdc/org.gvsig.fmap.geometry/org.gvsig.fmap.geometry.jts/src/main/java/org/gvsig/fmap/geom/jts/primitive/curve/line/BaseLine2DM.java
BaseLine2DM.java | ||
---|---|---|
40 | 40 |
import org.gvsig.fmap.geom.jts.primitive.surface.polygon.Polygon2DM; |
41 | 41 |
import org.gvsig.fmap.geom.jts.util.ArrayListCoordinateSequence; |
42 | 42 |
import org.gvsig.fmap.geom.jts.util.ReadOnlyCoordinates; |
43 |
import org.gvsig.fmap.geom.primitive.OrientablePrimitive; |
|
43 | 44 |
import org.gvsig.fmap.geom.primitive.Point; |
44 | 45 |
|
45 | 46 |
|
... | ... | |
80 | 81 |
this.coordinates = new ArrayListCoordinateSequence(new ReadOnlyCoordinates(coordinates)); |
81 | 82 |
} |
82 | 83 |
|
83 |
|
|
84 |
|
|
85 |
/* (non-Javadoc) |
|
86 |
* @see org.gvsig.fmap.geom.primitive.OrientablePrimitive#addVertex(double, double) |
|
87 |
*/ |
|
88 |
public void addVertex(double x, double y) { |
|
89 |
this.addVertex(new Point2DM(x, y, 0)); |
|
84 |
public OrientablePrimitive addVertex(double x, double y) { |
|
85 |
return this.addVertex(new Point2DM(x, y, 0)); |
|
90 | 86 |
} |
91 | 87 |
|
92 |
/* (non-Javadoc) |
|
93 |
* @see org.gvsig.fmap.geom.primitive.OrientablePrimitive#addVertex(double, double, double) |
|
94 |
*/ |
|
95 |
public void addVertex(double x, double y, double z) { |
|
88 |
public OrientablePrimitive addVertex(double x, double y, double z) { |
|
96 | 89 |
String message = "Can't add x,y,z coordinate to Polygon2DM."; |
97 | 90 |
notifyDeprecated(message); |
98 | 91 |
throw new UnsupportedOperationException(message); |
... | ... | |
167 | 160 |
* @see org.gvsig.fmap.geom.jts.primitive.curve.line.AbstractLine#setCoordinateAt(int, int, double) |
168 | 161 |
*/ |
169 | 162 |
@Override |
170 |
public void setCoordinateAt(int index, int dimension, double value) {
|
|
163 |
public OrientablePrimitive setCoordinateAt(int index, int dimension, double value) {
|
|
171 | 164 |
if (dimension == 2) { |
172 |
super.setCoordinateAt(index, CoordinateSequence.M, value); |
|
173 |
return; |
|
165 |
return super.setCoordinateAt(index, CoordinateSequence.M, value); |
|
174 | 166 |
} |
175 |
super.setCoordinateAt(index, dimension, value); |
|
167 |
return super.setCoordinateAt(index, dimension, value);
|
|
176 | 168 |
} |
177 | 169 |
} |
Also available in: Unified diff