From: Mikael C. <mik...@cl...> - 2010-03-19 09:25:56
|
Hi Poul, Did you try to add the version to the WFSProtocolOptions passed as a parameter to the constructor of WFSProtocol ? Mikael 2010/3/19 Paweł Pawlak <ppa...@gm...> > Hi Hi! > > I am using GWT with Openlayers 2.8. My goal is to save, delete and modify > object from Web Browser. I am using for that Vector layer with WFSProtocol. > I wrote 'save strategy' class for vector layer, because it has not been > included into GWT-OL library yet. When I try to save some features to the > database I got in firebug error: > * > <ServiceException> > java.lang.RuntimeException: Parsing failed for the_geom: > java.lang.ClassCastException: com.vividsolutions.jts.geom.LineString cannot > be cast to > com.vividsolutions.jts.geom.MultiLineString > Parsing failed for the_geom: java.lang.ClassCastException: > com.vividsolutions.jts.geom.LineString cannot be cast to > com.vividsolutions.jts.geom.MultiLineString > com.vividsolutions.jts.geom.LineString cannot be cast to > com.vividsolutions.jts.geom.MultiLineString > </ServiceException></ServiceExceptionReport>* > > I was thinking that maybe I have done some mistakes when I create new > classes but it was not that. > > I know why is that. The reason is that I use version of WFS 1.0.0 in > declaration of wfsProtocolOptions but in this version that kind of error > happens when you try to add LineString geometry to MultiLineString. This was > fixed in wfs 1.1.0 but unfortunately when I change the version of > WFSprotocol to 1.1.0 my *Vector layer does not appear on the map - IT DOES > NOT WORK*. Why is that?? How come version 1.1.0 of WFS does not work in > GWT-OL. > > I have also checked everything in pure JS. In version 1.0.0 of WFSProtocol > I got this same error, but when I change the version to 1.1.0 everything > work just fine. The new geometry was added to the database, and of course I > can see my vector layer on the map. > > Did anyone have this kinds of problems? > > Regards, > Poul > > ------------------------------------------------------------------------------ > Download Intel® Parallel Studio Eval > Try the new software tools for yourself. Speed compiling, find bugs > proactively, and fine-tune applications for parallel performance. > See why Intel Parallel Studio got high marks during beta. > http://p.sf.net/sfu/intel-sw-dev > _______________________________________________ > Gwt-openlayers-users mailing list > Gwt...@li... > https://lists.sourceforge.net/lists/listinfo/gwt-openlayers-users > > -- Mikael Couzic Pôle Business Intelligence Groupe Cliris |