This commit is contained in:
158
node_modules/ol/structs/LRUCache.d.ts
generated
vendored
Normal file
158
node_modules/ol/structs/LRUCache.d.ts
generated
vendored
Normal file
@@ -0,0 +1,158 @@
|
||||
export default LRUCache;
|
||||
export type Entry = {
|
||||
/**
|
||||
* Key.
|
||||
*/
|
||||
key_: string;
|
||||
/**
|
||||
* Newer.
|
||||
*/
|
||||
newer: any;
|
||||
/**
|
||||
* Older.
|
||||
*/
|
||||
older: any;
|
||||
/**
|
||||
* Value.
|
||||
*/
|
||||
value_: any;
|
||||
};
|
||||
/**
|
||||
* @typedef {Object} Entry
|
||||
* @property {string} key_ Key.
|
||||
* @property {Object} newer Newer.
|
||||
* @property {Object} older Older.
|
||||
* @property {*} value_ Value.
|
||||
*/
|
||||
/**
|
||||
* @classdesc
|
||||
* Implements a Least-Recently-Used cache where the keys do not conflict with
|
||||
* Object's properties (e.g. 'hasOwnProperty' is not allowed as a key). Expiring
|
||||
* items from the cache is the responsibility of the user.
|
||||
*
|
||||
* @fires import("../events/Event.js").default
|
||||
* @template T
|
||||
*/
|
||||
declare class LRUCache<T> {
|
||||
/**
|
||||
* @param {number} [opt_highWaterMark] High water mark.
|
||||
*/
|
||||
constructor(opt_highWaterMark?: number | undefined);
|
||||
/**
|
||||
* Desired max cache size after expireCache(). If set to 0, no cache entries
|
||||
* will be pruned at all.
|
||||
* @type {number}
|
||||
*/
|
||||
highWaterMark: number;
|
||||
/**
|
||||
* @private
|
||||
* @type {number}
|
||||
*/
|
||||
private count_;
|
||||
/**
|
||||
* @private
|
||||
* @type {!Object<string, Entry>}
|
||||
*/
|
||||
private entries_;
|
||||
/**
|
||||
* @private
|
||||
* @type {?Entry}
|
||||
*/
|
||||
private oldest_;
|
||||
/**
|
||||
* @private
|
||||
* @type {?Entry}
|
||||
*/
|
||||
private newest_;
|
||||
/**
|
||||
* @return {boolean} Can expire cache.
|
||||
*/
|
||||
canExpireCache(): boolean;
|
||||
/**
|
||||
* Expire the cache.
|
||||
* @param {!Object<string, boolean>} [keep] Keys to keep. To be implemented by subclasses.
|
||||
*/
|
||||
expireCache(keep?: {
|
||||
[x: string]: boolean;
|
||||
} | undefined): void;
|
||||
/**
|
||||
* FIXME empty description for jsdoc
|
||||
*/
|
||||
clear(): void;
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @return {boolean} Contains key.
|
||||
*/
|
||||
containsKey(key: string): boolean;
|
||||
/**
|
||||
* @param {function(T, string, LRUCache<T>): ?} f The function
|
||||
* to call for every entry from the oldest to the newer. This function takes
|
||||
* 3 arguments (the entry value, the entry key and the LRUCache object).
|
||||
* The return value is ignored.
|
||||
*/
|
||||
forEach(f: (arg0: T, arg1: string, arg2: LRUCache<T>) => unknown): void;
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @param {*} [opt_options] Options (reserved for subclasses).
|
||||
* @return {T} Value.
|
||||
*/
|
||||
get(key: string, opt_options?: any): T;
|
||||
/**
|
||||
* Remove an entry from the cache.
|
||||
* @param {string} key The entry key.
|
||||
* @return {T} The removed entry.
|
||||
*/
|
||||
remove(key: string): T;
|
||||
/**
|
||||
* @return {number} Count.
|
||||
*/
|
||||
getCount(): number;
|
||||
/**
|
||||
* @return {Array<string>} Keys.
|
||||
*/
|
||||
getKeys(): Array<string>;
|
||||
/**
|
||||
* @return {Array<T>} Values.
|
||||
*/
|
||||
getValues(): Array<T>;
|
||||
/**
|
||||
* @return {T} Last value.
|
||||
*/
|
||||
peekLast(): T;
|
||||
/**
|
||||
* @return {string} Last key.
|
||||
*/
|
||||
peekLastKey(): string;
|
||||
/**
|
||||
* Get the key of the newest item in the cache. Throws if the cache is empty.
|
||||
* @return {string} The newest key.
|
||||
*/
|
||||
peekFirstKey(): string;
|
||||
/**
|
||||
* Return an entry without updating least recently used time.
|
||||
* @param {string} key Key.
|
||||
* @return {T} Value.
|
||||
*/
|
||||
peek(key: string): T;
|
||||
/**
|
||||
* @return {T} value Value.
|
||||
*/
|
||||
pop(): T;
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @param {T} value Value.
|
||||
*/
|
||||
replace(key: string, value: T): void;
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @param {T} value Value.
|
||||
*/
|
||||
set(key: string, value: T): void;
|
||||
/**
|
||||
* Set a maximum number of entries for the cache.
|
||||
* @param {number} size Cache size.
|
||||
* @api
|
||||
*/
|
||||
setSize(size: number): void;
|
||||
}
|
||||
//# sourceMappingURL=LRUCache.d.ts.map
|
||||
1
node_modules/ol/structs/LRUCache.d.ts.map
generated
vendored
Normal file
1
node_modules/ol/structs/LRUCache.d.ts.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"LRUCache.d.ts","sourceRoot":"","sources":["../src/structs/LRUCache.js"],"names":[],"mappings":";;;;;UAQc,MAAM;;;;;;;;;;;;;;AAFpB;;;;;;GAMG;AAEH;;;;;;;;GAQG;AACH;IACE;;OAEG;IACH,oDAgCC;IA/BC;;;;OAIG;IACH,eAFU,MAAM,CAG4C;IAE5D;;;OAGG;IACH,eAAe;IAEf;;;OAGG;IACH,iBAAkB;IAElB;;;OAGG;IACH,gBAAmB;IAEnB;;;OAGG;IACH,gBAAmB;IAGrB;;OAEG;IACH,kBAFY,OAAO,CAIlB;IAED;;;OAGG;IACH;;yBAIC;IAED;;OAEG;IACH,cAKC;IAED;;;OAGG;IACH,iBAHW,MAAM,GACL,OAAO,CAIlB;IAED;;;;;OAKG;IACH,kBALoB,CAAC,QAAE,MAAM,QAAE,SAAS,CAAC,CAAC,oBAWzC;IAED;;;;OAIG;IACH,SAJW,MAAM,sBAEL,CAAC,CAmBZ;IAED;;;;OAIG;IACH,YAHW,MAAM,GACL,CAAC,CAsBZ;IAED;;OAEG;IACH,YAFY,MAAM,CAIjB;IAED;;OAEG;IACH,WAFY,MAAM,MAAM,CAAC,CAUxB;IAED;;OAEG;IACH,aAFY,MAAM,CAAC,CAAC,CAUnB;IAED;;OAEG;IACH,YAFY,CAAC,CAIZ;IAED;;OAEG;IACH,eAFY,MAAM,CAIjB;IAED;;;OAGG;IACH,gBAFY,MAAM,CAIjB;IAED;;;;OAIG;IACH,UAHW,MAAM,GACL,CAAC,CAOZ;IAED;;OAEG;IACH,OAFY,CAAC,CAcZ;IAED;;;OAGG;IACH,aAHW,MAAM,SACN,CAAC,QAKX;IAED;;;OAGG;IACH,SAHW,MAAM,SACN,CAAC,QAkBX;IAED;;;;OAIG;IACH,cAHW,MAAM,QAKhB;CACF"}
|
||||
268
node_modules/ol/structs/LRUCache.js
generated
vendored
Normal file
268
node_modules/ol/structs/LRUCache.js
generated
vendored
Normal file
@@ -0,0 +1,268 @@
|
||||
/**
|
||||
* @module ol/structs/LRUCache
|
||||
*/
|
||||
import { assert } from '../asserts.js';
|
||||
/**
|
||||
* @typedef {Object} Entry
|
||||
* @property {string} key_ Key.
|
||||
* @property {Object} newer Newer.
|
||||
* @property {Object} older Older.
|
||||
* @property {*} value_ Value.
|
||||
*/
|
||||
/**
|
||||
* @classdesc
|
||||
* Implements a Least-Recently-Used cache where the keys do not conflict with
|
||||
* Object's properties (e.g. 'hasOwnProperty' is not allowed as a key). Expiring
|
||||
* items from the cache is the responsibility of the user.
|
||||
*
|
||||
* @fires import("../events/Event.js").default
|
||||
* @template T
|
||||
*/
|
||||
var LRUCache = /** @class */ (function () {
|
||||
/**
|
||||
* @param {number} [opt_highWaterMark] High water mark.
|
||||
*/
|
||||
function LRUCache(opt_highWaterMark) {
|
||||
/**
|
||||
* Desired max cache size after expireCache(). If set to 0, no cache entries
|
||||
* will be pruned at all.
|
||||
* @type {number}
|
||||
*/
|
||||
this.highWaterMark =
|
||||
opt_highWaterMark !== undefined ? opt_highWaterMark : 2048;
|
||||
/**
|
||||
* @private
|
||||
* @type {number}
|
||||
*/
|
||||
this.count_ = 0;
|
||||
/**
|
||||
* @private
|
||||
* @type {!Object<string, Entry>}
|
||||
*/
|
||||
this.entries_ = {};
|
||||
/**
|
||||
* @private
|
||||
* @type {?Entry}
|
||||
*/
|
||||
this.oldest_ = null;
|
||||
/**
|
||||
* @private
|
||||
* @type {?Entry}
|
||||
*/
|
||||
this.newest_ = null;
|
||||
}
|
||||
/**
|
||||
* @return {boolean} Can expire cache.
|
||||
*/
|
||||
LRUCache.prototype.canExpireCache = function () {
|
||||
return this.highWaterMark > 0 && this.getCount() > this.highWaterMark;
|
||||
};
|
||||
/**
|
||||
* Expire the cache.
|
||||
* @param {!Object<string, boolean>} [keep] Keys to keep. To be implemented by subclasses.
|
||||
*/
|
||||
LRUCache.prototype.expireCache = function (keep) {
|
||||
while (this.canExpireCache()) {
|
||||
this.pop();
|
||||
}
|
||||
};
|
||||
/**
|
||||
* FIXME empty description for jsdoc
|
||||
*/
|
||||
LRUCache.prototype.clear = function () {
|
||||
this.count_ = 0;
|
||||
this.entries_ = {};
|
||||
this.oldest_ = null;
|
||||
this.newest_ = null;
|
||||
};
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @return {boolean} Contains key.
|
||||
*/
|
||||
LRUCache.prototype.containsKey = function (key) {
|
||||
return this.entries_.hasOwnProperty(key);
|
||||
};
|
||||
/**
|
||||
* @param {function(T, string, LRUCache<T>): ?} f The function
|
||||
* to call for every entry from the oldest to the newer. This function takes
|
||||
* 3 arguments (the entry value, the entry key and the LRUCache object).
|
||||
* The return value is ignored.
|
||||
*/
|
||||
LRUCache.prototype.forEach = function (f) {
|
||||
var entry = this.oldest_;
|
||||
while (entry) {
|
||||
f(entry.value_, entry.key_, this);
|
||||
entry = entry.newer;
|
||||
}
|
||||
};
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @param {*} [opt_options] Options (reserved for subclasses).
|
||||
* @return {T} Value.
|
||||
*/
|
||||
LRUCache.prototype.get = function (key, opt_options) {
|
||||
var entry = this.entries_[key];
|
||||
assert(entry !== undefined, 15); // Tried to get a value for a key that does not exist in the cache
|
||||
if (entry === this.newest_) {
|
||||
return entry.value_;
|
||||
}
|
||||
else if (entry === this.oldest_) {
|
||||
this.oldest_ = /** @type {Entry} */ (this.oldest_.newer);
|
||||
this.oldest_.older = null;
|
||||
}
|
||||
else {
|
||||
entry.newer.older = entry.older;
|
||||
entry.older.newer = entry.newer;
|
||||
}
|
||||
entry.newer = null;
|
||||
entry.older = this.newest_;
|
||||
this.newest_.newer = entry;
|
||||
this.newest_ = entry;
|
||||
return entry.value_;
|
||||
};
|
||||
/**
|
||||
* Remove an entry from the cache.
|
||||
* @param {string} key The entry key.
|
||||
* @return {T} The removed entry.
|
||||
*/
|
||||
LRUCache.prototype.remove = function (key) {
|
||||
var entry = this.entries_[key];
|
||||
assert(entry !== undefined, 15); // Tried to get a value for a key that does not exist in the cache
|
||||
if (entry === this.newest_) {
|
||||
this.newest_ = /** @type {Entry} */ (entry.older);
|
||||
if (this.newest_) {
|
||||
this.newest_.newer = null;
|
||||
}
|
||||
}
|
||||
else if (entry === this.oldest_) {
|
||||
this.oldest_ = /** @type {Entry} */ (entry.newer);
|
||||
if (this.oldest_) {
|
||||
this.oldest_.older = null;
|
||||
}
|
||||
}
|
||||
else {
|
||||
entry.newer.older = entry.older;
|
||||
entry.older.newer = entry.newer;
|
||||
}
|
||||
delete this.entries_[key];
|
||||
--this.count_;
|
||||
return entry.value_;
|
||||
};
|
||||
/**
|
||||
* @return {number} Count.
|
||||
*/
|
||||
LRUCache.prototype.getCount = function () {
|
||||
return this.count_;
|
||||
};
|
||||
/**
|
||||
* @return {Array<string>} Keys.
|
||||
*/
|
||||
LRUCache.prototype.getKeys = function () {
|
||||
var keys = new Array(this.count_);
|
||||
var i = 0;
|
||||
var entry;
|
||||
for (entry = this.newest_; entry; entry = entry.older) {
|
||||
keys[i++] = entry.key_;
|
||||
}
|
||||
return keys;
|
||||
};
|
||||
/**
|
||||
* @return {Array<T>} Values.
|
||||
*/
|
||||
LRUCache.prototype.getValues = function () {
|
||||
var values = new Array(this.count_);
|
||||
var i = 0;
|
||||
var entry;
|
||||
for (entry = this.newest_; entry; entry = entry.older) {
|
||||
values[i++] = entry.value_;
|
||||
}
|
||||
return values;
|
||||
};
|
||||
/**
|
||||
* @return {T} Last value.
|
||||
*/
|
||||
LRUCache.prototype.peekLast = function () {
|
||||
return this.oldest_.value_;
|
||||
};
|
||||
/**
|
||||
* @return {string} Last key.
|
||||
*/
|
||||
LRUCache.prototype.peekLastKey = function () {
|
||||
return this.oldest_.key_;
|
||||
};
|
||||
/**
|
||||
* Get the key of the newest item in the cache. Throws if the cache is empty.
|
||||
* @return {string} The newest key.
|
||||
*/
|
||||
LRUCache.prototype.peekFirstKey = function () {
|
||||
return this.newest_.key_;
|
||||
};
|
||||
/**
|
||||
* Return an entry without updating least recently used time.
|
||||
* @param {string} key Key.
|
||||
* @return {T} Value.
|
||||
*/
|
||||
LRUCache.prototype.peek = function (key) {
|
||||
if (!this.containsKey(key)) {
|
||||
return undefined;
|
||||
}
|
||||
return this.entries_[key].value_;
|
||||
};
|
||||
/**
|
||||
* @return {T} value Value.
|
||||
*/
|
||||
LRUCache.prototype.pop = function () {
|
||||
var entry = this.oldest_;
|
||||
delete this.entries_[entry.key_];
|
||||
if (entry.newer) {
|
||||
entry.newer.older = null;
|
||||
}
|
||||
this.oldest_ = /** @type {Entry} */ (entry.newer);
|
||||
if (!this.oldest_) {
|
||||
this.newest_ = null;
|
||||
}
|
||||
--this.count_;
|
||||
return entry.value_;
|
||||
};
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @param {T} value Value.
|
||||
*/
|
||||
LRUCache.prototype.replace = function (key, value) {
|
||||
this.get(key); // update `newest_`
|
||||
this.entries_[key].value_ = value;
|
||||
};
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @param {T} value Value.
|
||||
*/
|
||||
LRUCache.prototype.set = function (key, value) {
|
||||
assert(!(key in this.entries_), 16); // Tried to set a value for a key that is used already
|
||||
var entry = {
|
||||
key_: key,
|
||||
newer: null,
|
||||
older: this.newest_,
|
||||
value_: value,
|
||||
};
|
||||
if (!this.newest_) {
|
||||
this.oldest_ = entry;
|
||||
}
|
||||
else {
|
||||
this.newest_.newer = entry;
|
||||
}
|
||||
this.newest_ = entry;
|
||||
this.entries_[key] = entry;
|
||||
++this.count_;
|
||||
};
|
||||
/**
|
||||
* Set a maximum number of entries for the cache.
|
||||
* @param {number} size Cache size.
|
||||
* @api
|
||||
*/
|
||||
LRUCache.prototype.setSize = function (size) {
|
||||
this.highWaterMark = size;
|
||||
};
|
||||
return LRUCache;
|
||||
}());
|
||||
export default LRUCache;
|
||||
//# sourceMappingURL=LRUCache.js.map
|
||||
1
node_modules/ol/structs/LRUCache.js.map
generated
vendored
Normal file
1
node_modules/ol/structs/LRUCache.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
130
node_modules/ol/structs/LinkedList.d.ts
generated
vendored
Normal file
130
node_modules/ol/structs/LinkedList.d.ts
generated
vendored
Normal file
@@ -0,0 +1,130 @@
|
||||
export default LinkedList;
|
||||
export type Item = {
|
||||
/**
|
||||
* Previous.
|
||||
*/
|
||||
prev?: Item | undefined;
|
||||
/**
|
||||
* Next.
|
||||
*/
|
||||
next?: Item | undefined;
|
||||
/**
|
||||
* Data.
|
||||
*/
|
||||
data: unknown;
|
||||
};
|
||||
/**
|
||||
* @module ol/structs/LinkedList
|
||||
*/
|
||||
/**
|
||||
* @typedef {Object} Item
|
||||
* @property {Item} [prev] Previous.
|
||||
* @property {Item} [next] Next.
|
||||
* @property {?} data Data.
|
||||
*/
|
||||
/**
|
||||
* @classdesc
|
||||
* Creates an empty linked list structure.
|
||||
*/
|
||||
declare class LinkedList {
|
||||
/**
|
||||
* @param {boolean} [opt_circular] The last item is connected to the first one,
|
||||
* and the first item to the last one. Default is true.
|
||||
*/
|
||||
constructor(opt_circular?: boolean | undefined);
|
||||
/**
|
||||
* @private
|
||||
* @type {Item|undefined}
|
||||
*/
|
||||
private first_;
|
||||
/**
|
||||
* @private
|
||||
* @type {Item|undefined}
|
||||
*/
|
||||
private last_;
|
||||
/**
|
||||
* @private
|
||||
* @type {Item|undefined}
|
||||
*/
|
||||
private head_;
|
||||
/**
|
||||
* @private
|
||||
* @type {boolean}
|
||||
*/
|
||||
private circular_;
|
||||
/**
|
||||
* @private
|
||||
* @type {number}
|
||||
*/
|
||||
private length_;
|
||||
/**
|
||||
* Inserts an item into the linked list right after the current one.
|
||||
*
|
||||
* @param {?} data Item data.
|
||||
*/
|
||||
insertItem(data: unknown): void;
|
||||
/**
|
||||
* Removes the current item from the list. Sets the cursor to the next item,
|
||||
* if possible.
|
||||
*/
|
||||
removeItem(): void;
|
||||
/**
|
||||
* Sets the cursor to the first item, and returns the associated data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
firstItem(): unknown;
|
||||
/**
|
||||
* Sets the cursor to the last item, and returns the associated data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
lastItem(): unknown;
|
||||
/**
|
||||
* Sets the cursor to the next item, and returns the associated data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
nextItem(): unknown;
|
||||
/**
|
||||
* Returns the next item's data without moving the cursor.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
getNextItem(): unknown;
|
||||
/**
|
||||
* Sets the cursor to the previous item, and returns the associated data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
prevItem(): unknown;
|
||||
/**
|
||||
* Returns the previous item's data without moving the cursor.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
getPrevItem(): unknown;
|
||||
/**
|
||||
* Returns the current item's data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
getCurrItem(): unknown;
|
||||
/**
|
||||
* Sets the first item of the list. This only works for circular lists, and sets
|
||||
* the last item accordingly.
|
||||
*/
|
||||
setFirstItem(): void;
|
||||
/**
|
||||
* Concatenates two lists.
|
||||
* @param {LinkedList} list List to merge into the current list.
|
||||
*/
|
||||
concat(list: LinkedList): void;
|
||||
/**
|
||||
* Returns the current length of the list.
|
||||
*
|
||||
* @return {number} Length.
|
||||
*/
|
||||
getLength(): number;
|
||||
}
|
||||
//# sourceMappingURL=LinkedList.d.ts.map
|
||||
1
node_modules/ol/structs/LinkedList.d.ts.map
generated
vendored
Normal file
1
node_modules/ol/structs/LinkedList.d.ts.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"LinkedList.d.ts","sourceRoot":"","sources":["../src/structs/LinkedList.js"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA;;GAEG;AAEH;;;;;GAKG;AAEH;;;GAGG;AACH;IACE;;;OAGG;IACH,gDA8BC;IA7BC;;;OAGG;IACH,eAAW;IAEX;;;OAGG;IACH,cAAU;IAEV;;;OAGG;IACH,cAAU;IAEV;;;OAGG;IACH,kBAAiE;IAEjE;;;OAGG;IACH,gBAAgB;IAGlB;;;;OAIG;IACH,gCAkCC;IAED;;;OAGG;IACH,mBAwBC;IAED;;;;OAIG;IACH,qBAMC;IAED;;;;OAIG;IACH,oBAMC;IAED;;;;OAIG;IACH,oBAMC;IAED;;;;OAIG;IACH,uBAKC;IAED;;;;OAIG;IACH,oBAMC;IAED;;;;OAIG;IACH,uBAKC;IAED;;;;OAIG;IACH,uBAKC;IAED;;;OAGG;IACH,qBAKC;IAED;;;OAGG;IACH,aAFW,UAAU,QAsBpB;IAED;;;;OAIG;IACH,aAFY,MAAM,CAIjB;CACF"}
|
||||
242
node_modules/ol/structs/LinkedList.js
generated
vendored
Normal file
242
node_modules/ol/structs/LinkedList.js
generated
vendored
Normal file
@@ -0,0 +1,242 @@
|
||||
/**
|
||||
* @module ol/structs/LinkedList
|
||||
*/
|
||||
/**
|
||||
* @typedef {Object} Item
|
||||
* @property {Item} [prev] Previous.
|
||||
* @property {Item} [next] Next.
|
||||
* @property {?} data Data.
|
||||
*/
|
||||
/**
|
||||
* @classdesc
|
||||
* Creates an empty linked list structure.
|
||||
*/
|
||||
var LinkedList = /** @class */ (function () {
|
||||
/**
|
||||
* @param {boolean} [opt_circular] The last item is connected to the first one,
|
||||
* and the first item to the last one. Default is true.
|
||||
*/
|
||||
function LinkedList(opt_circular) {
|
||||
/**
|
||||
* @private
|
||||
* @type {Item|undefined}
|
||||
*/
|
||||
this.first_;
|
||||
/**
|
||||
* @private
|
||||
* @type {Item|undefined}
|
||||
*/
|
||||
this.last_;
|
||||
/**
|
||||
* @private
|
||||
* @type {Item|undefined}
|
||||
*/
|
||||
this.head_;
|
||||
/**
|
||||
* @private
|
||||
* @type {boolean}
|
||||
*/
|
||||
this.circular_ = opt_circular === undefined ? true : opt_circular;
|
||||
/**
|
||||
* @private
|
||||
* @type {number}
|
||||
*/
|
||||
this.length_ = 0;
|
||||
}
|
||||
/**
|
||||
* Inserts an item into the linked list right after the current one.
|
||||
*
|
||||
* @param {?} data Item data.
|
||||
*/
|
||||
LinkedList.prototype.insertItem = function (data) {
|
||||
/** @type {Item} */
|
||||
var item = {
|
||||
prev: undefined,
|
||||
next: undefined,
|
||||
data: data,
|
||||
};
|
||||
var head = this.head_;
|
||||
//Initialize the list.
|
||||
if (!head) {
|
||||
this.first_ = item;
|
||||
this.last_ = item;
|
||||
if (this.circular_) {
|
||||
item.next = item;
|
||||
item.prev = item;
|
||||
}
|
||||
}
|
||||
else {
|
||||
//Link the new item to the adjacent ones.
|
||||
var next = head.next;
|
||||
item.prev = head;
|
||||
item.next = next;
|
||||
head.next = item;
|
||||
if (next) {
|
||||
next.prev = item;
|
||||
}
|
||||
if (head === this.last_) {
|
||||
this.last_ = item;
|
||||
}
|
||||
}
|
||||
this.head_ = item;
|
||||
this.length_++;
|
||||
};
|
||||
/**
|
||||
* Removes the current item from the list. Sets the cursor to the next item,
|
||||
* if possible.
|
||||
*/
|
||||
LinkedList.prototype.removeItem = function () {
|
||||
var head = this.head_;
|
||||
if (head) {
|
||||
var next = head.next;
|
||||
var prev = head.prev;
|
||||
if (next) {
|
||||
next.prev = prev;
|
||||
}
|
||||
if (prev) {
|
||||
prev.next = next;
|
||||
}
|
||||
this.head_ = next || prev;
|
||||
if (this.first_ === this.last_) {
|
||||
this.head_ = undefined;
|
||||
this.first_ = undefined;
|
||||
this.last_ = undefined;
|
||||
}
|
||||
else if (this.first_ === head) {
|
||||
this.first_ = this.head_;
|
||||
}
|
||||
else if (this.last_ === head) {
|
||||
this.last_ = prev ? this.head_.prev : this.head_;
|
||||
}
|
||||
this.length_--;
|
||||
}
|
||||
};
|
||||
/**
|
||||
* Sets the cursor to the first item, and returns the associated data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
LinkedList.prototype.firstItem = function () {
|
||||
this.head_ = this.first_;
|
||||
if (this.head_) {
|
||||
return this.head_.data;
|
||||
}
|
||||
return undefined;
|
||||
};
|
||||
/**
|
||||
* Sets the cursor to the last item, and returns the associated data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
LinkedList.prototype.lastItem = function () {
|
||||
this.head_ = this.last_;
|
||||
if (this.head_) {
|
||||
return this.head_.data;
|
||||
}
|
||||
return undefined;
|
||||
};
|
||||
/**
|
||||
* Sets the cursor to the next item, and returns the associated data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
LinkedList.prototype.nextItem = function () {
|
||||
if (this.head_ && this.head_.next) {
|
||||
this.head_ = this.head_.next;
|
||||
return this.head_.data;
|
||||
}
|
||||
return undefined;
|
||||
};
|
||||
/**
|
||||
* Returns the next item's data without moving the cursor.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
LinkedList.prototype.getNextItem = function () {
|
||||
if (this.head_ && this.head_.next) {
|
||||
return this.head_.next.data;
|
||||
}
|
||||
return undefined;
|
||||
};
|
||||
/**
|
||||
* Sets the cursor to the previous item, and returns the associated data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
LinkedList.prototype.prevItem = function () {
|
||||
if (this.head_ && this.head_.prev) {
|
||||
this.head_ = this.head_.prev;
|
||||
return this.head_.data;
|
||||
}
|
||||
return undefined;
|
||||
};
|
||||
/**
|
||||
* Returns the previous item's data without moving the cursor.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
LinkedList.prototype.getPrevItem = function () {
|
||||
if (this.head_ && this.head_.prev) {
|
||||
return this.head_.prev.data;
|
||||
}
|
||||
return undefined;
|
||||
};
|
||||
/**
|
||||
* Returns the current item's data.
|
||||
*
|
||||
* @return {?} Item data.
|
||||
*/
|
||||
LinkedList.prototype.getCurrItem = function () {
|
||||
if (this.head_) {
|
||||
return this.head_.data;
|
||||
}
|
||||
return undefined;
|
||||
};
|
||||
/**
|
||||
* Sets the first item of the list. This only works for circular lists, and sets
|
||||
* the last item accordingly.
|
||||
*/
|
||||
LinkedList.prototype.setFirstItem = function () {
|
||||
if (this.circular_ && this.head_) {
|
||||
this.first_ = this.head_;
|
||||
this.last_ = this.head_.prev;
|
||||
}
|
||||
};
|
||||
/**
|
||||
* Concatenates two lists.
|
||||
* @param {LinkedList} list List to merge into the current list.
|
||||
*/
|
||||
LinkedList.prototype.concat = function (list) {
|
||||
if (list.head_) {
|
||||
if (this.head_) {
|
||||
var end = this.head_.next;
|
||||
this.head_.next = list.first_;
|
||||
list.first_.prev = this.head_;
|
||||
end.prev = list.last_;
|
||||
list.last_.next = end;
|
||||
this.length_ += list.length_;
|
||||
}
|
||||
else {
|
||||
this.head_ = list.head_;
|
||||
this.first_ = list.first_;
|
||||
this.last_ = list.last_;
|
||||
this.length_ = list.length_;
|
||||
}
|
||||
list.head_ = undefined;
|
||||
list.first_ = undefined;
|
||||
list.last_ = undefined;
|
||||
list.length_ = 0;
|
||||
}
|
||||
};
|
||||
/**
|
||||
* Returns the current length of the list.
|
||||
*
|
||||
* @return {number} Length.
|
||||
*/
|
||||
LinkedList.prototype.getLength = function () {
|
||||
return this.length_;
|
||||
};
|
||||
return LinkedList;
|
||||
}());
|
||||
export default LinkedList;
|
||||
//# sourceMappingURL=LinkedList.js.map
|
||||
1
node_modules/ol/structs/LinkedList.js.map
generated
vendored
Normal file
1
node_modules/ol/structs/LinkedList.js.map
generated
vendored
Normal file
@@ -0,0 +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ACvB,IAAI,CAAC,OAAO,GAAG,CAAC,CAAC;SAClB;IACH,CAAC;IAED;;;;OAIG;IACH,8BAAS,GAAT;QACE,OAAO,IAAI,CAAC,OAAO,CAAC;IACtB,CAAC;IACH,iBAAC;AAAD,CAAC,AAjPD,IAiPC;AAED,eAAe,UAAU,CAAC"}
|
||||
124
node_modules/ol/structs/PriorityQueue.d.ts
generated
vendored
Normal file
124
node_modules/ol/structs/PriorityQueue.d.ts
generated
vendored
Normal file
@@ -0,0 +1,124 @@
|
||||
/**
|
||||
* @type {number}
|
||||
*/
|
||||
export const DROP: number;
|
||||
export default PriorityQueue;
|
||||
/**
|
||||
* @classdesc
|
||||
* Priority queue.
|
||||
*
|
||||
* The implementation is inspired from the Closure Library's Heap class and
|
||||
* Python's heapq module.
|
||||
*
|
||||
* See https://github.com/google/closure-library/blob/master/closure/goog/structs/heap.js
|
||||
* and https://hg.python.org/cpython/file/2.7/Lib/heapq.py.
|
||||
*
|
||||
* @template T
|
||||
*/
|
||||
declare class PriorityQueue<T> {
|
||||
/**
|
||||
* @param {function(T): number} priorityFunction Priority function.
|
||||
* @param {function(T): string} keyFunction Key function.
|
||||
*/
|
||||
constructor(priorityFunction: (arg0: T) => number, keyFunction: (arg0: T) => string);
|
||||
/**
|
||||
* @type {function(T): number}
|
||||
* @private
|
||||
*/
|
||||
private priorityFunction_;
|
||||
/**
|
||||
* @type {function(T): string}
|
||||
* @private
|
||||
*/
|
||||
private keyFunction_;
|
||||
/**
|
||||
* @type {Array<T>}
|
||||
* @private
|
||||
*/
|
||||
private elements_;
|
||||
/**
|
||||
* @type {Array<number>}
|
||||
* @private
|
||||
*/
|
||||
private priorities_;
|
||||
/**
|
||||
* @type {!Object<string, boolean>}
|
||||
* @private
|
||||
*/
|
||||
private queuedElements_;
|
||||
/**
|
||||
* FIXME empty description for jsdoc
|
||||
*/
|
||||
clear(): void;
|
||||
/**
|
||||
* Remove and return the highest-priority element. O(log N).
|
||||
* @return {T} Element.
|
||||
*/
|
||||
dequeue(): T;
|
||||
/**
|
||||
* Enqueue an element. O(log N).
|
||||
* @param {T} element Element.
|
||||
* @return {boolean} The element was added to the queue.
|
||||
*/
|
||||
enqueue(element: T): boolean;
|
||||
/**
|
||||
* @return {number} Count.
|
||||
*/
|
||||
getCount(): number;
|
||||
/**
|
||||
* Gets the index of the left child of the node at the given index.
|
||||
* @param {number} index The index of the node to get the left child for.
|
||||
* @return {number} The index of the left child.
|
||||
* @private
|
||||
*/
|
||||
private getLeftChildIndex_;
|
||||
/**
|
||||
* Gets the index of the right child of the node at the given index.
|
||||
* @param {number} index The index of the node to get the right child for.
|
||||
* @return {number} The index of the right child.
|
||||
* @private
|
||||
*/
|
||||
private getRightChildIndex_;
|
||||
/**
|
||||
* Gets the index of the parent of the node at the given index.
|
||||
* @param {number} index The index of the node to get the parent for.
|
||||
* @return {number} The index of the parent.
|
||||
* @private
|
||||
*/
|
||||
private getParentIndex_;
|
||||
/**
|
||||
* Make this a heap. O(N).
|
||||
* @private
|
||||
*/
|
||||
private heapify_;
|
||||
/**
|
||||
* @return {boolean} Is empty.
|
||||
*/
|
||||
isEmpty(): boolean;
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @return {boolean} Is key queued.
|
||||
*/
|
||||
isKeyQueued(key: string): boolean;
|
||||
/**
|
||||
* @param {T} element Element.
|
||||
* @return {boolean} Is queued.
|
||||
*/
|
||||
isQueued(element: T): boolean;
|
||||
/**
|
||||
* @param {number} index The index of the node to move down.
|
||||
* @private
|
||||
*/
|
||||
private siftUp_;
|
||||
/**
|
||||
* @param {number} startIndex The index of the root.
|
||||
* @param {number} index The index of the node to move up.
|
||||
* @private
|
||||
*/
|
||||
private siftDown_;
|
||||
/**
|
||||
* FIXME empty description for jsdoc
|
||||
*/
|
||||
reprioritize(): void;
|
||||
}
|
||||
//# sourceMappingURL=PriorityQueue.d.ts.map
|
||||
1
node_modules/ol/structs/PriorityQueue.d.ts.map
generated
vendored
Normal file
1
node_modules/ol/structs/PriorityQueue.d.ts.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"PriorityQueue.d.ts","sourceRoot":"","sources":["../src/structs/PriorityQueue.js"],"names":[],"mappings":"AAMA;;GAEG;AACH,mBAFU,MAAM,CAEa;;AAE7B;;;;;;;;;;;GAWG;AACH;IACE;;;OAGG;IACH,qCAHoB,CAAC,KAAG,MAAM,sBACV,CAAC,KAAG,MAAM,EAgC7B;IA7BC;;;OAGG;IACH,0BAAyC;IAEzC;;;OAGG;IACH,qBAA+B;IAE/B;;;OAGG;IACH,kBAAmB;IAEnB;;;OAGG;IACH,oBAAqB;IAErB;;;OAGG;IACH,wBAAyB;IAG3B;;OAEG;IACH,cAIC;IAED;;;OAGG;IACH,WAFY,CAAC,CAiBZ;IAED;;;;OAIG;IACH,iBAHW,CAAC,GACA,OAAO,CAalB;IAED;;OAEG;IACH,YAFY,MAAM,CAIjB;IAED;;;;;OAKG;IACH,2BAEC;IAED;;;;;OAKG;IACH,4BAEC;IAED;;;;;OAKG;IACH,wBAEC;IAED;;;OAGG;IACH,iBAKC;IAED;;OAEG;IACH,WAFY,OAAO,CAIlB;IAED;;;OAGG;IACH,iBAHW,MAAM,GACL,OAAO,CAIlB;IAED;;;OAGG;IACH,kBAHW,CAAC,GACA,OAAO,CAIlB;IAED;;;OAGG;IACH,gBAyBC;IAED;;;;OAIG;IACH,kBAkBC;IAED;;OAEG;IACH,qBAoBC;CACF"}
|
||||
240
node_modules/ol/structs/PriorityQueue.js
generated
vendored
Normal file
240
node_modules/ol/structs/PriorityQueue.js
generated
vendored
Normal file
@@ -0,0 +1,240 @@
|
||||
/**
|
||||
* @module ol/structs/PriorityQueue
|
||||
*/
|
||||
import { assert } from '../asserts.js';
|
||||
import { clear } from '../obj.js';
|
||||
/**
|
||||
* @type {number}
|
||||
*/
|
||||
export var DROP = Infinity;
|
||||
/**
|
||||
* @classdesc
|
||||
* Priority queue.
|
||||
*
|
||||
* The implementation is inspired from the Closure Library's Heap class and
|
||||
* Python's heapq module.
|
||||
*
|
||||
* See https://github.com/google/closure-library/blob/master/closure/goog/structs/heap.js
|
||||
* and https://hg.python.org/cpython/file/2.7/Lib/heapq.py.
|
||||
*
|
||||
* @template T
|
||||
*/
|
||||
var PriorityQueue = /** @class */ (function () {
|
||||
/**
|
||||
* @param {function(T): number} priorityFunction Priority function.
|
||||
* @param {function(T): string} keyFunction Key function.
|
||||
*/
|
||||
function PriorityQueue(priorityFunction, keyFunction) {
|
||||
/**
|
||||
* @type {function(T): number}
|
||||
* @private
|
||||
*/
|
||||
this.priorityFunction_ = priorityFunction;
|
||||
/**
|
||||
* @type {function(T): string}
|
||||
* @private
|
||||
*/
|
||||
this.keyFunction_ = keyFunction;
|
||||
/**
|
||||
* @type {Array<T>}
|
||||
* @private
|
||||
*/
|
||||
this.elements_ = [];
|
||||
/**
|
||||
* @type {Array<number>}
|
||||
* @private
|
||||
*/
|
||||
this.priorities_ = [];
|
||||
/**
|
||||
* @type {!Object<string, boolean>}
|
||||
* @private
|
||||
*/
|
||||
this.queuedElements_ = {};
|
||||
}
|
||||
/**
|
||||
* FIXME empty description for jsdoc
|
||||
*/
|
||||
PriorityQueue.prototype.clear = function () {
|
||||
this.elements_.length = 0;
|
||||
this.priorities_.length = 0;
|
||||
clear(this.queuedElements_);
|
||||
};
|
||||
/**
|
||||
* Remove and return the highest-priority element. O(log N).
|
||||
* @return {T} Element.
|
||||
*/
|
||||
PriorityQueue.prototype.dequeue = function () {
|
||||
var elements = this.elements_;
|
||||
var priorities = this.priorities_;
|
||||
var element = elements[0];
|
||||
if (elements.length == 1) {
|
||||
elements.length = 0;
|
||||
priorities.length = 0;
|
||||
}
|
||||
else {
|
||||
elements[0] = elements.pop();
|
||||
priorities[0] = priorities.pop();
|
||||
this.siftUp_(0);
|
||||
}
|
||||
var elementKey = this.keyFunction_(element);
|
||||
delete this.queuedElements_[elementKey];
|
||||
return element;
|
||||
};
|
||||
/**
|
||||
* Enqueue an element. O(log N).
|
||||
* @param {T} element Element.
|
||||
* @return {boolean} The element was added to the queue.
|
||||
*/
|
||||
PriorityQueue.prototype.enqueue = function (element) {
|
||||
assert(!(this.keyFunction_(element) in this.queuedElements_), 31); // Tried to enqueue an `element` that was already added to the queue
|
||||
var priority = this.priorityFunction_(element);
|
||||
if (priority != DROP) {
|
||||
this.elements_.push(element);
|
||||
this.priorities_.push(priority);
|
||||
this.queuedElements_[this.keyFunction_(element)] = true;
|
||||
this.siftDown_(0, this.elements_.length - 1);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
};
|
||||
/**
|
||||
* @return {number} Count.
|
||||
*/
|
||||
PriorityQueue.prototype.getCount = function () {
|
||||
return this.elements_.length;
|
||||
};
|
||||
/**
|
||||
* Gets the index of the left child of the node at the given index.
|
||||
* @param {number} index The index of the node to get the left child for.
|
||||
* @return {number} The index of the left child.
|
||||
* @private
|
||||
*/
|
||||
PriorityQueue.prototype.getLeftChildIndex_ = function (index) {
|
||||
return index * 2 + 1;
|
||||
};
|
||||
/**
|
||||
* Gets the index of the right child of the node at the given index.
|
||||
* @param {number} index The index of the node to get the right child for.
|
||||
* @return {number} The index of the right child.
|
||||
* @private
|
||||
*/
|
||||
PriorityQueue.prototype.getRightChildIndex_ = function (index) {
|
||||
return index * 2 + 2;
|
||||
};
|
||||
/**
|
||||
* Gets the index of the parent of the node at the given index.
|
||||
* @param {number} index The index of the node to get the parent for.
|
||||
* @return {number} The index of the parent.
|
||||
* @private
|
||||
*/
|
||||
PriorityQueue.prototype.getParentIndex_ = function (index) {
|
||||
return (index - 1) >> 1;
|
||||
};
|
||||
/**
|
||||
* Make this a heap. O(N).
|
||||
* @private
|
||||
*/
|
||||
PriorityQueue.prototype.heapify_ = function () {
|
||||
var i;
|
||||
for (i = (this.elements_.length >> 1) - 1; i >= 0; i--) {
|
||||
this.siftUp_(i);
|
||||
}
|
||||
};
|
||||
/**
|
||||
* @return {boolean} Is empty.
|
||||
*/
|
||||
PriorityQueue.prototype.isEmpty = function () {
|
||||
return this.elements_.length === 0;
|
||||
};
|
||||
/**
|
||||
* @param {string} key Key.
|
||||
* @return {boolean} Is key queued.
|
||||
*/
|
||||
PriorityQueue.prototype.isKeyQueued = function (key) {
|
||||
return key in this.queuedElements_;
|
||||
};
|
||||
/**
|
||||
* @param {T} element Element.
|
||||
* @return {boolean} Is queued.
|
||||
*/
|
||||
PriorityQueue.prototype.isQueued = function (element) {
|
||||
return this.isKeyQueued(this.keyFunction_(element));
|
||||
};
|
||||
/**
|
||||
* @param {number} index The index of the node to move down.
|
||||
* @private
|
||||
*/
|
||||
PriorityQueue.prototype.siftUp_ = function (index) {
|
||||
var elements = this.elements_;
|
||||
var priorities = this.priorities_;
|
||||
var count = elements.length;
|
||||
var element = elements[index];
|
||||
var priority = priorities[index];
|
||||
var startIndex = index;
|
||||
while (index < count >> 1) {
|
||||
var lIndex = this.getLeftChildIndex_(index);
|
||||
var rIndex = this.getRightChildIndex_(index);
|
||||
var smallerChildIndex = rIndex < count && priorities[rIndex] < priorities[lIndex]
|
||||
? rIndex
|
||||
: lIndex;
|
||||
elements[index] = elements[smallerChildIndex];
|
||||
priorities[index] = priorities[smallerChildIndex];
|
||||
index = smallerChildIndex;
|
||||
}
|
||||
elements[index] = element;
|
||||
priorities[index] = priority;
|
||||
this.siftDown_(startIndex, index);
|
||||
};
|
||||
/**
|
||||
* @param {number} startIndex The index of the root.
|
||||
* @param {number} index The index of the node to move up.
|
||||
* @private
|
||||
*/
|
||||
PriorityQueue.prototype.siftDown_ = function (startIndex, index) {
|
||||
var elements = this.elements_;
|
||||
var priorities = this.priorities_;
|
||||
var element = elements[index];
|
||||
var priority = priorities[index];
|
||||
while (index > startIndex) {
|
||||
var parentIndex = this.getParentIndex_(index);
|
||||
if (priorities[parentIndex] > priority) {
|
||||
elements[index] = elements[parentIndex];
|
||||
priorities[index] = priorities[parentIndex];
|
||||
index = parentIndex;
|
||||
}
|
||||
else {
|
||||
break;
|
||||
}
|
||||
}
|
||||
elements[index] = element;
|
||||
priorities[index] = priority;
|
||||
};
|
||||
/**
|
||||
* FIXME empty description for jsdoc
|
||||
*/
|
||||
PriorityQueue.prototype.reprioritize = function () {
|
||||
var priorityFunction = this.priorityFunction_;
|
||||
var elements = this.elements_;
|
||||
var priorities = this.priorities_;
|
||||
var index = 0;
|
||||
var n = elements.length;
|
||||
var element, i, priority;
|
||||
for (i = 0; i < n; ++i) {
|
||||
element = elements[i];
|
||||
priority = priorityFunction(element);
|
||||
if (priority == DROP) {
|
||||
delete this.queuedElements_[this.keyFunction_(element)];
|
||||
}
|
||||
else {
|
||||
priorities[index] = priority;
|
||||
elements[index++] = element;
|
||||
}
|
||||
}
|
||||
elements.length = index;
|
||||
priorities.length = index;
|
||||
this.heapify_();
|
||||
};
|
||||
return PriorityQueue;
|
||||
}());
|
||||
export default PriorityQueue;
|
||||
//# sourceMappingURL=PriorityQueue.js.map
|
||||
1
node_modules/ol/structs/PriorityQueue.js.map
generated
vendored
Normal file
1
node_modules/ol/structs/PriorityQueue.js.map
generated
vendored
Normal file
File diff suppressed because one or more lines are too long
130
node_modules/ol/structs/RBush.d.ts
generated
vendored
Normal file
130
node_modules/ol/structs/RBush.d.ts
generated
vendored
Normal file
@@ -0,0 +1,130 @@
|
||||
export default RBush;
|
||||
export type Entry = {
|
||||
/**
|
||||
* MinX.
|
||||
*/
|
||||
minX: number;
|
||||
/**
|
||||
* MinY.
|
||||
*/
|
||||
minY: number;
|
||||
/**
|
||||
* MaxX.
|
||||
*/
|
||||
maxX: number;
|
||||
/**
|
||||
* MaxY.
|
||||
*/
|
||||
maxY: number;
|
||||
/**
|
||||
* Value.
|
||||
*/
|
||||
value?: any;
|
||||
};
|
||||
/**
|
||||
* @typedef {Object} Entry
|
||||
* @property {number} minX MinX.
|
||||
* @property {number} minY MinY.
|
||||
* @property {number} maxX MaxX.
|
||||
* @property {number} maxY MaxY.
|
||||
* @property {Object} [value] Value.
|
||||
*/
|
||||
/**
|
||||
* @classdesc
|
||||
* Wrapper around the RBush by Vladimir Agafonkin.
|
||||
* See https://github.com/mourner/rbush.
|
||||
*
|
||||
* @template T
|
||||
*/
|
||||
declare class RBush<T> {
|
||||
/**
|
||||
* @param {number} [opt_maxEntries] Max entries.
|
||||
*/
|
||||
constructor(opt_maxEntries?: number | undefined);
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
private rbush_;
|
||||
/**
|
||||
* A mapping between the objects added to this rbush wrapper
|
||||
* and the objects that are actually added to the internal rbush.
|
||||
* @private
|
||||
* @type {Object<string, Entry>}
|
||||
*/
|
||||
private items_;
|
||||
/**
|
||||
* Insert a value into the RBush.
|
||||
* @param {import("../extent.js").Extent} extent Extent.
|
||||
* @param {T} value Value.
|
||||
*/
|
||||
insert(extent: import("../extent.js").Extent, value: T): void;
|
||||
/**
|
||||
* Bulk-insert values into the RBush.
|
||||
* @param {Array<import("../extent.js").Extent>} extents Extents.
|
||||
* @param {Array<T>} values Values.
|
||||
*/
|
||||
load(extents: Array<import("../extent.js").Extent>, values: Array<T>): void;
|
||||
/**
|
||||
* Remove a value from the RBush.
|
||||
* @param {T} value Value.
|
||||
* @return {boolean} Removed.
|
||||
*/
|
||||
remove(value: T): boolean;
|
||||
/**
|
||||
* Update the extent of a value in the RBush.
|
||||
* @param {import("../extent.js").Extent} extent Extent.
|
||||
* @param {T} value Value.
|
||||
*/
|
||||
update(extent: import("../extent.js").Extent, value: T): void;
|
||||
/**
|
||||
* Return all values in the RBush.
|
||||
* @return {Array<T>} All.
|
||||
*/
|
||||
getAll(): Array<T>;
|
||||
/**
|
||||
* Return all values in the given extent.
|
||||
* @param {import("../extent.js").Extent} extent Extent.
|
||||
* @return {Array<T>} All in extent.
|
||||
*/
|
||||
getInExtent(extent: import("../extent.js").Extent): Array<T>;
|
||||
/**
|
||||
* Calls a callback function with each value in the tree.
|
||||
* If the callback returns a truthy value, this value is returned without
|
||||
* checking the rest of the tree.
|
||||
* @param {function(T): *} callback Callback.
|
||||
* @return {*} Callback return value.
|
||||
*/
|
||||
forEach(callback: (arg0: T) => any): any;
|
||||
/**
|
||||
* Calls a callback function with each value in the provided extent.
|
||||
* @param {import("../extent.js").Extent} extent Extent.
|
||||
* @param {function(T): *} callback Callback.
|
||||
* @return {*} Callback return value.
|
||||
*/
|
||||
forEachInExtent(extent: import("../extent.js").Extent, callback: (arg0: T) => any): any;
|
||||
/**
|
||||
* @param {Array<T>} values Values.
|
||||
* @param {function(T): *} callback Callback.
|
||||
* @private
|
||||
* @return {*} Callback return value.
|
||||
*/
|
||||
private forEach_;
|
||||
/**
|
||||
* @return {boolean} Is empty.
|
||||
*/
|
||||
isEmpty(): boolean;
|
||||
/**
|
||||
* Remove all values from the RBush.
|
||||
*/
|
||||
clear(): void;
|
||||
/**
|
||||
* @param {import("../extent.js").Extent} [opt_extent] Extent.
|
||||
* @return {import("../extent.js").Extent} Extent.
|
||||
*/
|
||||
getExtent(opt_extent?: import("../extent.js").Extent | undefined): import("../extent.js").Extent;
|
||||
/**
|
||||
* @param {RBush} rbush R-Tree.
|
||||
*/
|
||||
concat(rbush: RBush<any>): void;
|
||||
}
|
||||
//# sourceMappingURL=RBush.d.ts.map
|
||||
1
node_modules/ol/structs/RBush.d.ts.map
generated
vendored
Normal file
1
node_modules/ol/structs/RBush.d.ts.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"RBush.d.ts","sourceRoot":"","sources":["../src/structs/RBush.js"],"names":[],"mappings":";;;;;UAUc,MAAM;;;;UACN,MAAM;;;;UACN,MAAM;;;;UACN,MAAM;;;;;;AALpB;;;;;;;GAOG;AAEH;;;;;;GAMG;AACH;IACE;;OAEG;IACH,iDAaC;IAZC;;OAEG;IACH,eAAwC;IAExC;;;;;OAKG;IACH,eAAgB;IAGlB;;;;OAIG;IACH,eAHW,OAAO,cAAc,EAAE,MAAM,SAC7B,CAAC,QAcX;IAED;;;;OAIG;IACH,cAHW,MAAM,OAAO,cAAc,EAAE,MAAM,CAAC,UACpC,MAAM,CAAC,CAAC,QAoBlB;IAED;;;;OAIG;IACH,cAHW,CAAC,GACA,OAAO,CAUlB;IAED;;;;OAIG;IACH,eAHW,OAAO,cAAc,EAAE,MAAM,SAC7B,CAAC,QASX;IAED;;;OAGG;IACH,UAFY,MAAM,CAAC,CAAC,CAOnB;IAED;;;;OAIG;IACH,oBAHW,OAAO,cAAc,EAAE,MAAM,GAC5B,MAAM,CAAC,CAAC,CAcnB;IAED;;;;;;OAMG;IACH,yBAHoB,CAAC,eAKpB;IAED;;;;;OAKG;IACH,wBAJW,OAAO,cAAc,EAAE,MAAM,mBACpB,CAAC,eAKpB;IAED;;;;;OAKG;IACH,iBASC;IAED;;OAEG;IACH,WAFY,OAAO,CAIlB;IAED;;OAEG;IACH,cAGC;IAED;;;OAGG;IACH,mEAFY,OAAO,cAAc,EAAE,MAAM,CAWxC;IAED;;OAEG;IACH,gCAKC;CACF"}
|
||||
202
node_modules/ol/structs/RBush.js
generated
vendored
Normal file
202
node_modules/ol/structs/RBush.js
generated
vendored
Normal file
@@ -0,0 +1,202 @@
|
||||
/**
|
||||
* @module ol/structs/RBush
|
||||
*/
|
||||
import RBush_ from 'rbush';
|
||||
import { createOrUpdate, equals } from '../extent.js';
|
||||
import { getUid } from '../util.js';
|
||||
import { isEmpty } from '../obj.js';
|
||||
/**
|
||||
* @typedef {Object} Entry
|
||||
* @property {number} minX MinX.
|
||||
* @property {number} minY MinY.
|
||||
* @property {number} maxX MaxX.
|
||||
* @property {number} maxY MaxY.
|
||||
* @property {Object} [value] Value.
|
||||
*/
|
||||
/**
|
||||
* @classdesc
|
||||
* Wrapper around the RBush by Vladimir Agafonkin.
|
||||
* See https://github.com/mourner/rbush.
|
||||
*
|
||||
* @template T
|
||||
*/
|
||||
var RBush = /** @class */ (function () {
|
||||
/**
|
||||
* @param {number} [opt_maxEntries] Max entries.
|
||||
*/
|
||||
function RBush(opt_maxEntries) {
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
this.rbush_ = new RBush_(opt_maxEntries);
|
||||
/**
|
||||
* A mapping between the objects added to this rbush wrapper
|
||||
* and the objects that are actually added to the internal rbush.
|
||||
* @private
|
||||
* @type {Object<string, Entry>}
|
||||
*/
|
||||
this.items_ = {};
|
||||
}
|
||||
/**
|
||||
* Insert a value into the RBush.
|
||||
* @param {import("../extent.js").Extent} extent Extent.
|
||||
* @param {T} value Value.
|
||||
*/
|
||||
RBush.prototype.insert = function (extent, value) {
|
||||
/** @type {Entry} */
|
||||
var item = {
|
||||
minX: extent[0],
|
||||
minY: extent[1],
|
||||
maxX: extent[2],
|
||||
maxY: extent[3],
|
||||
value: value,
|
||||
};
|
||||
this.rbush_.insert(item);
|
||||
this.items_[getUid(value)] = item;
|
||||
};
|
||||
/**
|
||||
* Bulk-insert values into the RBush.
|
||||
* @param {Array<import("../extent.js").Extent>} extents Extents.
|
||||
* @param {Array<T>} values Values.
|
||||
*/
|
||||
RBush.prototype.load = function (extents, values) {
|
||||
var items = new Array(values.length);
|
||||
for (var i = 0, l = values.length; i < l; i++) {
|
||||
var extent = extents[i];
|
||||
var value = values[i];
|
||||
/** @type {Entry} */
|
||||
var item = {
|
||||
minX: extent[0],
|
||||
minY: extent[1],
|
||||
maxX: extent[2],
|
||||
maxY: extent[3],
|
||||
value: value,
|
||||
};
|
||||
items[i] = item;
|
||||
this.items_[getUid(value)] = item;
|
||||
}
|
||||
this.rbush_.load(items);
|
||||
};
|
||||
/**
|
||||
* Remove a value from the RBush.
|
||||
* @param {T} value Value.
|
||||
* @return {boolean} Removed.
|
||||
*/
|
||||
RBush.prototype.remove = function (value) {
|
||||
var uid = getUid(value);
|
||||
// get the object in which the value was wrapped when adding to the
|
||||
// internal rbush. then use that object to do the removal.
|
||||
var item = this.items_[uid];
|
||||
delete this.items_[uid];
|
||||
return this.rbush_.remove(item) !== null;
|
||||
};
|
||||
/**
|
||||
* Update the extent of a value in the RBush.
|
||||
* @param {import("../extent.js").Extent} extent Extent.
|
||||
* @param {T} value Value.
|
||||
*/
|
||||
RBush.prototype.update = function (extent, value) {
|
||||
var item = this.items_[getUid(value)];
|
||||
var bbox = [item.minX, item.minY, item.maxX, item.maxY];
|
||||
if (!equals(bbox, extent)) {
|
||||
this.remove(value);
|
||||
this.insert(extent, value);
|
||||
}
|
||||
};
|
||||
/**
|
||||
* Return all values in the RBush.
|
||||
* @return {Array<T>} All.
|
||||
*/
|
||||
RBush.prototype.getAll = function () {
|
||||
var items = this.rbush_.all();
|
||||
return items.map(function (item) {
|
||||
return item.value;
|
||||
});
|
||||
};
|
||||
/**
|
||||
* Return all values in the given extent.
|
||||
* @param {import("../extent.js").Extent} extent Extent.
|
||||
* @return {Array<T>} All in extent.
|
||||
*/
|
||||
RBush.prototype.getInExtent = function (extent) {
|
||||
/** @type {Entry} */
|
||||
var bbox = {
|
||||
minX: extent[0],
|
||||
minY: extent[1],
|
||||
maxX: extent[2],
|
||||
maxY: extent[3],
|
||||
};
|
||||
var items = this.rbush_.search(bbox);
|
||||
return items.map(function (item) {
|
||||
return item.value;
|
||||
});
|
||||
};
|
||||
/**
|
||||
* Calls a callback function with each value in the tree.
|
||||
* If the callback returns a truthy value, this value is returned without
|
||||
* checking the rest of the tree.
|
||||
* @param {function(T): *} callback Callback.
|
||||
* @return {*} Callback return value.
|
||||
*/
|
||||
RBush.prototype.forEach = function (callback) {
|
||||
return this.forEach_(this.getAll(), callback);
|
||||
};
|
||||
/**
|
||||
* Calls a callback function with each value in the provided extent.
|
||||
* @param {import("../extent.js").Extent} extent Extent.
|
||||
* @param {function(T): *} callback Callback.
|
||||
* @return {*} Callback return value.
|
||||
*/
|
||||
RBush.prototype.forEachInExtent = function (extent, callback) {
|
||||
return this.forEach_(this.getInExtent(extent), callback);
|
||||
};
|
||||
/**
|
||||
* @param {Array<T>} values Values.
|
||||
* @param {function(T): *} callback Callback.
|
||||
* @private
|
||||
* @return {*} Callback return value.
|
||||
*/
|
||||
RBush.prototype.forEach_ = function (values, callback) {
|
||||
var result;
|
||||
for (var i = 0, l = values.length; i < l; i++) {
|
||||
result = callback(values[i]);
|
||||
if (result) {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
return result;
|
||||
};
|
||||
/**
|
||||
* @return {boolean} Is empty.
|
||||
*/
|
||||
RBush.prototype.isEmpty = function () {
|
||||
return isEmpty(this.items_);
|
||||
};
|
||||
/**
|
||||
* Remove all values from the RBush.
|
||||
*/
|
||||
RBush.prototype.clear = function () {
|
||||
this.rbush_.clear();
|
||||
this.items_ = {};
|
||||
};
|
||||
/**
|
||||
* @param {import("../extent.js").Extent} [opt_extent] Extent.
|
||||
* @return {import("../extent.js").Extent} Extent.
|
||||
*/
|
||||
RBush.prototype.getExtent = function (opt_extent) {
|
||||
var data = this.rbush_.toJSON();
|
||||
return createOrUpdate(data.minX, data.minY, data.maxX, data.maxY, opt_extent);
|
||||
};
|
||||
/**
|
||||
* @param {RBush} rbush R-Tree.
|
||||
*/
|
||||
RBush.prototype.concat = function (rbush) {
|
||||
this.rbush_.load(rbush.rbush_.all());
|
||||
for (var i in rbush.items_) {
|
||||
this.items_[i] = rbush.items_[i];
|
||||
}
|
||||
};
|
||||
return RBush;
|
||||
}());
|
||||
export default RBush;
|
||||
//# sourceMappingURL=RBush.js.map
|
||||
1
node_modules/ol/structs/RBush.js.map
generated
vendored
Normal file
1
node_modules/ol/structs/RBush.js.map
generated
vendored
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"file":"RBush.js","sourceRoot":"","sources":["../src/structs/RBush.js"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,MAAM,MAAM,OAAO,CAAC;AAC3B,OAAO,EAAC,cAAc,EAAE,MAAM,EAAC,MAAM,cAAc,CAAC;AACpD,OAAO,EAAC,MAAM,EAAC,MAAM,YAAY,CAAC;AAClC,OAAO,EAAC,OAAO,EAAC,MAAM,WAAW,CAAC;AAElC;;;;;;;GAOG;AAEH;;;;;;GAMG;AACH;IACE;;OAEG;IACH,eAAY,cAAc;QACxB;;WAEG;QACH,IAAI,CAAC,MAAM,GAAG,I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