Hi list,

Please excuse me beginner question. I'm using geotools 10.7 and trying 
to parse wkt's with CRS.parseWKT() that contain EXTENSION parameters 
like below:

         PROJCS["UTM-19N-Nad83",
                             GEOGCS["unnamed",
                             DATUM["North_American_Datum_1983",
SPHEROID["North_American_Datum_1983",6378137,298.2572201434276],
                             TOWGS84[0,0,0,0,0,0,0]],
                             PRIMEM["Greenwich",0],
                             UNIT["degree",0.0174532925199433],
EXTENSION["Scaler","0,0,0,0.02,0.02,0.001"],
                             EXTENSION["Source","CARIS"]],
                             PROJECTION["Transverse_Mercator"],
                             PARAMETER["latitude_of_origin",0],
                             PARAMETER["central_meridian",-69],
                             PARAMETER["scale_factor",0.9996],
                             PARAMETER["false_easting",500000],
                             PARAMETER["false_northing",0],
                             UNIT["metre",1]]

but it fails with the following exception:

org.opengis.referencing.FactoryException: Error in "GEOGCS": Parameter 
"EXTENSION" was not expected.
     at 
org.geotools.referencing.factory.ReferencingObjectFactory.createFromWKT(ReferencingObjectFactory.java:1096)
     at org.geotools.referencing.CRS.parseWKT(CRS.java:534)

Caused by: java.text.ParseException: Error in "GEOGCS": Parameter 
"EXTENSION" was not expected.
     at org.geotools.referencing.wkt.Element.close(Element.java:539)
     at org.geotools.referencing.wkt.Parser.parseGeoGCS(Parser.java:882)
     at org.geotools.referencing.wkt.Parser.parseProjCS(Parser.java:913)
     at 
org.geotools.referencing.wkt.Parser.parseCoordinateReferenceSystem(Parser.java:225)
     at 
org.geotools.referencing.wkt.Parser.parseCoordinateReferenceSystem(Parser.java:204)
     at 
org.geotools.referencing.factory.ReferencingObjectFactory.createFromWKT(ReferencingObjectFactory.java:1090

Could someone kindly give me a pointer?

Thanks and best regards,
Nhan

------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk
_______________________________________________
GeoTools-GT2-Users mailing list
GeoTools-GT2-Users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to