Adding gml specific attributes to feature in gml parsing. p=sbenthall r=me (closes #1328)

git-svn-id: http://svn.openlayers.org/trunk/openlayers@7654 dc9f47b5-9b13-0410-9fdd-eb0c1a62fdaf
This commit is contained in:
Tim Schaub
2008-08-01 01:30:39 +00:00
parent 714b1d7363
commit f3283e9212

View File

@@ -168,6 +168,13 @@ OpenLayers.Format.GML = OpenLayers.Class(OpenLayers.Format.XML, {
attributes = this.parseAttributes(node);
}
var feature = new OpenLayers.Feature.Vector(geometry, attributes);
feature.gml = {
featureType: node.firstChild.nodeName.split(":")[1],
featureNS: node.firstChild.namespaceURI,
featureNSPrefix: node.firstChild.prefix
};
// assign fid - this can come from a "fid" or "id" attribute
var childNode = node.firstChild;
var fid;