Use extends and super for TileCache

This commit is contained in:
ahocevar
2018-07-17 14:11:47 +02:00
parent 9e259c471d
commit 64190b7109

View File

@@ -1,21 +1,17 @@
/**
* @module ol/TileCache
*/
import {inherits} from './util.js';
import LRUCache from './structs/LRUCache.js';
import {fromKey, getKey} from './tilecoord.js';
/**
* @extends {module:ol/structs/LRUCache.<module:ol/Tile>}
*/
class TileCache {
class TileCache extends LRUCache {
/**
* @param {number=} opt_highWaterMark High water mark.
*/
constructor(opt_highWaterMark) {
LRUCache.call(this, opt_highWaterMark);
super(opt_highWaterMark);
}
@@ -53,7 +49,5 @@ class TileCache {
}
}
inherits(TileCache, LRUCache);
export default TileCache;