use of com.revolsys.geometry.model.editor.PolygonalEditor in project com.revolsys.open by revolsys.
the class Polygonal method newGeometryEditor.
@Override
default PolygonalEditor newGeometryEditor(final int axisCount) {
final PolygonalEditor geometryEditor = newGeometryEditor();
geometryEditor.setAxisCount(axisCount);
return geometryEditor;
}
use of com.revolsys.geometry.model.editor.PolygonalEditor in project com.revolsys.open by revolsys.
the class MultiPolygonEditorTest method testSetM.
@Test
public void testSetM() {
final PolygonalEditor editor = POLYGONAL.newGeometryEditor(4);
editor.setM(1, 1, 1, 10);
final Polygonal newGeometry = editor.newGeometry();
Assert.assertNotSame(POLYGONAL, newGeometry);
Assert.assertEquals(10.0, newGeometry.getM(1, 1, 1), 0.0);
}
use of com.revolsys.geometry.model.editor.PolygonalEditor in project com.revolsys.open by revolsys.
the class MultiPolygonEditorTest method testSetCoordinates.
@Test
public void testSetCoordinates() {
for (int i = 0; i < 4; i++) {
final PolygonalEditor editor = POLYGONAL.newGeometryEditor(4);
final double newValue = POLYGONAL.getCoordinate(1, 1, 1, i);
editor.setCoordinate(1, 1, 1, i, newValue);
final Polygonal newGeometry = editor.newGeometry();
Assert.assertNotSame(POLYGONAL, newGeometry);
Assert.assertEquals(newValue, newGeometry.getCoordinate(1, 1, 1, i), 0.0);
}
}
use of com.revolsys.geometry.model.editor.PolygonalEditor in project com.revolsys.open by revolsys.
the class MultiPolygonEditorTest method testSetZ.
@Test
public void testSetZ() {
final PolygonalEditor editor = POLYGONAL.newGeometryEditor(3);
editor.setZ(1, 1, 1, 10);
final Polygonal newGeometry = editor.newGeometry();
Assert.assertNotSame(POLYGONAL, newGeometry);
Assert.assertEquals(10.0, newGeometry.getZ(1, 1, 1), 0.0);
}
use of com.revolsys.geometry.model.editor.PolygonalEditor in project com.revolsys.open by revolsys.
the class MultiPolygonEditorTest method testSetX.
@Test
public void testSetX() {
final PolygonalEditor editor = POLYGONAL.newGeometryEditor(3);
editor.setX(1, 1, 1, 10);
final Polygonal newGeometry = editor.newGeometry();
Assert.assertNotSame(POLYGONAL, newGeometry);
Assert.assertEquals(10.0, newGeometry.getX(1, 1, 1), 0.0);
}
Aggregations