Making ol.proj.Projection subclasses exportable

Because ol.proj.EPSG4326 et al. extend ol.proj.Projection which has exportable methods, these constructors need to be exportable as well (e.g. so ol.proj.EPSG4326.prototype is defined in exports.js when calling goog.exportProperty on getCode etc.).  If we really don't want these to be exportable, they should be removed or made private (and named like ol.proj.EPSG4326_) for internal use only.
This commit is contained in:
Tim Schaub
2014-04-28 20:53:12 -06:00
parent ec6aa21912
commit d552dfd96d
3 changed files with 5 additions and 0 deletions

View File

@@ -17,6 +17,7 @@ goog.require('ol.proj.Units');
* @constructor
* @extends {ol.proj.Projection}
* @param {{code: string, extent: ol.Extent}} options Options.
* @todo api
*/
ol.proj.CH = function(options) {
goog.base(this, {
@@ -395,6 +396,7 @@ ol.proj.CH.prototype.getPointResolution = function(resolution, point) {
* The EPSG:2056 projection, also known as LV95 (CH1903+).
* @constructor
* @extends {ol.proj.CH}
* @todo api
*/
ol.proj.EPSG2056 = function() {
goog.base(this, {
@@ -433,6 +435,7 @@ ol.proj.EPSG2056.add = function() {
* The EPSG:21781 projection, also known as LV03 (CH1903).
* @constructor
* @extends {ol.proj.CH}
* @todo api
*/
ol.proj.EPSG21781 = function() {
goog.base(this, {

View File

@@ -13,6 +13,7 @@ goog.require('ol.proj.Units');
* @constructor
* @extends {ol.proj.Projection}
* @param {string} code Code.
* @todo api
*/
ol.proj.EPSG3857 = function(code) {
goog.base(this, {

View File

@@ -11,6 +11,7 @@ goog.require('ol.proj.Units');
* @extends {ol.proj.Projection}
* @param {string} code Code.
* @param {string=} opt_axisOrientation Axis orientation.
* @todo api
*/
ol.proj.EPSG4326 = function(code, opt_axisOrientation) {
goog.base(this, {