Skip to content

Commit 6fd5212

Browse files
authored
Merge pull request #452 from fschmenger/enhance_js_doc
Enhance js doc
2 parents eef9d8d + 039f718 commit 6fd5212

File tree

13 files changed

+58
-61
lines changed

13 files changed

+58
-61
lines changed

src/components/measuretool/MeasureWin.vue

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,9 +104,8 @@ export default {
104104
* Called as callback of MeasureTypeChooser
105105
*
106106
* @param {String} newMeasureType New measure type
107-
* @param {String} oldMeasureType Old measure type
108107
*/
109-
applyMeasureType (newMeasureType, oldMeasureType) {
108+
applyMeasureType (newMeasureType) {
110109
this.measureType = newMeasureType;
111110
},
112111
/**

src/components/ol/HoverController.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export default class HoverController {
2828
* 'hoverAttribute' if the layer is configured as 'hoverable'
2929
*
3030
* @param {ol.Map} map OpenLayers map.
31-
* @param {object} hoverConf Global configuration options.
31+
* @param {object} [hoverConf] Optional global configuration options.
3232
*/
3333
constructor (map, hoverConf) {
3434
const me = this;
@@ -162,7 +162,7 @@ export default class HoverController {
162162
* @param {ol.Map} map OpenLayers map.
163163
* @param {ol.layer.Tile | ol.layer.Image} layer The layer to acquire the features for.
164164
* @param {ol.Coordinate} coordinate The coordinate in map projection.
165-
* @param {AbortController} abortCtrl An optional abort controller to abort the request.
165+
* @param {AbortController} [abortCtrl] An optional abort controller to abort the request.
166166
* @returns {Promise<Array<ol.Feature>>}
167167
*/
168168
getWMSFeaturesAsync (map, layer, coordinate, abortCtrl) {

src/components/ol/Map.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -375,7 +375,7 @@ export default {
375375
* property declared there will take precedence over the ones declared in the
376376
* language packs.
377377
*
378-
* @param {ol.layer.Layer} OL layer instance
378+
* @param {ol.layer.Layer} layer OL layer instance
379379
*/
380380
updateLocalizedLayerProps (layer) {
381381
const langKey = layer.get('langKey') || layer.get('lid');

src/components/overviewmap/OverviewMapController.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export default class OverviewMapController {
1515
* Construction
1616
* @param {ol.Map} map OpenLayers map.
1717
* @param {HTMLElement} target The target container to render the control.
18-
* @param {Object} config The overview map configuration object.
18+
* @param {Object} [config] Optional overview map configuration object.
1919
*/
2020
constructor (map, target, config) {
2121
this.map = map;

src/components/progress/MapLoadingStatus.vue

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,6 @@ export default {
4444
4545
/**
4646
* Registers the needed events on the map.
47-
*
48-
* @param {ol/layer/Base | ol/layer/Group} layer Layer or group to register
4947
*/
5048
registerMapEvents () {
5149
this.map.on('loadstart', this.showLoader);

src/factory/Layer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ export const LayerFactory = {
5757
* Returns an OpenLayers layer instance due to given config.
5858
*
5959
* @param {Object} lConf Layer config object
60-
* @param {ol/Map} olMap Optional OL map we work on
60+
* @param {ol/Map} [olMap] Optional OL map, required for WFS layer only.
6161
* @return {ol/layer/Base} OL layer instance
6262
*/
6363
getInstance (lConf, olMap) {

src/util/ColorTheme.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ const ColorThemeUtil = {
165165

166166
/**
167167
* Builds the theme object used by Vuetify
168-
* @param {Object} inputConfig user configuration from app-config
168+
* @param {Object} [inputConfig] optional user configuration from app-config
169169
* @returns {Object} theme object
170170
*/
171171
buildTheme: function (inputConfig) {

src/util/Layer.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ const LayerUtil = {
4444
*
4545
* @param {ol.layer.Base} vecLayer OL vector layer
4646
* @param {ol.Map} olMap The map to perform the zoom on
47-
* @param {Object} options Optional animation configuration
47+
* @param {Object} [options] Optional animation configuration
4848
*/
4949
zoomToLayerExtent (vecLayer, olMap, options) {
5050
if (!vecLayer || !vecLayer.getSource().getExtent || !olMap) {

src/util/LayerLegend.js

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ class LayerLegend {
1010
/**
1111
* Instantiates a layer legend object with the legend options configured
1212
* in the application context.
13-
* @param {Object} options Application wide legend options.
13+
* @param {Object} [options] Optional application wide legend options.
1414
*/
1515
constructor (options) {
1616
this.options = options;
@@ -19,7 +19,7 @@ class LayerLegend {
1919
/**
2020
* Merges the given legend options with the legend options configured
2121
* in the application context. The provided options will take precedence.
22-
* @param {Object} options Optional configuration params.
22+
* @param {Object} [options] Optional configuration params.
2323
* @returns {Object} Merged configuration params.
2424
*/
2525
getOptions (options) {
@@ -33,8 +33,8 @@ class LayerLegend {
3333
* Returns a URL to the layers legend image.
3434
* @param {ol.Layer} layer The layer to produce the legend for.
3535
* @param {Number} resolution Resolution of the legend image.
36-
* @param {Object} options Optional configuration params.
37-
* @param {String} formatUrl A custom format URL.
36+
* @param {Object} [options] Optional configuration params.
37+
* @param {String} [formatUrl] An optional custom format URL.
3838
* @returns {String} Legend URL or undefined if no legend can be produced.
3939
*/
4040
getUrl (layer, resolution, options, formatUrl) {
@@ -69,7 +69,7 @@ const CustomLegend = {
6969
* This replaces the parameter placeholders in formatUrl.
7070
* @param {ol.Source} source The source to produce the legend for.
7171
* @param {Number} resolution Resolution of the legend image.
72-
* @param {Object} options Optional configuration params.
72+
* @param {Object} [options] Optional configuration params.
7373
* @param {String} formatUrl A custom format URL.
7474
* @returns {String} The legend URL.
7575
*/
@@ -99,7 +99,7 @@ const WMSSourceLegend = {
9999
* Returns a URL to the legend image.
100100
* @param {ol.Source} source The source to produce the legend for.
101101
* @param {Number} resolution Resolution of the legend image.
102-
* @param {Object} options Optional configuration params.
102+
* @param {Object} [options] Optional configuration params.
103103
* @returns {String} The legend URL.
104104
*/
105105
getUrl (source, resolution, options) {

src/util/MapInteraction.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ const MapInteractionUtil = {
99
* Create a selectInteraction for a layer
1010
*
1111
* @param {ol.layer.Layer} layer The layer to create the interaction for
12-
* @param {Object} [selectStyleConf] The configuration for the selection style
13-
* @param {Boolean} [doAppendSelectStyle] If the selection style should be appended to the original style.
12+
* @param {Object} [selectStyleConf] Optional configuration for the selection style
13+
* @param {Boolean} doAppendSelectStyle Whether the selection style should be appended to the original style.
1414
*
1515
* @returns {ol.interaction.Select} The select interaction
1616
*/

0 commit comments

Comments
 (0)