Gaby creating an OGC URN or OGC HTTP URI CRS identifier is as simple as appending the EPSG code to the prefix as below:
int epsgCode = 2193; String ogcUrn = "urn:ogc:def:crs:EPSG::" + epsgCode; String ogcHttpUri = "http://www.opengis.net/def/crs/EPSG/0/" + epsgCode; I missed the double colon "::" in my first example, but GeoTools is lenient. An optional database version can go between the colons; "::" means none. The HTTP URI "/0/" also means no version. These forms should be fine for most users. Gaby, I have had to make changes to the implementation and I have nightmares too! Now we have excellent test coverage, and OGC URN and OGC HTTP URI forms and I sleep better at night. :-) See also: http://jira.codehaus.org/browse/GEOT-4160 HTTP URIs are current OGC policy: "In June 2010 OGC revised the naming policy to use http URIs to identify persistent OGC resources instead of URNs." http://www.opengeospatial.org/projects/groups/ogcnasc Whitepaper: "OGC Identifiers - the case for http URIs" (OGC 10-124r1): https://portal.opengeospatial.org/files/?artifact_id=39467 Kind regards, Ben. On 29/07/13 13:22, gaby wrote: > I agree with you Ben, it is not robust at all and it gives me nightmares > about other coordinate systems. I will try using the OGC urn code instead. > Does anyone have a link for how to come up with the codes? > Thanx > Gaby > > > > -- > View this message in context: > http://osgeo-org.1560.x6.nabble.com/Need-help-reprojecting-ReferencedEnvelope-tp5069254p5069266.html > Sent from the geotools-gt2-users mailing list archive at Nabble.com. > > ------------------------------------------------------------------------------ > See everything from the browser to the database with AppDynamics > Get end-to-end visibility with application monitoring from AppDynamics > Isolate bottlenecks and diagnose root cause in seconds. > Start your free trial of AppDynamics Pro today! > http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk > _______________________________________________ > GeoTools-GT2-Users mailing list > GeoTools-GT2-Users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users > > -- Ben Caradoc-Davies <ben.caradoc-dav...@csiro.au> Software Engineer CSIRO Earth Science and Resource Engineering Australian Resources Research Centre ------------------------------------------------------------------------------ See everything from the browser to the database with AppDynamics Get end-to-end visibility with application monitoring from AppDynamics Isolate bottlenecks and diagnose root cause in seconds. Start your free trial of AppDynamics Pro today! http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk _______________________________________________ GeoTools-GT2-Users mailing list GeoTools-GT2-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users