Add @api stable annotations for ol.geom.Geometry

This commit is contained in:
Éric Lemoine
2014-08-19 17:04:05 +02:00
parent 239a90cd55
commit 9b0ce7b80c

View File

@@ -12,7 +12,7 @@ goog.require('ol.proj');
* `'Polygon'`, `'MultiPoint'`, `'MultiLineString'`, `'MultiPolygon'`, * `'Polygon'`, `'MultiPoint'`, `'MultiLineString'`, `'MultiPolygon'`,
* `'GeometryCollection'`, `'Circle'`. * `'GeometryCollection'`, `'Circle'`.
* @enum {string} * @enum {string}
* @api * @api stable
*/ */
ol.geom.GeometryType = { ol.geom.GeometryType = {
POINT: 'Point', POINT: 'Point',
@@ -32,7 +32,7 @@ ol.geom.GeometryType = {
* or measure ('M') coordinate is available. Supported values are `'XY'`, * or measure ('M') coordinate is available. Supported values are `'XY'`,
* `'XYZ'`, `'XYM'`, `'XYZM'`. * `'XYZ'`, `'XYM'`, `'XYZM'`.
* @enum {string} * @enum {string}
* @api * @api stable
*/ */
ol.geom.GeometryLayout = { ol.geom.GeometryLayout = {
XY: 'XY', XY: 'XY',
@@ -52,7 +52,7 @@ ol.geom.GeometryLayout = {
* @constructor * @constructor
* @extends {ol.Observable} * @extends {ol.Observable}
* @fires change Triggered when the geometry changes. * @fires change Triggered when the geometry changes.
* @api * @api stable
*/ */
ol.geom.Geometry = function() { ol.geom.Geometry = function() {
@@ -96,7 +96,7 @@ goog.inherits(ol.geom.Geometry, ol.Observable);
* Make a complete copy of the geometry. * Make a complete copy of the geometry.
* @function * @function
* @return {ol.geom.Geometry} Clone. * @return {ol.geom.Geometry} Clone.
* @api * @api stable
*/ */
ol.geom.Geometry.prototype.clone = goog.abstractMethod; ol.geom.Geometry.prototype.clone = goog.abstractMethod;
@@ -115,7 +115,7 @@ ol.geom.Geometry.prototype.closestPointXY = goog.abstractMethod;
* @param {ol.Coordinate} point Point. * @param {ol.Coordinate} point Point.
* @param {ol.Coordinate=} opt_closestPoint Closest point. * @param {ol.Coordinate=} opt_closestPoint Closest point.
* @return {ol.Coordinate} Closest point. * @return {ol.Coordinate} Closest point.
* @api * @api stable
*/ */
ol.geom.Geometry.prototype.getClosestPoint = function(point, opt_closestPoint) { ol.geom.Geometry.prototype.getClosestPoint = function(point, opt_closestPoint) {
var closestPoint = goog.isDef(opt_closestPoint) ? var closestPoint = goog.isDef(opt_closestPoint) ?
@@ -147,7 +147,7 @@ ol.geom.Geometry.prototype.containsXY = goog.functions.FALSE;
* @function * @function
* @param {ol.Extent=} opt_extent Extent. * @param {ol.Extent=} opt_extent Extent.
* @return {ol.Extent} extent Extent. * @return {ol.Extent} extent Extent.
* @api * @api stable
*/ */
ol.geom.Geometry.prototype.getExtent = goog.abstractMethod; ol.geom.Geometry.prototype.getExtent = goog.abstractMethod;
@@ -159,7 +159,6 @@ ol.geom.Geometry.prototype.getExtent = goog.abstractMethod;
* @function * @function
* @param {number} squaredTolerance Squared tolerance. * @param {number} squaredTolerance Squared tolerance.
* @return {ol.geom.Geometry} Simplified geometry. * @return {ol.geom.Geometry} Simplified geometry.
* @api
*/ */
ol.geom.Geometry.prototype.getSimplifiedGeometry = goog.abstractMethod; ol.geom.Geometry.prototype.getSimplifiedGeometry = goog.abstractMethod;
@@ -168,7 +167,7 @@ ol.geom.Geometry.prototype.getSimplifiedGeometry = goog.abstractMethod;
* Get the type of this geometry. * Get the type of this geometry.
* @function * @function
* @return {ol.geom.GeometryType} Geometry type. * @return {ol.geom.GeometryType} Geometry type.
* @api * @api stable
*/ */
ol.geom.Geometry.prototype.getType = goog.abstractMethod; ol.geom.Geometry.prototype.getType = goog.abstractMethod;
@@ -179,7 +178,7 @@ ol.geom.Geometry.prototype.getType = goog.abstractMethod;
* then use this function on the clone. * then use this function on the clone.
* @function * @function
* @param {ol.TransformFunction} transformFn Transform. * @param {ol.TransformFunction} transformFn Transform.
* @api * @api stable
*/ */
ol.geom.Geometry.prototype.applyTransform = goog.abstractMethod; ol.geom.Geometry.prototype.applyTransform = goog.abstractMethod;
@@ -196,7 +195,7 @@ ol.geom.Geometry.prototype.applyTransform = goog.abstractMethod;
* string identifier or a {@link ol.proj.Projection} object. * string identifier or a {@link ol.proj.Projection} object.
* @return {ol.geom.Geometry} This geometry. Note that original geometry is * @return {ol.geom.Geometry} This geometry. Note that original geometry is
* modified in place. * modified in place.
* @api * @api stable
*/ */
ol.geom.Geometry.prototype.transform = function(source, destination) { ol.geom.Geometry.prototype.transform = function(source, destination) {
this.applyTransform(ol.proj.getTransform(source, destination)); this.applyTransform(ol.proj.getTransform(source, destination));
@@ -207,7 +206,7 @@ ol.geom.Geometry.prototype.transform = function(source, destination) {
/** /**
* Array representation of a point. Example: `[16, 48]`. * Array representation of a point. Example: `[16, 48]`.
* @typedef {ol.Coordinate} * @typedef {ol.Coordinate}
* @api * @api stable
*/ */
ol.geom.RawPoint; ol.geom.RawPoint;
@@ -215,7 +214,7 @@ ol.geom.RawPoint;
/** /**
* Array representation of a linestring. * Array representation of a linestring.
* @typedef {Array.<ol.Coordinate>} * @typedef {Array.<ol.Coordinate>}
* @api * @api stable
*/ */
ol.geom.RawLineString; ol.geom.RawLineString;
@@ -223,7 +222,7 @@ ol.geom.RawLineString;
/** /**
* Array representation of a linear ring. * Array representation of a linear ring.
* @typedef {Array.<ol.Coordinate>} * @typedef {Array.<ol.Coordinate>}
* @api * @api stable
*/ */
ol.geom.RawLinearRing; ol.geom.RawLinearRing;
@@ -231,7 +230,7 @@ ol.geom.RawLinearRing;
/** /**
* Array representation of a polygon. * Array representation of a polygon.
* @typedef {Array.<ol.geom.RawLinearRing>} * @typedef {Array.<ol.geom.RawLinearRing>}
* @api * @api stable
*/ */
ol.geom.RawPolygon; ol.geom.RawPolygon;
@@ -239,7 +238,7 @@ ol.geom.RawPolygon;
/** /**
* Array representation of a multipoint. * Array representation of a multipoint.
* @typedef {Array.<ol.geom.RawPoint>} * @typedef {Array.<ol.geom.RawPoint>}
* @api * @api stable
*/ */
ol.geom.RawMultiPoint; ol.geom.RawMultiPoint;
@@ -247,7 +246,7 @@ ol.geom.RawMultiPoint;
/** /**
* Array representation of a multilinestring. * Array representation of a multilinestring.
* @typedef {Array.<ol.geom.RawLineString>} * @typedef {Array.<ol.geom.RawLineString>}
* @api * @api stable
*/ */
ol.geom.RawMultiLineString; ol.geom.RawMultiLineString;
@@ -255,6 +254,6 @@ ol.geom.RawMultiLineString;
/** /**
* Array representation of a multipolygon. * Array representation of a multipolygon.
* @typedef {Array.<ol.geom.RawPolygon>} * @typedef {Array.<ol.geom.RawPolygon>}
* @api * @api stable
*/ */
ol.geom.RawMultiPolygon; ol.geom.RawMultiPolygon;