private String convertToWKT(Geometry g, boolean isFormatted) { if (g == null) return ""; if (!isFormatted) return g.toString(); WKTWriter writer = new WKTWriter(); writer.setFormatted(isFormatted); writer.setMaxCoordinatesPerLine(5); return writer.write(g); }
public String getWellKnownText(int i) { if (geom[i] == null) { return null; } return wktWriter.write(geom[i]); }