Move jsdoc constructor comments

This commit is contained in:
Frederic Junod
2018-07-17 10:20:26 +02:00
parent f2d0b11d24
commit 540b1793e7
23 changed files with 259 additions and 238 deletions

View File

@@ -58,12 +58,14 @@ GEOMETRY_WRITERS[GeometryType.MULTI_POLYGON] = writeMultiPolygonGeometry;
* @classdesc
* Feature format for reading and writing data in the EsriJSON format.
*
* @constructor
* @extends {module:ol/format/JSONFeature}
* @param {module:ol/format/EsriJSON~Options=} opt_options Options.
* @api
*/
class EsriJSON {
/**
* @param {module:ol/format/EsriJSON~Options=} opt_options Options.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -56,7 +56,6 @@ import {get as getProjection, equivalent as equivalentProjection, transformExten
* {@link module:ol/Feature~Feature} objects from a variety of commonly used geospatial
* file formats. See the documentation for each format for more details.
*
* @constructor
* @abstract
* @api
*/

View File

@@ -37,12 +37,14 @@ const MULTIGEOMETRY_TO_MEMBER_NODENAME = {
* Feature format for reading and writing data in the GML format,
* version 2.1.2.
*
* @constructor
* @param {module:ol/format/GMLBase~Options=} opt_options Optional configuration object.
* @extends {module:ol/format/GMLBase}
* @api
*/
class GML2 {
/**
* @param {module:ol/format/GMLBase~Options=} opt_options Optional configuration object.
*/
constructor(opt_options) {
const options = /** @type {module:ol/format/GMLBase~Options} */
(opt_options ? opt_options : {});

View File

@@ -48,13 +48,14 @@ const MULTIGEOMETRY_TO_MEMBER_NODENAME = {
* version 3.1.1.
* Currently only supports GML 3.1.1 Simple Features profile.
*
* @constructor
* @param {module:ol/format/GMLBase~Options=} opt_options
* Optional configuration object.
* @extends {module:ol/format/GMLBase}
* @api
*/
class GML3 {
/**
* @param {module:ol/format/GMLBase~Options=} opt_options Optional configuration object.
*/
constructor(opt_options) {
const options = /** @type {module:ol/format/GMLBase~Options} */
(opt_options ? opt_options : {});

View File

@@ -83,13 +83,14 @@ const ONLY_WHITESPACE_RE = /^[\s\xa0]*$/;
* This class cannot be instantiated, it contains only base content that
* is shared with versioned format classes GML2 and GML3.
*
* @constructor
* @abstract
* @param {module:ol/format/GMLBase~Options=} opt_options
* Optional configuration object.
* @extends {module:ol/format/XMLFeature}
*/
class GMLBase {
/**
* @param {module:ol/format/GMLBase~Options=} opt_options Optional configuration object.
*/
constructor(opt_options) {
const options = /** @type {module:ol/format/GMLBase~Options} */ (opt_options ? opt_options : {});

View File

@@ -103,12 +103,14 @@ const GPX_SERIALIZERS = makeStructureNS(
* @classdesc
* Feature format for reading and writing data in the GPX format.
*
* @constructor
* @extends {module:ol/format/XMLFeature}
* @param {module:ol/format/GPX~Options=} opt_options Options.
* @api
*/
class GPX {
/**
* @param {module:ol/format/GPX~Options=} opt_options Options.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -37,12 +37,14 @@ import {get as getProjection} from '../proj.js';
* @classdesc
* Feature format for reading and writing data in the GeoJSON format.
*
* @constructor
* @extends {module:ol/format/JSONFeature}
* @param {module:ol/format/GeoJSON~Options=} opt_options Options.
* @api
*/
class GeoJSON {
/**
* @param {module:ol/format/GeoJSON~Options=} opt_options Options.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -61,12 +61,14 @@ const NEWLINE_RE = /\r\n|\r|\n/;
* @classdesc
* Feature format for `*.igc` flight recording files.
*
* @constructor
* @extends {module:ol/format/TextFeature}
* @param {module:ol/format/IGC~Options=} opt_options Options.
* @api
*/
class IGC {
/**
* @param {module:ol/format/IGC~Options=} opt_options Options.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -11,7 +11,6 @@ import FormatType from '../format/FormatType.js';
* instantiated in apps.
* Base class for JSON feature formats.
*
* @constructor
* @abstract
* @extends {module:ol/format/Feature}
*/

View File

@@ -391,12 +391,14 @@ function createStyleDefaults() {
* Note that the KML format uses the URL() constructor. Older browsers such as IE
* which do not support this will need a URL polyfill to be loaded before use.
*
* @constructor
* @extends {module:ol/format/XMLFeature}
* @param {module:ol/format/KML~Options=} opt_options Options.
* @api
*/
class KML {
/**
* @param {module:ol/format/KML~Options=} opt_options Options.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -42,12 +42,15 @@ import RenderFeature from '../render/Feature.js';
* @classdesc
* Feature format for reading data in the Mapbox MVT format.
*
* @constructor
* @extends {module:ol/format/Feature}
* @param {module:ol/format/MVT~Options=} opt_options Options.
* @api
*/
class MVT {
/**
* @param {module:ol/format/MVT~Options=} opt_options Options.
*/
constructor(opt_options) {
FeatureFormat.call(this);

View File

@@ -50,7 +50,6 @@ const PARSERS = makeStructureNS(
* Feature format for reading data in the
* [OSMXML format](http://wiki.openstreetmap.org/wiki/OSM_XML).
*
* @constructor
* @extends {module:ol/format/XMLFeature}
* @api
*/

View File

@@ -28,7 +28,6 @@ const PARSERS = makeStructureNS(
/**
* @constructor
* @extends {module:ol/format/XML}
*/
class OWS {

View File

@@ -27,12 +27,14 @@ import {get as getProjection} from '../proj.js';
* Feature format for reading and writing data in the Encoded
* Polyline Algorithm Format.
*
* @constructor
* @extends {module:ol/format/TextFeature}
* @param {module:ol/format/Polyline~Options=} opt_options Optional configuration object.
* @api
*/
class Polyline {
/**
* @param {module:ol/format/Polyline~Options=} opt_options Optional configuration object.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -11,7 +11,6 @@ import FormatType from '../format/FormatType.js';
* instantiated in apps.
* Base class for text feature formats.
*
* @constructor
* @abstract
* @extends {module:ol/format/Feature}
*/

View File

@@ -43,12 +43,14 @@ import {get as getProjection} from '../proj.js';
* @classdesc
* Feature format for reading data in the TopoJSON format.
*
* @constructor
* @extends {module:ol/format/JSONFeature}
* @param {module:ol/format/TopoJSON~Options=} opt_options Options.
* @api
*/
class TopoJSON {
/**
* @param {module:ol/format/TopoJSON~Options=} opt_options Options.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -201,12 +201,14 @@ const DEFAULT_VERSION = '1.1.0';
* as option if you want to read a WFS that contains GML2 (WFS 1.0.0).
* Also see {@link module:ol/format/GMLBase~GMLBase} which is used by this format.
*
* @constructor
* @param {module:ol/format/WFS~Options=} opt_options Optional configuration object.
* @extends {module:ol/format/XMLFeature}
* @api
*/
class WFS {
/**
* @param {module:ol/format/WFS~Options=} opt_options Optional configuration object.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -87,10 +87,12 @@ const TokenType = {
/**
* Class to tokenize a WKT string.
* @param {string} wkt WKT string.
* @constructor
*/
class Lexer {
/**
* @param {string} wkt WKT string.
*/
constructor(wkt) {
/**
@@ -218,10 +220,12 @@ class Lexer {
/**
* Class to parse the tokens from the WKT string.
* @param {module:ol/format/WKT~Lexer} lexer The lexer.
* @constructor
*/
class Parser {
/**
* @param {module:ol/format/WKT~Lexer} lexer The lexer.
*/
constructor(lexer) {
/**
@@ -590,12 +594,14 @@ class Parser {
* Geometry format for reading and writing data in the `WellKnownText` (WKT)
* format.
*
* @constructor
* @extends {module:ol/format/TextFeature}
* @param {module:ol/format/WKT~Options=} opt_options Options.
* @api
*/
class WKT {
/**
* @param {module:ol/format/WKT~Options=} opt_options Options.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -46,7 +46,6 @@ const CAPABILITY_PARSERS = makeStructureNS(
* @classdesc
* Format for reading WMS capabilities data
*
* @constructor
* @extends {module:ol/format/XML}
* @api
*/

View File

@@ -34,12 +34,14 @@ const layerIdentifier = '_layer';
* Format for reading WMSGetFeatureInfo format. It uses
* {@link module:ol/format/GML2~GML2} to read features.
*
* @constructor
* @extends {module:ol/format/XMLFeature}
* @param {module:ol/format/WMSGetFeatureInfo~Options=} opt_options Options.
* @api
*/
class WMSGetFeatureInfo {
/**
* @param {module:ol/format/WMSGetFeatureInfo~Options=} opt_options Options.
*/
constructor(opt_options) {
const options = opt_options ? opt_options : {};

View File

@@ -45,7 +45,6 @@ const PARSERS = makeStructureNS(
* @classdesc
* Format for reading WMTS capabilities data.
*
* @constructor
* @extends {module:ol/format/XML}
* @api
*/

View File

@@ -7,9 +7,7 @@ import {isDocument, isNode, parse} from '../xml.js';
* @classdesc
* Generic format for reading non-feature XML data
*
* @constructor
* @abstract
* @struct
*/
class XML {
/**

View File

@@ -13,7 +13,6 @@ import {isDocument, isNode, parse} from '../xml.js';
* instantiated in apps.
* Base class for XML feature formats.
*
* @constructor
* @abstract
* @extends {module:ol/format/Feature}
*/