[OpenLayers-Dev] Format: inheriting writers
bartvde at osgis.nl
bartvde at osgis.nl
Fri May 8 02:35:50 EDT 2009
Hi list,
currently the SLD Format writers property uses the Filter Format writer
property. The Filter Format uses ogc as the prefix, e.g.:
var node = this.createElementNSPlus("ogc:PropertyIsEqualTo");
So this will work fine.
Now I want to use the Format.SLD writers in my OWSContext Format for
MinScaleDenominator and MaxScaleDenominator, but the problem here is that
there is no prefix, so:
"MaxScaleDenominator": function(scale) {
return this.createElementNSPlus(
"MaxScaleDenominator", {value: scale}
);
},
This will create MaxScaleDenominator in the default namespace, which is
incorrect.
Is there any way to work around this? Ofcourse changing the above to:
"MaxScaleDenominator": function(scale) {
return this.createElementNSPlus(
"sld:MaxScaleDenominator", {value: scale}
);
},
will make things work in either cases.
Best regards,
Bart
More information about the Dev
mailing list