Class GeometryUtils


  • public class GeometryUtils
    extends Object
    Utility methods for the geometry.
    • Field Detail

      • GEOGRAPHY_SRID

        public static final int GEOGRAPHY_SRID
        Coordinate system of lat/lng per https://epsg.io/4326
        See Also:
        Constant Field Values
      • GEOMETRY_FACTORY

        public static final org.locationtech.jts.geom.GeometryFactory GEOMETRY_FACTORY
      • GEOGRAPHY_FACTORY

        public static final org.locationtech.jts.geom.GeometryFactory GEOGRAPHY_FACTORY
      • GEOMETRY_WKT_READER

        public static final org.locationtech.jts.io.WKTReader GEOMETRY_WKT_READER
      • GEOGRAPHY_WKT_READER

        public static final org.locationtech.jts.io.WKTReader GEOGRAPHY_WKT_READER
      • GEOMETRY_WKB_READER

        public static final org.locationtech.jts.io.WKBReader GEOMETRY_WKB_READER
      • GEOGRAPHY_WKB_READER

        public static final org.locationtech.jts.io.WKBReader GEOGRAPHY_WKB_READER
      • WKT_WRITER

        public static final org.locationtech.jts.io.WKTWriter WKT_WRITER
      • WKB_WRITER

        public static final org.locationtech.jts.io.WKBWriter WKB_WRITER
      • OR_JOINER

        public static final com.google.common.base.Joiner OR_JOINER
      • EMPTY_POINT

        public static final org.locationtech.jts.geom.Geometry EMPTY_POINT
    • Method Detail

      • isGeography

        public static boolean isGeography​(org.locationtech.jts.geom.Geometry geometry)
        Checks if the given geo-spatial object is a geography object.
        Parameters:
        geometry - the given object to check
        Returns:
        true if the given geo-spatial object is a geography object, false otherwise
      • setGeography

        public static void setGeography​(org.locationtech.jts.geom.Geometry geometry)
        Sets the geometry to geography.
        Parameters:
        geometry - the geometry to set
      • setGeometry

        public static void setGeometry​(org.locationtech.jts.geom.Geometry geometry)
        Sets to geometry.
        Parameters:
        geometry - the geometry to set