On 27/09/2010 13:08, worklikeadevil wrote:
>
> Hi all,
> i need help with the Csv2Shape example. I opend a new netbeans project and
> copy and paste the code from the csv2shp example. I added following
> references:
>
> gt-main-2.7-M3.jar
> gt-shapefile-2.7-M3.jar
> gt-referencing-2.7-M3.jar
> gt-swing-2.7-M3.jar
> geoapi-pending-2.3-M1.jar
> geoapi-2.3-M1.jar
> jts-1.11.jar
> gt-api-2.7-M3.jar

> when i run the app, i get following exception:
>
> run:
> Exception in thread "main" org.geotools.feature.SchemaException: Error
> decoding srs: 4326
>          at

You're missing gt-epsg-hsql-2.7-M3.jar

> I looked in former postings and found a missing reference. So i added the
> gt-epsg-hsql-2.7-M3.jar

Ah ok

> But after adding the jar i get another exception:
> run:
> Exception in thread "main" java.lang.RuntimeException: Uncompilable source
> code
>          at csv2shape.csv2shape.main(csv2shape.java:70)
> Java Result: 1
> Line 70 is the GeometryFactory:
>
> GeometryFactory geometryFactory = JTSFactoryFinder.getGeometryFactory(null);

Now that is odd. Not sure why that is happening, it seems there is
some incompatibility issue. What if you use simply:
GeometryFactory geometryFactory = new GeometryFactory() ?

> Does anybody have an idea?
> By the way - i cannot use maven, unfortunately.

Ouch... using GT2 without maven is possible, but painful.

Cheers
Andrea

-----------------------------------------------------
Ing. Andrea Aime
Senior Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584962313
fax:     +39 0584962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-----------------------------------------------------

-- 
-----------------------------------------------------
Ing. Andrea Aime
Senior Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy

phone: +39 0584962313
fax:     +39 0584962313

http://www.geo-solutions.it
http://geo-solutions.blogspot.com/
http://www.linkedin.com/in/andreaaime
http://twitter.com/geowolf

-----------------------------------------------------

------------------------------------------------------------------------------
Start uncovering the many advantages of virtual appliances
and start using them to simplify application deployment and
accelerate your shift to cloud computing.
http://p.sf.net/sfu/novell-sfdev2dev
_______________________________________________
Geotools-gt2-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users

Reply via email to