Merge pull request #3156 from fredj/format-getprojection
Move readProjectionFrom* functions to the base classes
This commit is contained in:
@@ -501,22 +501,6 @@ ol.format.GPX.prototype.readFeaturesFromNode = function(node, opt_options) {
|
||||
ol.format.GPX.prototype.readProjection;
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.format.GPX.prototype.readProjectionFromDocument = function(doc) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.format.GPX.prototype.readProjectionFromNode = function(node) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {Node} node Node.
|
||||
* @param {string} value Value for the link's `href` attribute.
|
||||
|
||||
@@ -218,11 +218,3 @@ ol.format.IGC.prototype.readFeaturesFromText = function(text, opt_options) {
|
||||
* @api
|
||||
*/
|
||||
ol.format.IGC.prototype.readProjection;
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.format.IGC.prototype.readProjectionFromText = function(text) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
@@ -1721,22 +1721,6 @@ ol.format.KML.prototype.readNameFromNode = function(node) {
|
||||
ol.format.KML.prototype.readProjection;
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.format.KML.prototype.readProjectionFromDocument = function(doc) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.format.KML.prototype.readProjectionFromNode = function(node) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @param {Node} node Node to append a TextNode with the color to.
|
||||
* @param {ol.Color|string} color Color.
|
||||
|
||||
@@ -234,19 +234,3 @@ ol.format.OSMXML.prototype.readFeaturesFromNode = function(node, opt_options) {
|
||||
* @api stable
|
||||
*/
|
||||
ol.format.OSMXML.prototype.readProjection;
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.format.OSMXML.prototype.readProjectionFromDocument = function(doc) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.format.OSMXML.prototype.readProjectionFromNode = function(node) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
@@ -340,14 +340,6 @@ ol.format.Polyline.prototype.readGeometryFromText =
|
||||
ol.format.Polyline.prototype.readProjection;
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.format.Polyline.prototype.readProjectionFromText = function(text) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
|
||||
@@ -111,7 +111,9 @@ ol.format.TextFeature.prototype.readProjection = function(source) {
|
||||
* @protected
|
||||
* @return {ol.proj.Projection} Projection.
|
||||
*/
|
||||
ol.format.TextFeature.prototype.readProjectionFromText = goog.abstractMethod;
|
||||
ol.format.TextFeature.prototype.readProjectionFromText = function(text) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -291,14 +291,6 @@ ol.format.WKT.prototype.readGeometryFromText = function(text, opt_options) {
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* @inheritDoc
|
||||
*/
|
||||
ol.format.WKT.prototype.readProjectionFromText = function(text) {
|
||||
return null;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Encode a feature as a WKT string.
|
||||
*
|
||||
|
||||
@@ -185,7 +185,9 @@ ol.format.XMLFeature.prototype.readProjection = function(source) {
|
||||
* @protected
|
||||
* @return {ol.proj.Projection} Projection.
|
||||
*/
|
||||
ol.format.XMLFeature.prototype.readProjectionFromDocument = goog.abstractMethod;
|
||||
ol.format.XMLFeature.prototype.readProjectionFromDocument = function(doc) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
@@ -193,7 +195,9 @@ ol.format.XMLFeature.prototype.readProjectionFromDocument = goog.abstractMethod;
|
||||
* @protected
|
||||
* @return {ol.proj.Projection} Projection.
|
||||
*/
|
||||
ol.format.XMLFeature.prototype.readProjectionFromNode = goog.abstractMethod;
|
||||
ol.format.XMLFeature.prototype.readProjectionFromNode = function(node) {
|
||||
return this.defaultDataProjection;
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user