NormalizeGeometry implements GeometryOperator { @Override public Geometry apply(Geometry geometry, Context context) { LOGGER.debug("normalizing geometry object"); return geometry == null ? null : geometry.norm(); }  @Override Geometry apply(Geometry geometry, Context context); @Override String toString();  }
@Test public void testApply() throws ParseException { Geometry geometry = new WKTReader().read("LINESTRING( 0 0, 1 1, 2 2)"); Geometry normalizedGeometry = geometry.norm(); assertThat( normalizeGeometry.apply(geometry, new GeometryOperator.Context()), is(normalizedGeometry)); }