Class GeometryProcessor


  • public final class GeometryProcessor
    extends Object
    Utility functions on feature geometries.
    Since:
    0.1
    Author:
    mprins
    • Method Detail

      • processGeometry

        @NotNull
        public static @NotNull String processGeometry​(Object geometry,
                                                      @NotNull
                                                      @NotNull Boolean simplifyGeometry,
                                                      @NotNull
                                                      @NotNull Boolean linearizeGeomToWKT,
                                                      org.geotools.api.referencing.operation.MathTransform transform)
        process the geometry into a (optionally simplified) string representation.
        Parameters:
        geometry - An object representing a geometry
        simplifyGeometry - set to true to simplify
        transform - the transformation that should be applied to the geometry, can be null
        Returns:
        the string representation of the argument - normally WKT, optionally simplified or null when the given geometry was null
      • transformGeometry

        public static org.locationtech.jts.geom.Geometry transformGeometry​(@NotNull
                                                                           @NotNull org.locationtech.jts.geom.Geometry geometry,
                                                                           org.geotools.api.referencing.operation.MathTransform transform)
      • geometryToJson

        public static String geometryToJson​(org.locationtech.jts.geom.Geometry geom)
      • geometryToWKT

        public static String geometryToWKT​(@NotNull
                                           @NotNull org.locationtech.jts.geom.Geometry geom)
      • wktToGeometry

        public static org.locationtech.jts.geom.Geometry wktToGeometry​(String wkt)