Rename _ol_Collection_.Property_ to Property
This commit is contained in:
+12
-14
@@ -8,6 +8,16 @@ import _ol_Object_ from './Object.js';
|
|||||||
import Event from './events/Event.js';
|
import Event from './events/Event.js';
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @enum {string}
|
||||||
|
* @private
|
||||||
|
*/
|
||||||
|
var Property = {
|
||||||
|
LENGTH: 'length'
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef {{unique: (boolean|undefined)}}
|
* @typedef {{unique: (boolean|undefined)}}
|
||||||
*/
|
*/
|
||||||
@@ -139,9 +149,7 @@ _ol_Collection_.prototype.item = function(index) {
|
|||||||
* @api
|
* @api
|
||||||
*/
|
*/
|
||||||
_ol_Collection_.prototype.getLength = function() {
|
_ol_Collection_.prototype.getLength = function() {
|
||||||
return (
|
return (/** @type {number} */ this.get(Property.LENGTH));
|
||||||
/** @type {number} */ this.get(_ol_Collection_.Property_.LENGTH)
|
|
||||||
);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@@ -256,7 +264,7 @@ _ol_Collection_.prototype.setAt = function(index, elem) {
|
|||||||
* @private
|
* @private
|
||||||
*/
|
*/
|
||||||
_ol_Collection_.prototype.updateLength_ = function() {
|
_ol_Collection_.prototype.updateLength_ = function() {
|
||||||
this.set(_ol_Collection_.Property_.LENGTH, this.array_.length);
|
this.set(Property.LENGTH, this.array_.length);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
@@ -273,16 +281,6 @@ _ol_Collection_.prototype.assertUnique_ = function(elem, opt_except) {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @enum {string}
|
|
||||||
* @private
|
|
||||||
*/
|
|
||||||
_ol_Collection_.Property_ = {
|
|
||||||
LENGTH: 'length'
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @classdesc
|
* @classdesc
|
||||||
* Events emitted by {@link ol.Collection} instances are instances of this
|
* Events emitted by {@link ol.Collection} instances are instances of this
|
||||||
|
|||||||
Reference in New Issue
Block a user