diff -Nru postgis-java-2.2.1/debian/changelog postgis-java-2.3.0/debian/changelog --- postgis-java-2.2.1/debian/changelog 2018-10-14 07:35:25.000000000 +0000 +++ postgis-java-2.3.0/debian/changelog 2018-11-25 08:45:20.000000000 +0000 @@ -1,3 +1,12 @@ +postgis-java (1:2.3.0-1) unstable; urgency=medium + + * New upstream release. + * Update copyright years for Phillip Ross. + * Refresh patches. + * Strip trailing slash from Vcs-Browser URL. + + -- Bas Couwenberg Sun, 25 Nov 2018 09:45:20 +0100 + postgis-java (1:2.2.1-9) unstable; urgency=medium * Bump Standards-Version to 4.2.1, no changes. diff -Nru postgis-java-2.2.1/debian/control postgis-java-2.3.0/debian/control --- postgis-java-2.2.1/debian/control 2018-10-11 19:52:22.000000000 +0000 +++ postgis-java-2.3.0/debian/control 2018-11-25 08:44:49.000000000 +0000 @@ -12,7 +12,7 @@ maven-repo-helper, maven Standards-Version: 4.2.1 -Vcs-Browser: https://salsa.debian.org/debian-gis-team/postgis-java/ +Vcs-Browser: https://salsa.debian.org/debian-gis-team/postgis-java Vcs-Git: https://salsa.debian.org/debian-gis-team/postgis-java.git Homepage: https://github.com/postgis/postgis-java diff -Nru postgis-java-2.2.1/debian/copyright postgis-java-2.3.0/debian/copyright --- postgis-java-2.2.1/debian/copyright 2018-06-20 18:06:35.000000000 +0000 +++ postgis-java-2.3.0/debian/copyright 2018-11-25 08:35:03.000000000 +0000 @@ -6,7 +6,7 @@ Files: * Copyright: 2004, Paul Ramsey 2005, Markus Schaber - 2015, Phillip Ross + 2015, 2017, Phillip Ross License: LGPL-2.1+ Files: debian/* diff -Nru postgis-java-2.2.1/debian/patches/driverwrapper.patch postgis-java-2.3.0/debian/patches/driverwrapper.patch --- postgis-java-2.2.1/debian/patches/driverwrapper.patch 2018-06-20 18:08:14.000000000 +0000 +++ postgis-java-2.3.0/debian/patches/driverwrapper.patch 2018-11-25 08:41:15.000000000 +0000 @@ -1,10 +1,11 @@ Description: libpostgresql-jdbc-java 42.2.2 doesn't thow exception any more. Author: Bas Couwenberg Forwarded: https://github.com/postgis/postgis-java/pull/60 +Applied-Upstream: https://github.com/postgis/postgis-java/commit/d71e4fad18952ba01a2c0a8dd3f6ec5d106368b0 --- a/jdbc/src/main/java/org/postgis/DriverWrapper.java +++ b/jdbc/src/main/java/org/postgis/DriverWrapper.java -@@ -333,7 +333,7 @@ public class DriverWrapper extends Drive +@@ -339,7 +339,7 @@ public class DriverWrapper extends Drive } } @@ -19,8 +20,8 @@ org.postgresql postgresql -- [9.4.1208.jre7,) -+ [42.2.2.jre7,) +- 9.4.1208.jre7 ++ 42.2.2.jre7 diff -Nru postgis-java-2.2.1/debian/patches/upstream-version.patch postgis-java-2.3.0/debian/patches/upstream-version.patch --- postgis-java-2.2.1/debian/patches/upstream-version.patch 2018-06-20 18:08:33.000000000 +0000 +++ postgis-java-2.3.0/debian/patches/upstream-version.patch 2018-11-25 08:39:48.000000000 +0000 @@ -8,13 +8,13 @@ net.postgis postgis-java-aggregator -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 postgis-jdbc -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 jar Postgis JDBC Driver @@ -24,28 +24,37 @@ net.postgis postgis-java-aggregator -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 postgis-jdbc-jtsparser -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 jar Postgis JDBC Driver JTS Parser +@@ -27,7 +27,7 @@ + + net.postgis + postgis-jdbc +- 2.3.1-SNAPSHOT ++ 2.3.0 + + + org.locationtech.jts --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ net.postgis postgis-java-aggregator -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 pom PostGIS Java Project -@@ -371,4 +371,4 @@ +@@ -375,4 +375,4 @@ @@ -58,13 +67,13 @@ net.postgis postgis-java-aggregator -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 postgis-jdbc-java2d -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 jar postgis-jdbc-java2d @@ -72,8 +81,8 @@ net.postgis postgis-jdbc -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 @@ -83,13 +92,13 @@ tools net.postgis -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 osgeo-postgis-jdbc-test-util -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 jar osgeo-postgis-jdbc-test-util @@ -97,8 +106,8 @@ net.postgis postgis-jdbc -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 @@ -115,13 +124,13 @@ postgis-java-aggregator net.postgis -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 tools -- 2.2.2-SNAPSHOT -+ 2.2.1 +- 2.3.1-SNAPSHOT ++ 2.3.0 pom tools diff -Nru postgis-java-2.2.1/.gitignore postgis-java-2.3.0/.gitignore --- postgis-java-2.2.1/.gitignore 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.gitignore 2018-11-25 06:58:15.000000000 +0000 @@ -1,5 +1,134 @@ -# Created by .ignore support plugin (hsz.mobi) -.idea/misc.xml -.idea/uiDesigner.xml -.idea/workspace.xml -.idea/dictionaries \ No newline at end of file +.idea +### Linux template +*~ + +# temporary files which can be created if a process still has a handle open of a deleted file +.fuse_hidden* + +# KDE directory preferences +.directory + +# Linux trash folder which might appear on any partition or disk +.Trash-* + +# .nfs files are created when an open file is removed but is still being accessed +.nfs* +### Windows template +# Windows thumbnail cache files +Thumbs.db +ehthumbs.db +ehthumbs_vista.db + +# Dump file +*.stackdump + +# Folder config file +[Dd]esktop.ini + +# Recycle Bin used on file shares +$RECYCLE.BIN/ + +# Windows Installer files +*.cab +*.msi +*.msix +*.msm +*.msp + +# Windows shortcuts +*.lnk + +# CMake +cmake-build-debug/ +cmake-build-release/ + +# File-based project format +*.iws +*.iml + +# IntelliJ +out/ + +# mpeltonen/sbt-idea plugin +.idea_modules/ + +# JIRA plugin +atlassian-ide-plugin.xml + +### Vim template +# Swap +[._]*.s[a-v][a-z] +[._]*.sw[a-p] +[._]s[a-v][a-z] +[._]sw[a-p] + +# Session +Session.vim + +# Temporary +.netrwhist +# Auto-generated tag files +tags +### Maven template +target/ +pom.xml.tag +pom.xml.releaseBackup +pom.xml.versionsBackup +pom.xml.next +release.properties +dependency-reduced-pom.xml +buildNumber.properties +.mvn/timing.properties + +### macOS template +# General +.DS_Store +.AppleDouble +.LSOverride + +# Icon must end with two \r +Icon + +# Thumbnails +._* + +# Files that might appear in the root of a volume +.DocumentRevisions-V100 +.fseventsd +.Spotlight-V100 +.TemporaryItems +.Trashes +.VolumeIcon.icns +.com.apple.timemachine.donotpresent + +# Directories potentially created on remote AFP share +.AppleDB +.AppleDesktop +Network Trash Folder +Temporary Items +.apdisk +### Java template +# Compiled class file +*.class + +# Log file +*.log + +# BlueJ files +*.ctxt + +# Mobile Tools for Java (J2ME) +.mtj.tmp/ + +# Package Files # +*.jar +*.war +*.nar +*.ear +*.zip +*.tar.gz +*.rar + +# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml +hs_err_pid* + diff -Nru postgis-java-2.2.1/.idea/compiler.xml postgis-java-2.3.0/.idea/compiler.xml --- postgis-java-2.2.1/.idea/compiler.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/compiler.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,41 +0,0 @@ - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/copyright/profiles_settings.xml postgis-java-2.3.0/.idea/copyright/profiles_settings.xml --- postgis-java-2.2.1/.idea/copyright/profiles_settings.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/copyright/profiles_settings.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/encodings.xml postgis-java-2.3.0/.idea/encodings.xml --- postgis-java-2.2.1/.idea/encodings.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/encodings.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,12 +0,0 @@ - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/libraries/Maven__ch_qos_logback_logback_classic_1_1_7.xml postgis-java-2.3.0/.idea/libraries/Maven__ch_qos_logback_logback_classic_1_1_7.xml --- postgis-java-2.2.1/.idea/libraries/Maven__ch_qos_logback_logback_classic_1_1_7.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/libraries/Maven__ch_qos_logback_logback_classic_1_1_7.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/libraries/Maven__ch_qos_logback_logback_core_1_1_7.xml postgis-java-2.3.0/.idea/libraries/Maven__ch_qos_logback_logback_core_1_1_7.xml --- postgis-java-2.2.1/.idea/libraries/Maven__ch_qos_logback_logback_core_1_1_7.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/libraries/Maven__ch_qos_logback_logback_core_1_1_7.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/libraries/Maven__com_beust_jcommander_1_48.xml postgis-java-2.3.0/.idea/libraries/Maven__com_beust_jcommander_1_48.xml --- postgis-java-2.2.1/.idea/libraries/Maven__com_beust_jcommander_1_48.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/libraries/Maven__com_beust_jcommander_1_48.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/libraries/Maven__com_vividsolutions_jts_1_12.xml postgis-java-2.3.0/.idea/libraries/Maven__com_vividsolutions_jts_1_12.xml --- postgis-java-2.2.1/.idea/libraries/Maven__com_vividsolutions_jts_1_12.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/libraries/Maven__com_vividsolutions_jts_1_12.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/libraries/Maven__org_beanshell_bsh_2_0b4.xml postgis-java-2.3.0/.idea/libraries/Maven__org_beanshell_bsh_2_0b4.xml --- postgis-java-2.2.1/.idea/libraries/Maven__org_beanshell_bsh_2_0b4.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/libraries/Maven__org_beanshell_bsh_2_0b4.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/libraries/Maven__org_postgresql_postgresql_9_4_1209_jre7.xml postgis-java-2.3.0/.idea/libraries/Maven__org_postgresql_postgresql_9_4_1209_jre7.xml --- postgis-java-2.2.1/.idea/libraries/Maven__org_postgresql_postgresql_9_4_1209_jre7.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/libraries/Maven__org_postgresql_postgresql_9_4_1209_jre7.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/libraries/Maven__org_slf4j_slf4j_api_1_7_21.xml postgis-java-2.3.0/.idea/libraries/Maven__org_slf4j_slf4j_api_1_7_21.xml --- postgis-java-2.2.1/.idea/libraries/Maven__org_slf4j_slf4j_api_1_7_21.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/libraries/Maven__org_slf4j_slf4j_api_1_7_21.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/libraries/Maven__org_testng_testng_6_9_10.xml postgis-java-2.3.0/.idea/libraries/Maven__org_testng_testng_6_9_10.xml --- postgis-java-2.2.1/.idea/libraries/Maven__org_testng_testng_6_9_10.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/libraries/Maven__org_testng_testng_6_9_10.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/libraries/Maven__xerces_xercesImpl_2_4_0.xml postgis-java-2.3.0/.idea/libraries/Maven__xerces_xercesImpl_2_4_0.xml --- postgis-java-2.2.1/.idea/libraries/Maven__xerces_xercesImpl_2_4_0.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/libraries/Maven__xerces_xercesImpl_2_4_0.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/modules.xml postgis-java-2.3.0/.idea/modules.xml --- postgis-java-2.2.1/.idea/modules.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/modules.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,13 +0,0 @@ - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/.name postgis-java-2.3.0/.idea/.name --- postgis-java-2.2.1/.idea/.name 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/.name 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -postgis-aggregator \ No newline at end of file diff -Nru postgis-java-2.2.1/.idea/vcs.xml postgis-java-2.3.0/.idea/vcs.xml --- postgis-java-2.2.1/.idea/vcs.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/.idea/vcs.xml 1970-01-01 00:00:00.000000000 +0000 @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/jdbc/pom.xml postgis-java-2.3.0/jdbc/pom.xml --- postgis-java-2.2.1/jdbc/pom.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc/pom.xml 2018-11-25 06:58:15.000000000 +0000 @@ -5,11 +5,11 @@ net.postgis postgis-java-aggregator - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT postgis-jdbc - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT jar Postgis JDBC Driver @@ -27,7 +27,7 @@ org.postgresql postgresql - [9.4.1208.jre7,) + 9.4.1208.jre7 diff -Nru postgis-java-2.2.1/jdbc/postgis-jdbc.iml postgis-java-2.3.0/jdbc/postgis-jdbc.iml --- postgis-java-2.2.1/jdbc/postgis-jdbc.iml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc/postgis-jdbc.iml 1970-01-01 00:00:00.000000000 +0000 @@ -1,23 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/jdbc/src/main/java/org/postgis/DriverWrapper.java postgis-java-2.3.0/jdbc/src/main/java/org/postgis/DriverWrapper.java --- postgis-java-2.2.1/jdbc/src/main/java/org/postgis/DriverWrapper.java 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc/src/main/java/org/postgis/DriverWrapper.java 2018-11-25 06:58:15.000000000 +0000 @@ -281,6 +281,8 @@ public void addGeometries(Connection conn) throws SQLException { PGConnection pgconn = (PGConnection) conn; pgconn.addDataType("geometry", org.postgis.PGgeometry.class); + pgconn.addDataType("public.geometry", org.postgis.PGgeometry.class); + pgconn.addDataType("\"public\".\"geometry\"", org.postgis.PGgeometry.class); } public void addBoxen(Connection conn) throws SQLException { @@ -300,6 +302,8 @@ public void addGeometries(Connection conn) throws SQLException { org.postgresql.PGConnection pgconn = (org.postgresql.PGConnection) conn; pgconn.addDataType("geometry", org.postgis.PGgeometry.class); + pgconn.addDataType("public.geometry", org.postgis.PGgeometry.class); + pgconn.addDataType("\"public\".\"geometry\"", org.postgis.PGgeometry.class); } public void addBoxen(Connection conn) throws SQLException { @@ -319,6 +323,8 @@ public void addGeometries(Connection conn) throws SQLException { PGConnection pgconn = (PGConnection) conn; pgconn.addDataType("geometry", org.postgis.PGgeometry.class); + pgconn.addDataType("public.geometry", org.postgis.PGgeometry.class); + pgconn.addDataType("\"public\".\"geometry\"", org.postgis.PGgeometry.class); } public void addBoxen(Connection conn) throws SQLException { diff -Nru postgis-java-2.2.1/jdbc/src/main/java/org/postgis/PGgeometry.java postgis-java-2.3.0/jdbc/src/main/java/org/postgis/PGgeometry.java --- postgis-java-2.2.1/jdbc/src/main/java/org/postgis/PGgeometry.java 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc/src/main/java/org/postgis/PGgeometry.java 2018-11-25 06:58:15.000000000 +0000 @@ -1,12 +1,12 @@ /* * PGgeometry.java - * + * * PostGIS extension for PostgreSQL JDBC driver - PGobject Geometry Wrapper - * + * * (C) 2004 Paul Ramsey, pramsey@refractions.net - * + * * (C) 2005 Markus Schaber, markus.schaber@logix-tt.com - * + * * (C) 2015 Phillip Ross, phillip.w.g.ross@gmail.com * * This library is free software; you can redistribute it and/or @@ -22,7 +22,7 @@ * You should have received a copy of the GNU Lesser General Public * License along with this library; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA - * + * */ package org.postgis; @@ -37,7 +37,6 @@ private static final long serialVersionUID = 0x100; Geometry geom; - BinaryParser bp = new BinaryParser(); public PGgeometry() { this.setType("geometry"); @@ -54,7 +53,7 @@ } public void setValue(String value) throws SQLException { - geom = geomFromString(value, bp); + geom = geomFromString(value, new BinaryParser()); } public static Geometry geomFromString(String value) throws SQLException { @@ -131,7 +130,7 @@ public void setGeometry(Geometry newgeom) { this.geom = newgeom; } - + public int getGeoType() { return geom.type; } @@ -153,7 +152,7 @@ /** * Splits a String at the first occurrence of border character. - * + * * Poor man's String.split() replacement, as String.split() was invented at * jdk1.4, and the Debian PostGIS Maintainer had problems building the woody * backport of his package using DFSG-free compilers. In all the cases we diff -Nru postgis-java-2.2.1/jdbc/src/test/java/org/postgis/ParserTest.java postgis-java-2.3.0/jdbc/src/test/java/org/postgis/ParserTest.java --- postgis-java-2.2.1/jdbc/src/test/java/org/postgis/ParserTest.java 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc/src/test/java/org/postgis/ParserTest.java 2018-11-25 06:58:15.000000000 +0000 @@ -322,6 +322,13 @@ } } + /* + // Temporarily removing this check since it breaks between PostGIS v2.4.4 and PostGIS v2.5.0 + // Tests performed via psql between mdillon/postgis:9.3 and mdillon/postgis:9.4 shows the breakage + // Test is also broken in mdillon/postgis:11-alpine + // In psql, the sql statement "SELECT ST_AsEWKT(geometry_in('POINT(1e100 1.2345e-100 -2e-5)'));" returns + // "POINT(1e+100 1.2345e-100 -2e-05)" with 9.3 and "POINT(1e+100 0 -0.00002)" with 9.4 and later + // asEWKT() function is not present on PostGIS 0.X, and the test // is pointless as 0.X uses EWKT as canonical rep so the same // functionality was already tested above. @@ -330,6 +337,7 @@ logger.debug("asEWKT: {}", sqlGeom); Assert.assertEquals(geom, sqlGeom); } + */ // asEWKB() function is not present on PostGIS 0.X. if (serverPostgisMajor >= 1) { diff -Nru postgis-java-2.2.1/jdbc/src/test/java/org/postgis/SerializationTest.java postgis-java-2.3.0/jdbc/src/test/java/org/postgis/SerializationTest.java --- postgis-java-2.2.1/jdbc/src/test/java/org/postgis/SerializationTest.java 1970-01-01 00:00:00.000000000 +0000 +++ postgis-java-2.3.0/jdbc/src/test/java/org/postgis/SerializationTest.java 2018-11-25 06:58:15.000000000 +0000 @@ -0,0 +1,54 @@ +/* + * ServerTest.java + * + * PostGIS extension for PostgreSQL JDBC driver - example and test classes + * + * (C) 2004 Paul Ramsey, pramsey@refractions.net + * + * (C) 2005 Markus Schaber, markus.schaber@logix-tt.com + * + * (C) 2017 Phillip Ross, phillip.w.g.ross@gmail.com + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + * + */ + +package org.postgis; + + +import org.testng.Assert; +import org.testng.annotations.Test; + +import java.io.ByteArrayOutputStream; +import java.io.NotSerializableException; +import java.io.ObjectOutputStream; + + +public class SerializationTest { + + + @Test + public void serializationCheckPGgeometry() throws Exception { + try { + new ObjectOutputStream(new ByteArrayOutputStream()) + .writeObject(new PGgeometry("MULTIPOLYGON(((1 1,1 2,2 1,1 1)))")); + } + catch (NotSerializableException ex) { + Assert.fail("serialization of PGgeometry failed: " + ex); + } + } + + +} diff -Nru postgis-java-2.2.1/jdbc/src/test/resources/testng.xml postgis-java-2.3.0/jdbc/src/test/resources/testng.xml --- postgis-java-2.2.1/jdbc/src/test/resources/testng.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc/src/test/resources/testng.xml 2018-11-25 06:58:15.000000000 +0000 @@ -15,9 +15,10 @@ + - \ No newline at end of file + diff -Nru postgis-java-2.2.1/jdbc_jtsparser/pom.xml postgis-java-2.3.0/jdbc_jtsparser/pom.xml --- postgis-java-2.2.1/jdbc_jtsparser/pom.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc_jtsparser/pom.xml 2018-11-25 06:58:15.000000000 +0000 @@ -5,11 +5,11 @@ net.postgis postgis-java-aggregator - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT postgis-jdbc-jtsparser - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT jar Postgis JDBC Driver JTS Parser @@ -27,12 +27,23 @@ net.postgis postgis-jdbc - [2.1.0,) + 2.3.1-SNAPSHOT - com.vividsolutions + org.locationtech.jts jts - 1.12 + 1.15.0 + pom + + + org.locationtech.jts + jts-core + 1.15.0 + + + org.locationtech.spatial4j + spatial4j + 0.7 diff -Nru postgis-java-2.2.1/jdbc_jtsparser/postgis-jdbc-jtsparser.iml postgis-java-2.3.0/jdbc_jtsparser/postgis-jdbc-jtsparser.iml --- postgis-java-2.2.1/jdbc_jtsparser/postgis-jdbc-jtsparser.iml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc_jtsparser/postgis-jdbc-jtsparser.iml 1970-01-01 00:00:00.000000000 +0000 @@ -1,25 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsBinaryParser.java postgis-java-2.3.0/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsBinaryParser.java --- postgis-java-2.2.1/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsBinaryParser.java 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsBinaryParser.java 2018-11-25 06:58:15.000000000 +0000 @@ -24,13 +24,13 @@ */ package org.postgis.jts; +import org.locationtech.jts.geom.*; +import org.locationtech.jts.geom.impl.PackedCoordinateSequence; +import org.locationtech.spatial4j.context.jts.JtsSpatialContextFactory; import org.postgis.binary.ByteGetter; -import org.postgis.binary.ValueGetter; import org.postgis.binary.ByteGetter.BinaryByteGetter; import org.postgis.binary.ByteGetter.StringByteGetter; - -import com.vividsolutions.jts.geom.*; -import com.vividsolutions.jts.geom.impl.PackedCoordinateSequence; +import org.postgis.binary.ValueGetter; /** * Parse binary representation of geometries. Currently, only text rep (hexed) @@ -48,6 +48,8 @@ * */ public class JtsBinaryParser { + + private JtsSpatialContextFactory jtsFactory = new JtsSpatialContextFactory(); /** * Get the appropriate ValueGetter for my endianness @@ -169,9 +171,9 @@ Point result; if (haveZ) { double Z = data.getDouble(); - result = JtsGeometry.geofac.createPoint(new Coordinate(X, Y, Z)); + result = jtsFactory.getGeometryFactory().createPoint(new Coordinate(X, Y, Z)); } else { - result = JtsGeometry.geofac.createPoint(new Coordinate(X, Y)); + result = jtsFactory.getGeometryFactory().createPoint(new Coordinate(X, Y)); } if (haveM) { // skip M value @@ -214,15 +216,15 @@ private MultiPoint parseMultiPoint(ValueGetter data, int srid) { Point[] points = new Point[data.getInt()]; parseGeometryArray(data, points, srid); - return JtsGeometry.geofac.createMultiPoint(points); + return jtsFactory.getGeometryFactory().createMultiPoint(points); } private LineString parseLineString(ValueGetter data, boolean haveZ, boolean haveM) { - return JtsGeometry.geofac.createLineString(parseCS(data, haveZ, haveM)); + return jtsFactory.getGeometryFactory().createLineString(parseCS(data, haveZ, haveM)); } private LinearRing parseLinearRing(ValueGetter data, boolean haveZ, boolean haveM) { - return JtsGeometry.geofac.createLinearRing(parseCS(data, haveZ, haveM)); + return jtsFactory.getGeometryFactory().createLinearRing(parseCS(data, haveZ, haveM)); } private Polygon parsePolygon(ValueGetter data, boolean haveZ, boolean haveM, int srid) { @@ -234,27 +236,27 @@ rings[i] = parseLinearRing(data, haveZ, haveM); rings[i].setSRID(srid); } - return JtsGeometry.geofac.createPolygon(shell, rings); + return jtsFactory.getGeometryFactory().createPolygon(shell, rings); } private MultiLineString parseMultiLineString(ValueGetter data, int srid) { int count = data.getInt(); LineString[] strings = new LineString[count]; parseGeometryArray(data, strings, srid); - return JtsGeometry.geofac.createMultiLineString(strings); + return jtsFactory.getGeometryFactory().createMultiLineString(strings); } private MultiPolygon parseMultiPolygon(ValueGetter data, int srid) { int count = data.getInt(); Polygon[] polys = new Polygon[count]; parseGeometryArray(data, polys, srid); - return JtsGeometry.geofac.createMultiPolygon(polys); + return jtsFactory.getGeometryFactory().createMultiPolygon(polys); } private GeometryCollection parseCollection(ValueGetter data, int srid) { int count = data.getInt(); Geometry[] geoms = new Geometry[count]; parseGeometryArray(data, geoms, srid); - return JtsGeometry.geofac.createGeometryCollection(geoms); + return jtsFactory.getGeometryFactory().createGeometryCollection(geoms); } } diff -Nru postgis-java-2.2.1/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsBinaryWriter.java postgis-java-2.3.0/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsBinaryWriter.java --- postgis-java-2.2.1/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsBinaryWriter.java 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsBinaryWriter.java 2018-11-25 06:58:15.000000000 +0000 @@ -24,15 +24,15 @@ */ package org.postgis.jts; -import com.vividsolutions.jts.geom.CoordinateSequence; -import com.vividsolutions.jts.geom.Geometry; -import com.vividsolutions.jts.geom.GeometryCollection; -import com.vividsolutions.jts.geom.LineString; -import com.vividsolutions.jts.geom.MultiLineString; -import com.vividsolutions.jts.geom.MultiPoint; -import com.vividsolutions.jts.geom.MultiPolygon; -import com.vividsolutions.jts.geom.Point; -import com.vividsolutions.jts.geom.Polygon; +import org.locationtech.jts.geom.CoordinateSequence; +import org.locationtech.jts.geom.Geometry; +import org.locationtech.jts.geom.GeometryCollection; +import org.locationtech.jts.geom.LineString; +import org.locationtech.jts.geom.MultiLineString; +import org.locationtech.jts.geom.MultiPoint; +import org.locationtech.jts.geom.MultiPolygon; +import org.locationtech.jts.geom.Point; +import org.locationtech.jts.geom.Polygon; import org.postgis.binary.ByteSetter; import org.postgis.binary.ValueSetter; @@ -184,23 +184,23 @@ } public static int getWKBType(Geometry geom) { - // We always write emtpy geometries as emtpy collections - for OpenGIS + // We always write empty geometries as empty collections - for OpenGIS // conformance if (geom.isEmpty()) { return org.postgis.Geometry.GEOMETRYCOLLECTION; } else if (geom instanceof Point) { return org.postgis.Geometry.POINT; - } else if (geom instanceof com.vividsolutions.jts.geom.LineString) { + } else if (geom instanceof org.locationtech.jts.geom.LineString) { return org.postgis.Geometry.LINESTRING; - } else if (geom instanceof com.vividsolutions.jts.geom.Polygon) { + } else if (geom instanceof org.locationtech.jts.geom.Polygon) { return org.postgis.Geometry.POLYGON; } else if (geom instanceof MultiPoint) { return org.postgis.Geometry.MULTIPOINT; } else if (geom instanceof MultiLineString) { return org.postgis.Geometry.MULTILINESTRING; - } else if (geom instanceof com.vividsolutions.jts.geom.MultiPolygon) { + } else if (geom instanceof org.locationtech.jts.geom.MultiPolygon) { return org.postgis.Geometry.MULTIPOLYGON; - } if (geom instanceof com.vividsolutions.jts.geom.GeometryCollection) { + } if (geom instanceof org.locationtech.jts.geom.GeometryCollection) { return org.postgis.Geometry.GEOMETRYCOLLECTION; } else { throw new IllegalArgumentException("Unknown Geometry Type: " + geom.getClass().getName()); @@ -216,7 +216,7 @@ } /** - * Write a Coordinatesequence, part of LinearRing and Linestring, but not + * Write a CoordinateSequence, part of LinearRing and Linestring, but not * MultiPoint! */ private void writeCoordinates(CoordinateSequence seq, int dims, ValueSetter dest) { diff -Nru postgis-java-2.2.1/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsGeometry.java postgis-java-2.3.0/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsGeometry.java --- postgis-java-2.2.1/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsGeometry.java 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc_jtsparser/src/main/java/org/postgis/jts/JtsGeometry.java 2018-11-25 06:58:15.000000000 +0000 @@ -30,14 +30,14 @@ import org.postgresql.util.PGobject; -import com.vividsolutions.jts.geom.CoordinateSequenceFactory; -import com.vividsolutions.jts.geom.Geometry; -import com.vividsolutions.jts.geom.GeometryCollection; -import com.vividsolutions.jts.geom.GeometryFactory; -import com.vividsolutions.jts.geom.Polygon; -import com.vividsolutions.jts.geom.PrecisionModel; -import com.vividsolutions.jts.geom.impl.PackedCoordinateSequenceFactory; -import com.vividsolutions.jts.io.WKTReader; +import org.locationtech.jts.geom.CoordinateSequenceFactory; +import org.locationtech.jts.geom.Geometry; +import org.locationtech.jts.geom.GeometryCollection; +import org.locationtech.jts.geom.GeometryFactory; +import org.locationtech.jts.geom.Polygon; +import org.locationtech.jts.geom.PrecisionModel; +import org.locationtech.jts.geom.impl.PackedCoordinateSequenceFactory; +import org.locationtech.jts.io.WKTReader; /** * JTS Geometry SQL wrapper. Supports PostGIS 1.x (lwgeom hexwkb) for writing diff -Nru postgis-java-2.2.1/jdbc_jtsparser/src/main/java/org/postgis/jts/JTSShape.java postgis-java-2.3.0/jdbc_jtsparser/src/main/java/org/postgis/jts/JTSShape.java --- postgis-java-2.2.1/jdbc_jtsparser/src/main/java/org/postgis/jts/JTSShape.java 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc_jtsparser/src/main/java/org/postgis/jts/JTSShape.java 2018-11-25 06:58:15.000000000 +0000 @@ -25,25 +25,17 @@ package org.postgis.jts; -import java.awt.Rectangle; -import java.awt.Shape; +import org.locationtech.jts.geom.*; +import org.locationtech.jts.geom.Point; +import org.locationtech.jts.geom.Polygon; +import org.locationtech.jts.geom.impl.PackedCoordinateSequence; + +import java.awt.*; import java.awt.geom.AffineTransform; import java.awt.geom.PathIterator; import java.awt.geom.Point2D; import java.awt.geom.Rectangle2D; -import com.vividsolutions.jts.geom.Coordinate; -import com.vividsolutions.jts.geom.CoordinateSequence; -import com.vividsolutions.jts.geom.Envelope; -import com.vividsolutions.jts.geom.Geometry; -import com.vividsolutions.jts.geom.GeometryCollection; -import com.vividsolutions.jts.geom.GeometryFactory; -import com.vividsolutions.jts.geom.LineString; -import com.vividsolutions.jts.geom.LinearRing; -import com.vividsolutions.jts.geom.Point; -import com.vividsolutions.jts.geom.Polygon; -import com.vividsolutions.jts.geom.impl.PackedCoordinateSequence; - public class JTSShape implements Shape { static GeometryFactory fac = new GeometryFactory(); diff -Nru postgis-java-2.2.1/jdbc_jtsparser/src/test/java/org/postgis/jts/JtsParserTest.java postgis-java-2.3.0/jdbc_jtsparser/src/test/java/org/postgis/jts/JtsParserTest.java --- postgis-java-2.2.1/jdbc_jtsparser/src/test/java/org/postgis/jts/JtsParserTest.java 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/jdbc_jtsparser/src/test/java/org/postgis/jts/JtsParserTest.java 2018-11-25 06:58:15.000000000 +0000 @@ -26,7 +26,7 @@ import org.postgis.binary.ValueSetter; -import com.vividsolutions.jts.geom.*; +import org.locationtech.jts.geom.*; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.testng.Assert; diff -Nru postgis-java-2.2.1/pom.xml postgis-java-2.3.0/pom.xml --- postgis-java-2.2.1/pom.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/pom.xml 2018-11-25 06:58:15.000000000 +0000 @@ -4,7 +4,7 @@ net.postgis postgis-java-aggregator - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT pom PostGIS Java Project @@ -108,31 +108,35 @@ true - 1.12 - 1.3.0 - 3.0.0 - 3.5.1 - 2.10 + 3.0.0 + 1.4.0 + 1.6.0 + 3.0.0 + 3.1.0 + 3.7.0 + 3.1.0 2.8.2 - 2.10.1 + 3.0.0 + 3.0.0 1.4.1 - 2.19.1 + 2.21.0 1.6 2.5.2 - 3.0.2 + 3.1.0 1.4 - 2.10.4 + 3.0.0 2.5 2.5.3 - 3.0.1 - 2.4.3 + 3.0.2 + 3.1.1 3.0.1 - 2.19.1 - 2.6 + 2.21.0 + 2.5 + 3.2.0 - 1.1.7 - 1.7.21 - 6.9.10 + 1.2.3 + 1.7.25 + 6.14.3 diff -Nru postgis-java-2.2.1/postgis-java-aggregator.iml postgis-java-2.3.0/postgis-java-aggregator.iml --- postgis-java-2.2.1/postgis-java-aggregator.iml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/postgis-java-aggregator.iml 1970-01-01 00:00:00.000000000 +0000 @@ -1,18 +0,0 @@ - - - - - - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/postgis-jdbc-java2d/pom.xml postgis-java-2.3.0/postgis-jdbc-java2d/pom.xml --- postgis-java-2.2.1/postgis-jdbc-java2d/pom.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/postgis-jdbc-java2d/pom.xml 2018-11-25 06:58:15.000000000 +0000 @@ -5,11 +5,11 @@ net.postgis postgis-java-aggregator - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT postgis-jdbc-java2d - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT jar postgis-jdbc-java2d @@ -27,7 +27,7 @@ net.postgis postgis-jdbc - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT diff -Nru postgis-java-2.2.1/postgis-jdbc-java2d/postgis-jdbc-java2d.iml postgis-java-2.3.0/postgis-jdbc-java2d/postgis-jdbc-java2d.iml --- postgis-java-2.2.1/postgis-jdbc-java2d/postgis-jdbc-java2d.iml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/postgis-jdbc-java2d/postgis-jdbc-java2d.iml 1970-01-01 00:00:00.000000000 +0000 @@ -1,23 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/tools/osgeo-postgis-jdbc-test-util/osgeo-postgis-jdbc-test-util.iml postgis-java-2.3.0/tools/osgeo-postgis-jdbc-test-util/osgeo-postgis-jdbc-test-util.iml --- postgis-java-2.2.1/tools/osgeo-postgis-jdbc-test-util/osgeo-postgis-jdbc-test-util.iml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/tools/osgeo-postgis-jdbc-test-util/osgeo-postgis-jdbc-test-util.iml 1970-01-01 00:00:00.000000000 +0000 @@ -1,24 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff -Nru postgis-java-2.2.1/tools/osgeo-postgis-jdbc-test-util/pom.xml postgis-java-2.3.0/tools/osgeo-postgis-jdbc-test-util/pom.xml --- postgis-java-2.2.1/tools/osgeo-postgis-jdbc-test-util/pom.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/tools/osgeo-postgis-jdbc-test-util/pom.xml 2018-11-25 06:58:15.000000000 +0000 @@ -5,11 +5,11 @@ tools net.postgis - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT osgeo-postgis-jdbc-test-util - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT jar osgeo-postgis-jdbc-test-util @@ -30,7 +30,7 @@ net.postgis postgis-jdbc - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT diff -Nru postgis-java-2.2.1/tools/pom.xml postgis-java-2.3.0/tools/pom.xml --- postgis-java-2.2.1/tools/pom.xml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/tools/pom.xml 2018-11-25 06:58:15.000000000 +0000 @@ -5,11 +5,11 @@ postgis-java-aggregator net.postgis - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT tools - 2.2.2-SNAPSHOT + 2.3.1-SNAPSHOT pom tools diff -Nru postgis-java-2.2.1/tools/tools.iml postgis-java-2.3.0/tools/tools.iml --- postgis-java-2.2.1/tools/tools.iml 2016-07-28 18:40:29.000000000 +0000 +++ postgis-java-2.3.0/tools/tools.iml 1970-01-01 00:00:00.000000000 +0000 @@ -1,21 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file