Skip to content

Commit

Permalink
deegree#1124 (#8363) - upgrade to PostGIS 2.5.1
Browse files Browse the repository at this point in the history
  • Loading branch information
lgoltz committed Jun 30, 2022
1 parent fd8164d commit 9224bf4
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,27 +35,27 @@
----------------------------------------------------------------------------*/
package org.deegree.geometry.io;

import java.io.IOException;
import java.io.Reader;
import java.sql.SQLException;

import org.apache.commons.io.IOUtils;
import org.deegree.cs.coordinatesystems.ICRS;
import org.deegree.geometry.Geometry;
import org.locationtech.jts.io.ParseException;
import org.postgis.GeometryBuilder;
import org.postgis.binary.BinaryWriter;

import org.locationtech.jts.io.ParseException;
import java.io.IOException;
import java.io.Reader;
import java.sql.SQLException;

/**
* Reads {@link Geometry} objects encoded as Well-Known Text (WKT).
*
*
* TODO re-implement without delegating to JTS TODO add support for non-SFS geometries (e.g. non-linear curves) TODO
* TODO TODO do not go about using PostGIS for parsing the WKT, generate WKB and then parse it back using JTS TODO TODO
* TODO repeat after me s/TODO/TODO TODO/g
*
*
* @author <a href="mailto:schneider@lat-lon.de">Markus Schneider</a>
* @author last edited by: $Author$
*
*
* @version $Revision$, $Date$
*/
public class WKTReader {
Expand All @@ -79,7 +79,7 @@ public Geometry read( Reader reader )
public Geometry read( String wkt )
throws ParseException {
try {
org.postgis.Geometry g = org.postgis.PGgeometry.geomFromString( wkt );
org.postgis.Geometry g = GeometryBuilder.geomFromString( wkt );
byte[] bs = new BinaryWriter().writeBinary( g );
return WKBReader.read( bs, crs );
} catch ( SQLException e ) {
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -807,7 +807,7 @@
<dependency>
<groupId>net.postgis</groupId>
<artifactId>postgis-jdbc</artifactId>
<version>2.3.0</version>
<version>2.5.1</version>
</dependency>
<dependency>
<groupId>org.postgresql</groupId>
Expand Down

0 comments on commit 9224bf4

Please sign in to comment.