Ticket #3037 (closed feature: fixed)
OpenLayers.Protocol.WFS misses a setGeometryName method
| Reported by: | fvanderbiest | Owned by: | tschaub |
|---|---|---|---|
| Priority: | minor | Milestone: | 2.11 Release |
| Component: | Protocol.WFS | Version: | SVN |
| Keywords: | Cc: | ||
| State: | Needs More Work |
Description
WFS protocol can be created after WFS getCapabilities, for instance, by a GeoExt WFSCapabilitiesReader. At this stage, protocol's geometryName is unkown, since it can only be obtained by WFS DescribeFeatureType.
Thus, I think we need a setGeometryName method in OpenLayers.Protocol.WFS.v1, so that its internal format can be upgraded to take into account a geometryName different than OpenLayers' default "the_geom".
Here's a simple implementation for this proposal :
/**
* APIMethod: setGeometryName
* Sets the geometryName option after instanciation.
*/
setGeometryName: function(geometryName) {
this.geometryName = geometryName;
this.format.geometryName = geometryName;
},
It would also be very easy to do it at application level, but since the format is not an API property, it might be better to expose an API method for this purpose.
Change History
Note: See
TracTickets for help on using
tickets.
