Module type for ol/Feature

This commit is contained in:
Tim Schaub
2018-03-11 23:32:28 -06:00
parent 5c9aa0ce93
commit cf80733e41
56 changed files with 333 additions and 333 deletions
+1 -1
View File
@@ -18,7 +18,7 @@ common.getRendererFromQueryString = function(opt_default) {};
* @param {function(new:ol.style.Stroke, olx.style.StrokeOptions=)} Stroke Stroke constructor.
* @param {function(new:ol.style.Icon, olx.style.IconOptions=)} Icon Icon constructor.
* @param {function(new:ol.style.Text, olx.style.TextOptions=)} Text Text constructor.
* @return {function((ol.Feature|ol.render.Feature), number):
* @return {function((module:ol/Feature~Feature|ol.render.Feature), number):
* Array.<ol.style.Style>}
*/
var createMapboxStreetsV6Style = function(Style, Fill, Stroke, Icon, Text) {};
+7 -7
View File
@@ -86,7 +86,7 @@ oli.DrawEvent = function() {};
/**
* @type {ol.Feature}
* @type {module:ol/Feature~Feature}
*/
oli.DrawEvent.prototype.feature;
@@ -109,7 +109,7 @@ oli.ModifyEvent = function() {};
/**
* @type {ol.Collection.<ol.Feature>}
* @type {ol.Collection.<module:ol/Feature~Feature>}
*/
oli.ModifyEvent.prototype.features;
@@ -199,13 +199,13 @@ oli.SelectEvent = function() {};
/**
* @type {Array.<ol.Feature>}
* @type {Array.<module:ol/Feature~Feature>}
*/
oli.SelectEvent.prototype.deselected;
/**
* @type {Array.<ol.Feature>}
* @type {Array.<module:ol/Feature~Feature>}
*/
oli.SelectEvent.prototype.selected;
@@ -248,7 +248,7 @@ oli.interaction.DragAndDropEvent = function() {};
/**
* @type {Array.<ol.Feature>|undefined}
* @type {Array.<module:ol/Feature~Feature>|undefined}
*/
oli.interaction.DragAndDropEvent.prototype.features;
@@ -272,7 +272,7 @@ oli.interaction.TranslateEvent = function() {};
/**
* @type {ol.Collection.<ol.Feature>}
* @type {ol.Collection.<module:ol/Feature~Feature>}
*/
oli.interaction.TranslateEvent.prototype.features;
@@ -380,6 +380,6 @@ oli.source.Vector.Event = function() {};
/**
* @type {ol.Feature|undefined}
* @type {module:ol/Feature~Feature|undefined}
*/
oli.source.Vector.Event.prototype.feature;
+24 -24
View File
@@ -239,7 +239,7 @@ olx.interaction.DragZoomOptions.prototype.out;
/**
* @typedef {{clickTolerance: (number|undefined),
* features: (ol.Collection.<ol.Feature>|undefined),
* features: (ol.Collection.<module:ol/Feature~Feature>|undefined),
* source: (ol.source.Vector|undefined),
* dragVertexDelay: (number|undefined),
* snapTolerance: (number|undefined),
@@ -273,7 +273,7 @@ olx.interaction.DrawOptions.prototype.clickTolerance;
/**
* Destination collection for the drawn features.
* @type {ol.Collection.<ol.Feature>|undefined}
* @type {ol.Collection.<module:ol/Feature~Feature>|undefined}
* @api
*/
olx.interaction.DrawOptions.prototype.features;
@@ -465,7 +465,7 @@ olx.interaction.ExtentOptions.prototype.wrapX;
/**
* @typedef {{
* features: (ol.Collection.<ol.Feature>|undefined),
* features: (ol.Collection.<module:ol/Feature~Feature>|undefined),
* layers: (undefined|Array.<ol.layer.Layer>|function(ol.layer.Layer): boolean),
* hitTolerance: (number|undefined)
* }}
@@ -476,7 +476,7 @@ olx.interaction.TranslateOptions;
/**
* Only features contained in this collection will be able to be translated. If
* not specified, all features on the map will be able to be translated.
* @type {ol.Collection.<ol.Feature>|undefined}
* @type {ol.Collection.<module:ol/Feature~Feature>|undefined}
* @api
*/
olx.interaction.TranslateOptions.prototype.features;
@@ -581,7 +581,7 @@ olx.interaction.KeyboardZoomOptions.prototype.delta;
* pixelTolerance: (number|undefined),
* style: (ol.style.Style|Array.<ol.style.Style>|ol.StyleFunction|undefined),
* source: (ol.source.Vector|undefined),
* features: (ol.Collection.<ol.Feature>|undefined),
* features: (ol.Collection.<module:ol/Feature~Feature>|undefined),
* wrapX: (boolean|undefined)
* }}
*/
@@ -650,7 +650,7 @@ olx.interaction.ModifyOptions.prototype.source;
/**
* The features the interaction works on. If a feature collection is not
* provided, a vector source must be provided with the source option.
* @type {ol.Collection.<ol.Feature>|undefined}
* @type {ol.Collection.<module:ol/Feature~Feature>|undefined}
* @api
*/
olx.interaction.ModifyOptions.prototype.features;
@@ -832,7 +832,7 @@ olx.interaction.PointerOptions.prototype.handleUpEvent;
* removeCondition: (ol.EventsConditionType|undefined),
* toggleCondition: (ol.EventsConditionType|undefined),
* multi: (boolean|undefined),
* features: (ol.Collection.<ol.Feature>|undefined),
* features: (ol.Collection.<module:ol/Feature~Feature>|undefined),
* filter: (ol.SelectFilterFunction|undefined),
* wrapX: (boolean|undefined),
* hitTolerance: (number|undefined)}}
@@ -927,13 +927,13 @@ olx.interaction.SelectOptions.prototype.multi;
* not set the interaction will create a collection. In any case the collection
* used by the interaction is returned by
* {@link ol.interaction.Select#getFeatures}.
* @type {ol.Collection.<ol.Feature>|undefined}
* @type {ol.Collection.<module:ol/Feature~Feature>|undefined}
* @api
*/
olx.interaction.SelectOptions.prototype.features;
/**
* A function that takes an {@link ol.Feature} and an {@link ol.layer.Layer} and
* A function that takes an {@link module:ol/Feature~Feature} and an {@link ol.layer.Layer} and
* returns `true` if the feature may be selected or `false` otherwise.
* @type {ol.SelectFilterFunction|undefined}
* @api
@@ -962,7 +962,7 @@ olx.interaction.SelectOptions.prototype.hitTolerance;
/**
* Options for snap
* @typedef {{
* features: (ol.Collection.<ol.Feature>|undefined),
* features: (ol.Collection.<module:ol/Feature~Feature>|undefined),
* pixelTolerance: (number|undefined),
* source: (ol.source.Vector|undefined),
* edge: (boolean|undefined),
@@ -974,7 +974,7 @@ olx.interaction.SnapOptions;
/**
* Snap to these features. Either this option or source should be provided.
* @type {ol.Collection.<ol.Feature>|undefined}
* @type {ol.Collection.<module:ol/Feature~Feature>|undefined}
* @api
*/
olx.interaction.SnapOptions.prototype.features;
@@ -1220,7 +1220,7 @@ olx.layer.GroupOptions.prototype.layers;
* radius: (number|undefined),
* blur: (number|undefined),
* shadow: (number|undefined),
* weight: (string|function(ol.Feature):number|undefined),
* weight: (string|function(module:ol/Feature~Feature):number|undefined),
* extent: (ol.Extent|undefined),
* minResolution: (number|undefined),
* maxResolution: (number|undefined),
@@ -1269,7 +1269,7 @@ olx.layer.HeatmapOptions.prototype.shadow;
* The feature attribute to use for the weight or a function that returns a
* weight from a feature. Weight values should range from 0 to 1 (and values
* outside will be clamped to that range). Default is `weight`.
* @type {string|function(ol.Feature):number|undefined}
* @type {string|function(module:ol/Feature~Feature):number|undefined}
* @api
*/
olx.layer.HeatmapOptions.prototype.weight;
@@ -1867,7 +1867,7 @@ olx.layer.VectorTileOptions.prototype.zIndex;
/**
* @typedef {{context: CanvasRenderingContext2D,
* feature: (ol.Feature|ol.render.Feature),
* feature: (module:ol/Feature~Feature|ol.render.Feature),
* geometry: module:ol/geom/SimpleGeometry~SimpleGeometry,
* pixelRatio: number,
* resolution: number,
@@ -2017,7 +2017,7 @@ olx.source.BingMapsOptions.prototype.transition;
* distance: (number|undefined),
* extent: (ol.Extent|undefined),
* format: (ol.format.Feature|undefined),
* geometryFunction: (undefined|function(ol.Feature):module:ol/geom/Point~Point),
* geometryFunction: (undefined|function(module:ol/Feature~Feature):module:ol/geom/Point~Point),
* projection: ol.ProjectionLike,
* source: ol.source.Vector,
* wrapX: (boolean|undefined)}}
@@ -2050,7 +2050,7 @@ olx.source.ClusterOptions.prototype.extent;
/**
* Function that takes an {@link ol.Feature} as argument and returns an
* Function that takes an {@link module:ol/Feature~Feature} as argument and returns an
* {@link module:ol/geom/Point~Point} as cluster calculation point for the feature. When a
* feature should not be considered for clustering, the function should return
* `null`. The default, which works when the underyling source contains point
@@ -2062,7 +2062,7 @@ olx.source.ClusterOptions.prototype.extent;
* ```
* See {@link module:ol/geom/Polygon~Polygon#getInteriorPoint} for a way to get a cluster
* calculation point for polygons.
* @type {undefined|function(ol.Feature):module:ol/geom/Point~Point}
* @type {undefined|function(module:ol/Feature~Feature):module:ol/geom/Point~Point}
* @api
*/
olx.source.ClusterOptions.prototype.geometryFunction;
@@ -3693,12 +3693,12 @@ olx.source.TileWMSOptions.prototype.transition;
/**
* @typedef {{attributions: (ol.AttributionLike|undefined),
* features: (Array.<ol.Feature>|ol.Collection.<ol.Feature>|undefined),
* features: (Array.<module:ol/Feature~Feature>|ol.Collection.<module:ol/Feature~Feature>|undefined),
* format: (ol.format.Feature|undefined),
* loader: (ol.FeatureLoader|undefined),
* loader: (module:ol/Feature~FeatureLoader|undefined),
* overlaps: (boolean|undefined),
* strategy: (ol.LoadingStrategy|undefined),
* url: (string|ol.FeatureUrlFunction|undefined),
* url: (string|module:ol/Feature~FeatureUrlFunction|undefined),
* useSpatialIndex: (boolean|undefined),
* wrapX: (boolean|undefined)}}
*/
@@ -3716,7 +3716,7 @@ olx.source.VectorOptions.prototype.attributions;
/**
* Features. If provided as {@link ol.Collection}, the features in the source
* and the collection will stay in sync.
* @type {Array.<ol.Feature>|ol.Collection.<ol.Feature>|undefined}
* @type {Array.<module:ol/Feature~Feature>|ol.Collection.<module:ol/Feature~Feature>|undefined}
* @api
*/
olx.source.VectorOptions.prototype.features;
@@ -3766,7 +3766,7 @@ olx.source.VectorOptions.prototype.format;
* strategy: ol.loadingstrategy.bbox
* });
* ```
* @type {ol.FeatureLoader|undefined}
* @type {module:ol/Feature~FeatureLoader|undefined}
* @api
*/
olx.source.VectorOptions.prototype.loader;
@@ -3796,7 +3796,7 @@ olx.source.VectorOptions.prototype.strategy;
* Setting this option instructs the source to load features using an XHR loader
* (see {@link ol.featureloader.xhr}). Use a `string` and an
* {@link ol.loadingstrategy.all} for a one-off download of all features from
* the given URL. Use a {@link ol.FeatureUrlFunction} to generate the url with
* the given URL. Use a {@link module:ol/Feature~FeatureUrlFunction} to generate the url with
* other loading strategies.
* Requires `format` to be set as well.
* When default XHR feature loader is provided, the features will
@@ -3807,7 +3807,7 @@ olx.source.VectorOptions.prototype.strategy;
* defaultDataProjection constructor option on the format.
* Note that if a source contains non-feature data, such as a GeoJSON geometry
* or a KML NetworkLink, these will be ignored. Use a custom loader to load these.
* @type {string|ol.FeatureUrlFunction|undefined}
* @type {string|module:ol/Feature~FeatureUrlFunction|undefined}
* @api
*/
olx.source.VectorOptions.prototype.url;
+12 -12
View File
@@ -78,7 +78,7 @@
* geometry being drawn. Default is 6 pixels. That value was chosen for
* the draw interaction to behave correctly on mouse as well as on touch
* devices.
* @property {ol.Collection.<ol.Feature>|undefined} features Destination collection for the drawn features.
* @property {ol.Collection.<module:ol/Feature~Feature>|undefined} features Destination collection for the drawn features.
* @property {ol.source.Vector|undefined} source Destination source for the drawn features.
* @property {number|undefined} dragVertexDelay Delay in milliseconds after pointerdown before the current vertex can be
* dragged to its exact position. Default is 500 ms.
@@ -128,7 +128,7 @@
/**
* @typedef {Object} interaction_TranslateOptions
* @property {ol.Collection.<ol.Feature>|undefined} features Only features contained in this collection will be able to be translated. If
* @property {ol.Collection.<module:ol/Feature~Feature>|undefined} features Only features contained in this collection will be able to be translated. If
* not specified, all features on the map will be able to be translated.
* @property {undefined|Array.<ol.layer.Layer>|function(ol.layer.Layer): boolean} layers A list of layers from which features should be
* translated. Alternatively, a filter function can be provided. The
@@ -181,7 +181,7 @@
* style is used (see {@link ol.style}).
* @property {ol.source.Vector|undefined} source The vector source with features to modify. If a vector source is not
* provided, a feature collection must be provided with the features option.
* @property {ol.Collection.<ol.Feature>|undefined} features The features the interaction works on. If a feature collection is not
* @property {ol.Collection.<module:ol/Feature~Feature>|undefined} features The features the interaction works on. If a feature collection is not
* provided, a vector source must be provided with the source option.
* @property {boolean|undefined} wrapX Wrap the world horizontally on the sketch overlay. Default is `false`.
*/
@@ -270,11 +270,11 @@
* @property {boolean|undefined} multi A boolean that determines if the default behaviour should select only
* single features or all (overlapping) features at the clicked map
* position. Default is false i.e single select
* @property {ol.Collection.<ol.Feature>|undefined} features Collection where the interaction will place selected features. Optional. If
* @property {ol.Collection.<module:ol/Feature~Feature>|undefined} features Collection where the interaction will place selected features. Optional. If
* not set the interaction will create a collection. In any case the collection
* used by the interaction is returned by
* {@link ol.interaction.Select#getFeatures}.
* @property {ol.SelectFilterFunction|undefined} filter A function that takes an {@link ol.Feature} and an {@link ol.layer.Layer} and
* @property {ol.SelectFilterFunction|undefined} filter A function that takes an {@link module:ol/Feature~Feature} and an {@link ol.layer.Layer} and
* returns `true` if the feature may be selected or `false` otherwise.
* @property {boolean|undefined} wrapX Wrap the world horizontally on the selection overlay. Default is `true`.
* @property {number|undefined} hitTolerance Hit-detection tolerance. Pixels inside the radius around the given position
@@ -285,7 +285,7 @@
/**
* @typedef {Object} interaction_SnapOptions
* @property {ol.Collection.<ol.Feature>|undefined} features Snap to these features. Either this option or source should be provided.
* @property {ol.Collection.<module:ol/Feature~Feature>|undefined} features Snap to these features. Either this option or source should be provided.
* @property {boolean|undefined} edge Snap to edges. Default is `true`.
* @property {boolean|undefined} vertex Snap to vertices. Default is `true`.
* @property {number|undefined} pixelTolerance Pixel tolerance for considering the pointer close enough to a segment or
@@ -344,7 +344,7 @@
* @property {number|undefined} radius Radius size in pixels. Default is `8`.
* @property {number|undefined} blur Blur size in pixels. Default is `15`.
* @property {number|undefined} shadow Shadow size in pixels. Default is `250`.
* @property {string|function(ol.Feature):number|undefined} weight The feature attribute to use for the weight or a function that returns a
* @property {string|function(module:ol/Feature~Feature):number|undefined} weight The feature attribute to use for the weight or a function that returns a
* weight from a feature. Weight values should range from 0 to 1 (and values
* outside will be clamped to that range). Default is `weight`.
* @property {ol.Extent|undefined} extent The bounding extent for layer rendering. The layer will not be rendered
@@ -532,7 +532,7 @@
* @property {ol.AttributionLike|undefined} attributions Attributions.
* @property {number|undefined} distance Minimum distance in pixels between clusters. Default is `20`.
* @property {ol.Extent|undefined} extent Extent.
* @property {undefined|function(ol.Feature):module:ol/geom/Point~Point} geometryFunction Function that takes an {@link ol.Feature} as argument and returns an
* @property {undefined|function(module:ol/Feature~Feature):module:ol/geom/Point~Point} geometryFunction Function that takes an {@link module:ol/Feature~Feature} as argument and returns an
* {@link module:ol/geom/Point~Point} as cluster calculation point for the feature. When a
* feature should not be considered for clustering, the function should return
* `null`. The default, which works when the underyling source contains point
@@ -977,11 +977,11 @@
/**
* @typedef {Object} source_VectorOptions
* @property {ol.AttributionLike|undefined} attributions Attributions.
* @property {Array.<ol.Feature>|ol.Collection.<ol.Feature>|undefined} features Features. If provided as {@link ol.Collection}, the features in the source
* @property {Array.<module:ol/Feature~Feature>|ol.Collection.<module:ol/Feature~Feature>|undefined} features Features. If provided as {@link ol.Collection}, the features in the source
* and the collection will stay in sync.
* @property {ol.format.Feature|undefined} format The feature format used by the XHR feature loader when `url` is set.
* Required if `url` is set, otherwise ignored. Default is `undefined`.
* @property {ol.FeatureLoader|undefined} loader The loader function used to load features, from a remote source for example.
* @property {module:ol/Feature~FeatureLoader|undefined} loader The loader function used to load features, from a remote source for example.
* If this is not set and `url` is set, the source will create and use an XHR
* feature loader.
*
@@ -1021,10 +1021,10 @@
* stroke operations.
* @property {ol.LoadingStrategy|undefined} strategy The loading strategy to use. By default an {@link ol.loadingstrategy.all}
* strategy is used, a one-off strategy which loads all features at once.
* @property {string|ol.FeatureUrlFunction|undefined} url Setting this option instructs the source to load features using an XHR loader
* @property {string|module:ol/Feature~FeatureUrlFunction|undefined} url Setting this option instructs the source to load features using an XHR loader
* (see {@link ol.featureloader.xhr}). Use a `string` and an
* {@link ol.loadingstrategy.all} for a one-off download of all features from
* the given URL. Use a {@link ol.FeatureUrlFunction} to generate the url with
* the given URL. Use a {@link module:ol/Feature~FeatureUrlFunction} to generate the url with
* other loading strategies.
* Requires `format` to be set as well.
* When default XHR feature loader is provided, the features will