Make internal proj constructors private

This commit is contained in:
Tim Schaub
2014-07-10 16:37:07 -06:00
parent 121d19e0ba
commit 521cbfb1b0
3 changed files with 31 additions and 31 deletions
+12 -12
View File
@@ -16,9 +16,9 @@ goog.require('ol.proj.Units');
* @constructor
* @extends {ol.proj.Projection}
* @param {string} code Code.
* @api
* @private
*/
ol.proj.EPSG3857 = function(code) {
ol.proj.EPSG3857_ = function(code) {
goog.base(this, {
code: code,
units: ol.proj.Units.METERS,
@@ -26,7 +26,15 @@ ol.proj.EPSG3857 = function(code) {
global: true
});
};
goog.inherits(ol.proj.EPSG3857, ol.proj.Projection);
goog.inherits(ol.proj.EPSG3857_, ol.proj.Projection);
/**
* @inheritDoc
*/
ol.proj.EPSG3857_.prototype.getPointResolution = function(resolution, point) {
return resolution / ol.math.cosh(point[1] / ol.proj.EPSG3857.RADIUS);
};
/**
@@ -77,7 +85,7 @@ ol.proj.EPSG3857.CODES = [
ol.proj.EPSG3857.PROJECTIONS = goog.array.map(
ol.proj.EPSG3857.CODES,
function(code) {
return new ol.proj.EPSG3857(code);
return new ol.proj.EPSG3857_(code);
});
@@ -139,11 +147,3 @@ ol.proj.EPSG3857.toEPSG4326 = function(input, opt_output, opt_dimension) {
}
return output;
};
/**
* @inheritDoc
*/
ol.proj.EPSG3857.prototype.getPointResolution = function(resolution, point) {
return resolution / ol.math.cosh(point[1] / ol.proj.EPSG3857.RADIUS);
};