Introduce defaultDataProjection for formats

This commit is contained in:
tsauerwein
2014-08-18 14:28:43 +02:00
parent 1205d0fe1e
commit 539e4a23b9
17 changed files with 145 additions and 91 deletions
+9 -3
View File
@@ -199,7 +199,9 @@ ol.format.XMLFeature.prototype.readProjectionFromNode = goog.abstractMethod;
* @inheritDoc
*/
ol.format.XMLFeature.prototype.writeFeature = function(feature, opt_options) {
return this.writeFeatureNode(feature, opt_options);
return this.writeFeatureNode(
feature,
this.adaptOptionsWithDefaultDataProjection(opt_options));
};
@@ -216,7 +218,9 @@ ol.format.XMLFeature.prototype.writeFeatureNode = goog.abstractMethod;
* @inheritDoc
*/
ol.format.XMLFeature.prototype.writeFeatures = function(features, opt_options) {
return this.writeFeaturesNode(features, opt_options);
return this.writeFeaturesNode(
features,
this.adaptOptionsWithDefaultDataProjection(opt_options));
};
@@ -233,7 +237,9 @@ ol.format.XMLFeature.prototype.writeFeaturesNode = goog.abstractMethod;
* @inheritDoc
*/
ol.format.XMLFeature.prototype.writeGeometry = function(geometry, opt_options) {
return this.writeGeometryNode(geometry, opt_options);
return this.writeGeometryNode(
geometry,
this.adaptOptionsWithDefaultDataProjection(opt_options));
};