Error con ShapeObj in mapscript java - ms4w 2.3

View: New views
1 Messages — Rating Filter:   Alert me  

Error con ShapeObj in mapscript java - ms4w 2.3

by joel mamani :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----------------------------------------------------
import java.io.IOException;
import edu.umn.gis.mapscript.mapObj;
import edu.umn.gis.mapscript.shapeObj;
public class PruebasShapes {

        /**
         * @param args
         * @throws IOException
         */
        public static void main(String[] args) throws IOException {
                mapObj m=new mapObj("");
            shapeObj s=shapeObj.fromWKT("LINE((2000 2500, 70 4322))");
            System.out.print(""+s.getCentroid().toString());
        }

}
--------------------------------------------------------
Error:
--------------------------------------------------------
Exception in thread "main" java.lang.UnknownError: msGEOSShapeFromWKT(): GEOS library error. Error reading WKT geometry "LINE((2000 2500, 70 4322))".;msGEOSError(): GEOS library error. ParseException: Unknown type: 'LINE'
        at edu.umn.gis.mapscript.mapscriptJNI.shapeObj_fromWKT(Native Method)
        at edu.umn.gis.mapscript.shapeObj.fromWKT(shapeObj.java:108)
        at PruebasShapes.main(PruebasShapes.java:12)
--------------------------------------------------------
Help!


      Yahoo! Cocina

Encontra las mejores recetas con Yahoo! Cocina.


http://ar.mujer.yahoo.com/cocina/
_______________________________________________
MS4W-Users mailing list
MS4W-Users@...
http://lists.maptools.org/mailman/listinfo/ms4w-users