Merge pull request #2552 from elemoine/apistable

Add @api stable annotations for the ol.layer namespace
This commit is contained in:
Éric Lemoine
2014-08-22 19:01:13 +02:00
7 changed files with 62 additions and 52 deletions

View File

@@ -2349,7 +2349,7 @@ olx.layer.BaseOptions.prototype.hue;
/**
* Opacity (0, 1). Default is `1`.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.BaseOptions.prototype.opacity;
@@ -2365,7 +2365,7 @@ olx.layer.BaseOptions.prototype.saturation;
/**
* Visibility. Default is `true`.
* @type {boolean|undefined}
* @api
* @api stable
*/
olx.layer.BaseOptions.prototype.visible;
@@ -2374,7 +2374,7 @@ olx.layer.BaseOptions.prototype.visible;
* The bounding extent for layer rendering. The layer will not be rendered
* outside of this extent.
* @type {ol.Extent|undefined}
* @api
* @api stable
*/
olx.layer.BaseOptions.prototype.extent;
@@ -2382,7 +2382,7 @@ olx.layer.BaseOptions.prototype.extent;
/**
* The minimum resolution (inclusive) at which this layer will be visible.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.BaseOptions.prototype.minResolution;
@@ -2390,6 +2390,7 @@ olx.layer.BaseOptions.prototype.minResolution;
/**
* The maximum resolution (exclusive) below which this layer will be visible.
* @type {number|undefined}
* @api stable
*/
olx.layer.BaseOptions.prototype.maxResolution;
@@ -2437,7 +2438,7 @@ olx.layer.LayerOptions.prototype.hue;
/**
* Opacity (0, 1). Default is `1`.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.LayerOptions.prototype.opacity;
@@ -2453,7 +2454,7 @@ olx.layer.LayerOptions.prototype.saturation;
/**
* Source for this layer.
* @type {ol.source.Source}
* @api
* @api stable
*/
olx.layer.LayerOptions.prototype.source;
@@ -2461,7 +2462,7 @@ olx.layer.LayerOptions.prototype.source;
/**
* Visibility. Default is `true` (visible).
* @type {boolean|undefined}
* @api
* @api stable
*/
olx.layer.LayerOptions.prototype.visible;
@@ -2470,7 +2471,7 @@ olx.layer.LayerOptions.prototype.visible;
* The bounding extent for layer rendering. The layer will not be rendered
* outside of this extent.
* @type {ol.Extent|undefined}
* @api
* @api stable
*/
olx.layer.LayerOptions.prototype.extent;
@@ -2478,7 +2479,7 @@ olx.layer.LayerOptions.prototype.extent;
/**
* The minimum resolution (inclusive) at which this layer will be visible.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.LayerOptions.prototype.minResolution;
@@ -2486,7 +2487,7 @@ olx.layer.LayerOptions.prototype.minResolution;
/**
* The maximum resolution (exclusive) below which this layer will be visible.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.LayerOptions.prototype.maxResolution;
@@ -2534,6 +2535,7 @@ olx.layer.GroupOptions.prototype.hue;
/**
* Opacity (0, 1). Default is `1`.
* @type {number|undefined}
* @api stable
*/
olx.layer.GroupOptions.prototype.opacity;
@@ -2541,6 +2543,7 @@ olx.layer.GroupOptions.prototype.opacity;
/**
* Saturation. Default is `1`.
* @type {number|undefined}
* @api
*/
olx.layer.GroupOptions.prototype.saturation;
@@ -2548,7 +2551,7 @@ olx.layer.GroupOptions.prototype.saturation;
/**
* Visibility. Default is `true`.
* @type {boolean|undefined}
* @api
* @api stable
*/
olx.layer.GroupOptions.prototype.visible;
@@ -2557,7 +2560,7 @@ olx.layer.GroupOptions.prototype.visible;
* The bounding extent for layer rendering. The layer will not be rendered
* outside of this extent.
* @type {ol.Extent|undefined}
* @api
* @api stable
*/
olx.layer.GroupOptions.prototype.extent;
@@ -2565,7 +2568,7 @@ olx.layer.GroupOptions.prototype.extent;
/**
* The minimum resolution (inclusive) at which this layer will be visible.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.GroupOptions.prototype.minResolution;
@@ -2573,7 +2576,7 @@ olx.layer.GroupOptions.prototype.minResolution;
/**
* The maximum resolution (exclusive) below which this layer will be visible.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.GroupOptions.prototype.maxResolution;
@@ -2581,7 +2584,7 @@ olx.layer.GroupOptions.prototype.maxResolution;
/**
* Child layers.
* @type {Array.<ol.layer.Base>|ol.Collection.<ol.layer.Base>|undefined}
* @api
* @api stable
*/
olx.layer.GroupOptions.prototype.layers;
@@ -2776,15 +2779,16 @@ olx.layer.TileOptions.prototype.hue;
/**
* Opacity (0, 1). Default is `1`.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.TileOptions.prototype.opacity;
/**
* Preload.
* Preload. Load low-resolution tiles up to `preload` levels. By default
* `preload` is `0`, which means no preloading.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.TileOptions.prototype.preload;
@@ -2800,7 +2804,7 @@ olx.layer.TileOptions.prototype.saturation;
/**
* Source for this layer.
* @type {ol.source.Source}
* @api
* @api stable
*/
olx.layer.TileOptions.prototype.source;
@@ -2808,7 +2812,7 @@ olx.layer.TileOptions.prototype.source;
/**
* Visibility. Default is `true` (visible).
* @type {boolean|undefined}
* @api
* @api stable
*/
olx.layer.TileOptions.prototype.visible;
@@ -2817,7 +2821,7 @@ olx.layer.TileOptions.prototype.visible;
* The bounding extent for layer rendering. The layer will not be rendered
* outside of this extent.
* @type {ol.Extent|undefined}
* @api
* @api stable
*/
olx.layer.TileOptions.prototype.extent;
@@ -2825,7 +2829,7 @@ olx.layer.TileOptions.prototype.extent;
/**
* The minimum resolution (inclusive) at which this layer will be visible.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.TileOptions.prototype.minResolution;
@@ -2833,7 +2837,7 @@ olx.layer.TileOptions.prototype.minResolution;
/**
* The maximum resolution (exclusive) below which this layer will be visible.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.TileOptions.prototype.maxResolution;
@@ -2841,7 +2845,7 @@ olx.layer.TileOptions.prototype.maxResolution;
/**
* Use interim tiles on error. Default is `true`.
* @type {boolean|undefined}
* @api
* @api stable
*/
olx.layer.TileOptions.prototype.useInterimTilesOnError;
@@ -2901,7 +2905,7 @@ olx.layer.VectorOptions.prototype.hue;
* The bounding extent for layer rendering. The layer will not be rendered
* outside of this extent.
* @type {ol.Extent|undefined}
* @api
* @api stable
*/
olx.layer.VectorOptions.prototype.extent;
@@ -2909,7 +2913,7 @@ olx.layer.VectorOptions.prototype.extent;
/**
* The minimum resolution (inclusive) at which this layer will be visible.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.VectorOptions.prototype.minResolution;
@@ -2917,7 +2921,7 @@ olx.layer.VectorOptions.prototype.minResolution;
/**
* The maximum resolution (exclusive) below which this layer will be visible.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.VectorOptions.prototype.maxResolution;
@@ -2925,7 +2929,7 @@ olx.layer.VectorOptions.prototype.maxResolution;
/**
* Opacity. 0-1. Default is `1`.
* @type {number|undefined}
* @api
* @api stable
*/
olx.layer.VectorOptions.prototype.opacity;
@@ -2941,7 +2945,7 @@ olx.layer.VectorOptions.prototype.saturation;
/**
* Source.
* @type {ol.source.Vector}
* @api
* @api stable
*/
olx.layer.VectorOptions.prototype.source;
@@ -2950,7 +2954,7 @@ olx.layer.VectorOptions.prototype.source;
* Layer style. See {@link ol.style} for default style which will be used if
* this is not defined.
* @type {ol.style.Style|Array.<ol.style.Style>|ol.style.StyleFunction|undefined}
* @api
* @api stable
*/
olx.layer.VectorOptions.prototype.style;
@@ -2958,7 +2962,7 @@ olx.layer.VectorOptions.prototype.style;
/**
* Visibility. Default is `true` (visible).
* @type {boolean|undefined}
* @api
* @api stable
*/
olx.layer.VectorOptions.prototype.visible;

