geotools decode featuretype

المشرف العام

Administrator
طاقم الإدارة
Encode:

A way of encoding a FeatureType is:

SimpleFeatureType TYPE = DataUtilities.createType("Location", "geom:point,name:String");GML encode = new GML(Version.GML2);encode.setBaseURL(new URL("http://localhost/"));encode.encode(out, TYPE);Decode:

I have a xsd of a featuretype:

And I want to decode it as a SimpleFeatureType. How can I do that?

Possible solution 1:
The GML2ParsingUtils Class may be helpful. It has a method named featuretype for parsing schema, but I don't know how to prepare the method arguments.

Possible solution 2:

GML gml = new GML(GML.Version.GML2);gml.decodeSimpleFeatureType(url,name);But I don't have any url. I have a HttpServletRequest.



أكثر...
 
أعلى