diff --git a/src/ol/format/TopoJSON.js b/src/ol/format/TopoJSON.js index 5c586c36f4..d7dc6aba0e 100644 --- a/src/ol/format/TopoJSON.js +++ b/src/ol/format/TopoJSON.js @@ -1,7 +1,6 @@ /** * @module ol/format/TopoJSON */ -import {inherits} from '../util.js'; import Feature from '../Feature.js'; import {transformWithOptions} from '../format/Feature.js'; import JSONFeature from '../format/JSONFeature.js'; @@ -43,20 +42,18 @@ import {get as getProjection} from '../proj.js'; * @classdesc * Feature format for reading data in the TopoJSON format. * - * @extends {module:ol/format/JSONFeature} * @api */ -class TopoJSON { +class TopoJSON extends JSONFeature { /** * @param {module:ol/format/TopoJSON~Options=} opt_options Options. */ constructor(opt_options) { + super(); const options = opt_options ? opt_options : {}; - JSONFeature.call(this); - /** * @private * @type {string|undefined} @@ -157,8 +154,6 @@ class TopoJSON { readFeatureFromObject() {} } -inherits(TopoJSON, JSONFeature); - /** * @const @@ -380,17 +375,6 @@ function readFeatureFromGeometry(object, arcs, scale, translate, property, name, } -/** - * Read all features from a TopoJSON source. - * - * @function - * @param {Document|Node|Object|string} source Source. - * @return {Array.} Features. - * @api - */ -TopoJSON.prototype.readFeatures; - - /** * Apply a linear transform to array of arcs. The provided array of arcs is * modified in place. @@ -441,15 +425,4 @@ function transformVertex(vertex, scale, translate) { } -/** - * Read the projection from a TopoJSON source. - * - * @param {Document|Node|Object|string} object Source. - * @return {module:ol/proj/Projection} Projection. - * @override - * @api - */ -TopoJSON.prototype.readProjection; - - export default TopoJSON;