View File

@@ -16,7 +16,7 @@ goog.require('ol.layer.Layer');
* @extends {ol.layer.Layer}
* @fires ol.render.Event
* @param {olx.layer.LayerOptions} options Layer options.
* @api
* @api stable
*/
ol.layer.Image = function(options) {
goog.base(this, options);

View File

@@ -22,7 +22,7 @@ goog.require('ol.source.Source');
* @fires ol.render.Event
* @fires change Triggered when the state of the source changes.
* @param {olx.layer.LayerOptions} options Layer options.
* @api
* @api stable
*/
ol.layer.Layer = function(options) {
@@ -80,7 +80,7 @@ ol.layer.Layer.prototype.getLayerStatesArray = function(opt_states) {
/**
* @return {ol.source.Source} Source.
* @api
* @api stable
*/
ol.layer.Layer.prototype.getSource = function() {
return this.source_;

View File

@@ -181,7 +181,7 @@ ol.layer.Base.prototype.getLayerStatesArray = goog.abstractMethod;
/**
* @return {ol.Extent|undefined} The layer extent.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.getExtent = function() {
return /** @type {ol.Extent|undefined} */ (
@@ -196,7 +196,7 @@ goog.exportProperty(
/**
* @return {number|undefined} The maximum resolution of the layer.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.getMaxResolution = function() {
return /** @type {number|undefined} */ (
@@ -211,7 +211,7 @@ goog.exportProperty(
/**
* @return {number|undefined} The minimum resolution of the layer.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.getMinResolution = function() {
return /** @type {number|undefined} */ (
@@ -226,7 +226,7 @@ goog.exportProperty(
/**
* @return {number|undefined} The opacity of the layer.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.getOpacity = function() {
return /** @type {number|undefined} */ (
@@ -262,7 +262,7 @@ ol.layer.Base.prototype.getSourceState = goog.abstractMethod;
/**
* @return {boolean|undefined} The visiblity of the layer.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.getVisible = function() {
return /** @type {boolean|undefined} */ (
@@ -344,7 +344,7 @@ goog.exportProperty(
* will be visible at all extents.
* @param {ol.Extent|undefined} extent The extent of the layer.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.setExtent = function(extent) {
this.set(ol.layer.LayerProperty.EXTENT, extent);
@@ -358,7 +358,7 @@ goog.exportProperty(
/**
* @param {number|undefined} maxResolution The maximum resolution of the layer.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.setMaxResolution = function(maxResolution) {
this.set(ol.layer.LayerProperty.MAX_RESOLUTION, maxResolution);
@@ -372,7 +372,7 @@ goog.exportProperty(
/**
* @param {number|undefined} minResolution The minimum resolution of the layer.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.setMinResolution = function(minResolution) {
this.set(ol.layer.LayerProperty.MIN_RESOLUTION, minResolution);
@@ -386,7 +386,7 @@ goog.exportProperty(
/**
* @param {number|undefined} opacity The opacity of the layer.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.setOpacity = function(opacity) {
this.set(ol.layer.LayerProperty.OPACITY, opacity);
@@ -419,7 +419,7 @@ goog.exportProperty(
/**
* @param {boolean|undefined} visible The visiblity of the layer.
* @observable
* @api
* @api stable
*/
ol.layer.Base.prototype.setVisible = function(visible) {
this.set(ol.layer.LayerProperty.VISIBLE, visible);

View File

@@ -33,7 +33,7 @@ ol.layer.GroupProperty = {
* @extends {ol.layer.Base}
* @fires change Triggered when the group/Collection changes.
* @param {olx.layer.GroupOptions=} opt_options Layer options.
* @api
* @api stable
*/
ol.layer.Group = function(opt_options) {
@@ -148,7 +148,7 @@ ol.layer.Group.prototype.handleLayersRemove_ = function(collectionEvent) {
* @return {ol.Collection.<ol.layer.Base>|undefined} Collection of
* {@link ol.layer.Layer layers} that are part of this group.
* @observable
* @api
* @api stable
*/
ol.layer.Group.prototype.getLayers = function() {
return /** @type {ol.Collection.<ol.layer.Base>|undefined} */ (this.get(
@@ -164,7 +164,7 @@ goog.exportProperty(
* @param {ol.Collection.<ol.layer.Base>|undefined} layers Collection of
* {@link ol.layer.Layer layers} that are part of this group.
* @observable
* @api
* @api stable
*/
ol.layer.Group.prototype.setLayers = function(layers) {
this.set(ol.layer.GroupProperty.LAYERS, layers);

View File

@@ -25,7 +25,7 @@ ol.layer.TileProperty = {
* @extends {ol.layer.Layer}
* @fires ol.render.Event
* @param {olx.layer.TileOptions} options Tile layer options.
* @api
* @api stable
*/
ol.layer.Tile = function(options) {
goog.base(this, options);
@@ -37,6 +37,7 @@ goog.inherits(ol.layer.Tile, ol.layer.Layer);
/**
* @return {number|undefined} The level to preload tiles up to.
* @observable
* @api
*/
ol.layer.Tile.prototype.getPreload = function() {
return /** @type {number|undefined} */ (
@@ -51,6 +52,7 @@ goog.exportProperty(
/**
* @param {number} preload The level to preload tiles up to.
* @observable
* @api
*/
ol.layer.Tile.prototype.setPreload = function(preload) {
this.set(ol.layer.TileProperty.PRELOAD, preload);
@@ -63,6 +65,8 @@ goog.exportProperty(
/**
* @return {boolean|undefined} Use interim tiles on error.
* @observable
* @api
*/
ol.layer.Tile.prototype.getUseInterimTilesOnError = function() {
return /** @type {boolean|undefined} */ (
@@ -76,6 +80,8 @@ goog.exportProperty(
/**
* @param {boolean|undefined} useInterimTilesOnError Use interim tiles on error.
* @observable
* @api
*/
ol.layer.Tile.prototype.setUseInterimTilesOnError =
function(useInterimTilesOnError) {

View File

@@ -25,7 +25,7 @@ ol.layer.VectorProperty = {
* @extends {ol.layer.Layer}
* @fires ol.render.Event
* @param {olx.layer.VectorOptions=} opt_options Options.
* @api
* @api stable
*/
ol.layer.Vector = function(opt_options) {
@@ -73,7 +73,7 @@ ol.layer.Vector.prototype.getRenderOrder = function() {
* option at construction or to the `setStyle` method.
* @return {ol.style.Style|Array.<ol.style.Style>|ol.style.StyleFunction}
* Layer style.
* @api
* @api stable
*/
ol.layer.Vector.prototype.getStyle = function() {
return this.style_;
@@ -83,7 +83,7 @@ ol.layer.Vector.prototype.getStyle = function() {
/**
* Get the style function.
* @return {ol.style.StyleFunction|undefined} Layer style function.
* @api
* @api stable
*/
ol.layer.Vector.prototype.getStyleFunction = function() {
return this.styleFunction_;
@@ -105,7 +105,7 @@ ol.layer.Vector.prototype.setRenderOrder = function(renderOrder) {
* an array of styles.
* @param {ol.style.Style|Array.<ol.style.Style>|ol.style.StyleFunction} style
* Layer style.
* @api
* @api stable
*/
ol.layer.Vector.prototype.setStyle = function(style) {
this.style_ = style;