Class Constructors

java.lang.Object
org.apache.sedona.common.Constructors

public class Constructors extends Object
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static org.locationtech.jts.geom.Geometry
    geomCollFromText(String wkt, int srid)
     
    static org.locationtech.jts.geom.Geometry
     
    static org.locationtech.jts.geom.Geometry
    geomFromGeoHash(String geoHash, Integer precision)
     
    static org.locationtech.jts.geom.Geometry
     
    static org.locationtech.jts.geom.Geometry
     
    static org.locationtech.jts.geom.Geometry
    geomFromMySQL(byte[] binary)
     
    static org.locationtech.jts.geom.Geometry
    geomFromText(String geomString, String geomFormat, GeometryType geometryType)
     
    static org.locationtech.jts.geom.Geometry
    geomFromText(String geomString, FileDataSplitter fileDataSplitter)
     
    static org.locationtech.jts.geom.Geometry
    geomFromWKB(byte[] wkb)
     
    static org.locationtech.jts.geom.Geometry
    geomFromWKB(byte[] wkb, int SRID)
     
    static org.locationtech.jts.geom.Geometry
    geomFromWKT(String wkt, int srid)
     
    static org.locationtech.jts.geom.Geometry
    lineFromText(String geomString)
     
    static org.locationtech.jts.geom.Geometry
    lineFromWKB(byte[] wkb)
     
    static org.locationtech.jts.geom.Geometry
    lineFromWKB(byte[] wkb, int srid)
     
    static org.locationtech.jts.geom.Geometry
    lineStringFromText(String geomString, String geomFormat)
     
    static org.locationtech.jts.geom.Geometry
    makeEnvelope(double minX, double minY, double maxX, double maxY)
     
    static org.locationtech.jts.geom.Geometry
    makeEnvelope(double minX, double minY, double maxX, double maxY, int srid)
     
    static org.locationtech.jts.geom.Geometry
     
    static org.locationtech.jts.geom.Geometry
    makePointM(double x, double y, double m)
     
    static org.locationtech.jts.geom.Geometry
    mLineFromText(String wkt, int srid)
     
    static org.locationtech.jts.geom.Geometry
    mPointFromText(String wkt, int srid)
     
    static org.locationtech.jts.geom.Geometry
    mPolyFromText(String wkt, int srid)
     
    static org.locationtech.jts.geom.Geometry
    point(double x, double y)
    Creates a point from the given coordinate.
    static org.locationtech.jts.geom.Geometry
    pointFromGeoHash(String geoHash, Integer precision)
     
    static org.locationtech.jts.geom.Geometry
    pointFromText(String geomString, String geomFormat)
     
    static org.locationtech.jts.geom.Geometry
    pointFromWKB(byte[] wkb)
     
    static org.locationtech.jts.geom.Geometry
    pointFromWKB(byte[] wkb, int srid)
     
    static org.locationtech.jts.geom.Geometry
    pointM(double x, double y, double m, int srid)
    Creates a point from the given coordinate.
    static org.locationtech.jts.geom.Geometry
    pointZ(double x, double y, double z, int srid)
    Creates a point from the given coordinate.
    static org.locationtech.jts.geom.Geometry
    pointZM(double x, double y, double z, double m, int srid)
    Creates a point from the given coordinate.
    static org.locationtech.jts.geom.Geometry
    polygonFromEnvelope(double minX, double minY, double maxX, double maxY)
     
    static org.locationtech.jts.geom.Geometry
    polygonFromText(String geomString, String geomFormat)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Constructors

      public Constructors()
  • Method Details

    • geomFromWKT

      public static org.locationtech.jts.geom.Geometry geomFromWKT(String wkt, int srid) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • geomFromEWKT

      public static org.locationtech.jts.geom.Geometry geomFromEWKT(String ewkt) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • geomFromWKB

      public static org.locationtech.jts.geom.Geometry geomFromWKB(byte[] wkb) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • geomFromWKB

      public static org.locationtech.jts.geom.Geometry geomFromWKB(byte[] wkb, int SRID) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • pointFromWKB

      public static org.locationtech.jts.geom.Geometry pointFromWKB(byte[] wkb) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • pointFromWKB

      public static org.locationtech.jts.geom.Geometry pointFromWKB(byte[] wkb, int srid) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • lineFromWKB

      public static org.locationtech.jts.geom.Geometry lineFromWKB(byte[] wkb) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • lineFromWKB

      public static org.locationtech.jts.geom.Geometry lineFromWKB(byte[] wkb, int srid) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • mPointFromText

      public static org.locationtech.jts.geom.Geometry mPointFromText(String wkt, int srid) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • mLineFromText

      public static org.locationtech.jts.geom.Geometry mLineFromText(String wkt, int srid) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • mPolyFromText

      public static org.locationtech.jts.geom.Geometry mPolyFromText(String wkt, int srid) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • geomCollFromText

      public static org.locationtech.jts.geom.Geometry geomCollFromText(String wkt, int srid) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • point

      public static org.locationtech.jts.geom.Geometry point(double x, double y)
      Creates a point from the given coordinate. ST_Point in Sedona Spark API took an optional z value before v1.4.0. This was removed to avoid confusion with other GIS implementations where the optional third argument is srid.

      A future version of Sedona will add a srid parameter once enough users have upgraded and hence are forced to use ST_PointZ for 3D points.

      Parameters:
      x - the x value
      y - the y value
      Returns:
      The point geometry
    • makePointM

      public static org.locationtech.jts.geom.Geometry makePointM(double x, double y, double m)
    • makePoint

      public static org.locationtech.jts.geom.Geometry makePoint(Double x, Double y, Double z, Double m)
    • pointZ

      public static org.locationtech.jts.geom.Geometry pointZ(double x, double y, double z, int srid)
      Creates a point from the given coordinate.
      Parameters:
      x - the x value
      y - the y value
      z - the z value
      srid - Set to 0 if unknown
      Returns:
      The point geometry
    • pointM

      public static org.locationtech.jts.geom.Geometry pointM(double x, double y, double m, int srid)
      Creates a point from the given coordinate.
      Parameters:
      x - the x value
      y - the y value
      m - the m value
      srid - Set to 0 if unknown
      Returns:
      The point geometry
    • pointZM

      public static org.locationtech.jts.geom.Geometry pointZM(double x, double y, double z, double m, int srid)
      Creates a point from the given coordinate.
      Parameters:
      x - the x value
      y - the y value
      z - the z value
      m - the m value
      srid - Set to 0 if unknown
      Returns:
      The point geometry
    • geomFromText

      public static org.locationtech.jts.geom.Geometry geomFromText(String geomString, String geomFormat, GeometryType geometryType)
    • geomFromText

      public static org.locationtech.jts.geom.Geometry geomFromText(String geomString, FileDataSplitter fileDataSplitter)
    • pointFromText

      public static org.locationtech.jts.geom.Geometry pointFromText(String geomString, String geomFormat)
    • polygonFromText

      public static org.locationtech.jts.geom.Geometry polygonFromText(String geomString, String geomFormat)
    • lineStringFromText

      public static org.locationtech.jts.geom.Geometry lineStringFromText(String geomString, String geomFormat)
    • lineFromText

      public static org.locationtech.jts.geom.Geometry lineFromText(String geomString)
    • polygonFromEnvelope

      public static org.locationtech.jts.geom.Geometry polygonFromEnvelope(double minX, double minY, double maxX, double maxY)
    • makeEnvelope

      public static org.locationtech.jts.geom.Geometry makeEnvelope(double minX, double minY, double maxX, double maxY, int srid)
    • makeEnvelope

      public static org.locationtech.jts.geom.Geometry makeEnvelope(double minX, double minY, double maxX, double maxY)
    • geomFromGeoHash

      public static org.locationtech.jts.geom.Geometry geomFromGeoHash(String geoHash, Integer precision)
    • pointFromGeoHash

      public static org.locationtech.jts.geom.Geometry pointFromGeoHash(String geoHash, Integer precision)
    • geomFromGML

      public static org.locationtech.jts.geom.Geometry geomFromGML(String gml) throws IOException, ParserConfigurationException, SAXException
      Throws:
      IOException
      ParserConfigurationException
      SAXException
    • geomFromKML

      public static org.locationtech.jts.geom.Geometry geomFromKML(String kml) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException
    • geomFromMySQL

      public static org.locationtech.jts.geom.Geometry geomFromMySQL(byte[] binary) throws org.locationtech.jts.io.ParseException
      Throws:
      org.locationtech.jts.io.ParseException