PostgisDataStore 'M' Geometry Type Mapping
------------------------------------------
Key: GEOT-2066
URL: http://jira.codehaus.org/browse/GEOT-2066
Project: GeoTools
Issue Type: Bug
Components: data postgis
Affects Versions: 2.5-RC0
Reporter: Matt Blanchette
Assignee: Justin Deoliveira
The addition of M Geometry types in Hashmap named "GEOM_TYPE_MAP" in
PostgisDataStore.java may cause the wrong Geometry type to be used and the
createSchema method to fail.
Example mapping:
GEOM_TYPE_MAP.put("POINT", Point.class);
GEOM_TYPE_MAP.put("POINTM", Point.class);
The Hashmap "GEOM_CLASS_MAPPINGS" attempts to create mappings in the reverse
direction (from Class to String), but the two Strings share the same Class
resulting in only one of the two mappings.
Depending on the order of the keySet returned from "GEOM_TYPE_MAP" the M
Geometry type String may be mapped to the class.
The createSchema method calls getGeometrySQLTypeName method which uses this
HashMap "GEOM_CLASS_MAPPINGS" and will cause this method to fail from the
CONSTRAINT enforce_geotype when the wrong Geometry type String is returned.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel