Mercurial > dive4elements > river
changeset 2864:bb116a8d6e19
Changed the geometry type of 'catchments' from polygon to multipolygon.
flys-backend/trunk@4356 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Tue, 08 May 2012 10:22:48 +0000 |
parents | b3d5e6d6e468 |
children | a6ef300748c4 |
files | flys-backend/ChangeLog flys-backend/doc/schema/oracle-spatial_idx.sql flys-backend/src/main/java/de/intevation/flys/model/Catchment.java |
diffstat | 3 files changed, 13 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/flys-backend/ChangeLog Tue May 08 07:06:37 2012 +0000 +++ b/flys-backend/ChangeLog Tue May 08 10:22:48 2012 +0000 @@ -1,3 +1,11 @@ +2012-05-08 Ingo Weinzierl <ingo@intevation.de> + + * doc/schema/oracle-spatial_idx.sql: Set the geometry type of 'catchments' + to 'multipolygon'. + + * src/main/java/de/intevation/flys/model/Catchment.java: The geometry + attribute in such instances is now from type 'Geometry'. + 2012-05-08 Ingo Weinzierl <ingo@intevation.de> * doc/schema/import-dems.sql: New. Insert statements to insert dems into
--- a/flys-backend/doc/schema/oracle-spatial_idx.sql Tue May 08 07:06:37 2012 +0000 +++ b/flys-backend/doc/schema/oracle-spatial_idx.sql Tue May 08 10:22:48 2012 +0000 @@ -1,4 +1,4 @@ -CREATE INDEX catchment_spatial_idx ON catchment(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=polygon'); +CREATE INDEX catchment_spatial_idx ON catchment(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=multipolygon'); CREATE INDEX river_axes_km_spatial_idx ON river_axes_km(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=point'); CREATE INDEX buildings_spatial_idx ON buildings(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=LINE'); CREATE INDEX fixpoints_spatial_idx ON fixpoints(GEOM) indextype IS MDSYS.SPATIAL_INDEX parameters ('LAYER_GTYPE=POINT');
--- a/flys-backend/src/main/java/de/intevation/flys/model/Catchment.java Tue May 08 07:06:37 2012 +0000 +++ b/flys-backend/src/main/java/de/intevation/flys/model/Catchment.java Tue May 08 10:22:48 2012 +0000 @@ -15,7 +15,7 @@ import org.hibernate.Query; import org.hibernate.annotations.Type; -import com.vividsolutions.jts.geom.Polygon; +import com.vividsolutions.jts.geom.Geometry; import de.intevation.flys.backend.SessionHolder; @@ -29,7 +29,7 @@ private BigDecimal area; private String name; private River river; - private Polygon geom; + private Geometry geom; public Catchment() { } @@ -83,12 +83,12 @@ @Column(name = "geom") @Type(type = "org.hibernatespatial.GeometryUserType") - public Polygon getGeom() { + public Geometry getGeom() { return geom; } - public void setGeom(Polygon geom) { + public void setGeom(Geometry geom) { this.geom = geom; }