diff --git a/apidoc/plugins/exports.js b/apidoc/plugins/exports.js
index f2b19c2d57..6e8eaaf4b0 100644
--- a/apidoc/plugins/exports.js
+++ b/apidoc/plugins/exports.js
@@ -30,7 +30,6 @@ function collectExports(source) {
var encoding = env.conf.encoding || 'utf8';
var fs = require('jsdoc/fs');
collectExports(fs.readFileSync('build/src/external/src/exports.js', encoding));
-collectExports(fs.readFileSync('build/src/external/src/types.js', encoding));
exports.handlers = {
diff --git a/bin/generate-exports.py b/bin/generate-exports.py
index e00a8e1770..5205f692cb 100755
--- a/bin/generate-exports.py
+++ b/bin/generate-exports.py
@@ -220,7 +220,7 @@ class ObjectLiteral(Exportable):
return ''.join(lines)
def extern_name(self):
- return re.sub(r'ol\.(\S+)', r'olx.\1Extern', self.name)
+ return re.sub(r'(olx\.\S+)', r'\1Extern', self.name)
def extern_namespace(self):
return '.'.join(self.extern_name().split('.')[:-1]) or None
@@ -398,6 +398,7 @@ def main(argv):
else:
sys.stdout.write('var %s;\n' % (namespace,))
for object_literal in object_literals:
+ sys.stdout.write(object_literal.typedef())
sys.stdout.write(object_literal.extern())
if options.typedef:
diff --git a/build.py b/build.py
index 32578a3679..4e60d165ff 100755
--- a/build.py
+++ b/build.py
@@ -91,8 +91,7 @@ EXPORTS = [path
EXTERNAL_SRC = [
'build/src/external/externs/types.js',
- 'build/src/external/src/exports.js',
- 'build/src/external/src/types.js']
+ 'build/src/external/src/exports.js']
EXAMPLES = [path
for path in ifind('examples')
@@ -237,13 +236,6 @@ def build_src_external_src_exports_js(t):
'--exports', 'src/objectliterals.jsdoc', EXPORTS)
-@target('build/src/external/src/types.js', 'bin/generate-exports.py',
- 'src/objectliterals.jsdoc')
-def build_src_external_src_types_js(t):
- t.output('%(PYTHON)s', 'bin/generate-exports.py',
- '--typedef', 'src/objectliterals.jsdoc')
-
-
for glsl_src in GLSL_SRC:
def shader_src_helper(glsl_src):
@target(glsl_src.replace('.glsl', 'shader.js'), glsl_src,
diff --git a/buildcfg/ol-all.json b/buildcfg/ol-all.json
index b3a6cfd3de..02563fec18 100644
--- a/buildcfg/ol-all.json
+++ b/buildcfg/ol-all.json
@@ -18,7 +18,6 @@
"inputs": [
"../build/src/internal/src/requireall.js",
- "../build/src/internal/src/types.js",
"../build/src/external/src/exports.js"
]
diff --git a/buildcfg/ol-simple.json b/buildcfg/ol-simple.json
index 93192f4484..4afa4b5ff6 100644
--- a/buildcfg/ol-simple.json
+++ b/buildcfg/ol-simple.json
@@ -14,6 +14,7 @@
"externs": [
"//json.js",
+ "../build/src/external/externs/types.js",
"../externs/bingmaps.js",
"../externs/geojson.js",
"../externs/topojson.js",
@@ -27,7 +28,7 @@
"inputs": [
"../build/src/internal/src/requireall.js",
- "../build/src/internal/src/types.js"
+ "../build/src/external/src/exports.js"
],
"mode": "SIMPLE",
diff --git a/buildcfg/ol-whitespace.json b/buildcfg/ol-whitespace.json
index c17f47682b..b74b4a8376 100644
--- a/buildcfg/ol-whitespace.json
+++ b/buildcfg/ol-whitespace.json
@@ -27,8 +27,7 @@
"inherits": "ol.json",
"inputs": [
- "../build/src/internal/src/requireall.js",
- "../build/src/internal/src/types.js"
+ "../build/src/internal/src/requireall.js"
],
"mode": "WHITESPACE",
diff --git a/buildcfg/ol.json b/buildcfg/ol.json
index a315972e4a..6c207af40a 100644
--- a/buildcfg/ol.json
+++ b/buildcfg/ol.json
@@ -27,8 +27,7 @@
"inherits": "base.json",
"inputs": [
- "../build/src/external/src/exports.js",
- "../build/src/external/src/types.js"
+ "../build/src/external/src/exports.js"
],
"output-wrapper": "// OpenLayers 3. see http://ol3js.org/\n(function(){%output%})();",
diff --git a/old/examples/draw-features.html b/old/examples/draw-features.html
index 5459365499..ebe5703c91 100644
--- a/old/examples/draw-features.html
+++ b/old/examples/draw-features.html
@@ -36,9 +36,9 @@
diff --git a/old/examples/style-rules.js b/old/examples/style-rules.js
index c78bcb207f..7134d9fb6a 100644
--- a/old/examples/style-rules.js
+++ b/old/examples/style-rules.js
@@ -44,7 +44,7 @@ var style = new ol.style.Style({rules: [
]
}),
new ol.style.Rule({
- filter: 'geometryType("point")',
+ filter: 'geometryType("Point")',
symbolizers: [
new ol.style.Shape({
size: 40,
diff --git a/old/examples/wkt.js b/old/examples/wkt.js
index 793de87854..4ea4b41aca 100644
--- a/old/examples/wkt.js
+++ b/old/examples/wkt.js
@@ -1,3 +1,4 @@
+goog.require('ol.Feature');
goog.require('ol.Map');
goog.require('ol.RendererHint');
goog.require('ol.View2D');
@@ -12,13 +13,19 @@ var raster = new ol.layer.Tile({
source: new ol.source.OSM()
});
+var parser = new ol.parser.WKT();
+var transform = ol.proj.getTransform('EPSG:4326', 'EPSG:3857');
+var geom = parser.read(
+ 'POLYGON((10.689697265625 -25.0927734375, 34.595947265625 ' +
+ '-20.1708984375, 38.814697265625 -35.6396484375, 13.502197265625 ' +
+ '-39.1552734375, 10.689697265625 -25.0927734375))');
+geom.transform(transform);
+var feature = new ol.Feature();
+feature.setGeometry(geom);
+
var vector = new ol.layer.Vector({
source: new ol.source.Vector({
- parser: new ol.parser.WKT(),
- projection: ol.proj.get('EPSG:4326'),
- data: 'POLYGON((10.689697265625 -25.0927734375, 34.595947265625 ' +
- '-20.1708984375, 38.814697265625 -35.6396484375, 13.502197265625 ' +
- '-39.1552734375, 10.689697265625 -25.0927734375))'
+ features: [feature]
})
});
diff --git a/old/src/ol/geom.exports b/old/src/ol/geom.exports
index fded8bcdf9..1af957868f 100644
--- a/old/src/ol/geom.exports
+++ b/old/src/ol/geom.exports
@@ -1,12 +1,12 @@
@exportSymbol ol.geom.GeometryType
@exportProperty ol.geom.GeometryType.POINT
-@exportProperty ol.geom.GeometryType.LINEARRING
-@exportProperty ol.geom.GeometryType.LINESTRING
+@exportProperty ol.geom.GeometryType.LINEAR_RING
+@exportProperty ol.geom.GeometryType.LINE_STRING
@exportProperty ol.geom.GeometryType.POLYGON
-@exportProperty ol.geom.GeometryType.MULTIPOINT
-@exportProperty ol.geom.GeometryType.MULTILINESTRING
-@exportProperty ol.geom.GeometryType.MULTIPOLYGON
-@exportProperty ol.geom.GeometryType.GEOMETRYCOLLECTION
+@exportProperty ol.geom.GeometryType.MULTI_POINT
+@exportProperty ol.geom.GeometryType.MULTI_LINE_STRING
+@exportProperty ol.geom.GeometryType.MULTI_POLYGON
+@exportProperty ol.geom.GeometryType.GEOMETRY_COLLECTION
@exportSymbol ol.geom.Geometry
diff --git a/old/src/ol/interaction/drawinteraction.exports b/old/src/ol/interaction/drawinteraction.exports
index c085ef69e2..890ae0f515 100644
--- a/old/src/ol/interaction/drawinteraction.exports
+++ b/old/src/ol/interaction/drawinteraction.exports
@@ -1 +1 @@
-@exportClass ol.interaction.Draw ol.interaction.DrawOptions
+@exportSymbol ol.interaction.Draw
diff --git a/old/src/ol/interaction/drawinteraction.js b/old/src/ol/interaction/drawinteraction.js
index 8a698818a1..6157a21131 100644
--- a/old/src/ol/interaction/drawinteraction.js
+++ b/old/src/ol/interaction/drawinteraction.js
@@ -23,7 +23,7 @@ goog.require('ol.source.Vector');
/**
* Interaction that allows drawing geometries.
- * @param {ol.interaction.DrawOptions} options Options.
+ * @param {olx.interaction.DrawOptions} options Options.
* @constructor
* @extends {ol.interaction.Interaction}
*/
@@ -337,11 +337,11 @@ ol.interaction.Draw.prototype.finishDrawing_ = function(event) {
sketchFeature.setGeometry(new ol.geom.Polygon(coordinates));
}
// cast multi-part geometries
- if (this.type_ === ol.geom.GeometryType.MULTIPOINT) {
+ if (this.type_ === ol.geom.GeometryType.MULTI_POINT) {
sketchFeature.setGeometry(new ol.geom.MultiPoint([coordinates]));
- } else if (this.type_ === ol.geom.GeometryType.MULTILINESTRING) {
+ } else if (this.type_ === ol.geom.GeometryType.MULTI_LINE_STRING) {
sketchFeature.setGeometry(new ol.geom.MultiLineString([coordinates]));
- } else if (this.type_ === ol.geom.GeometryType.MULTIPOLYGON) {
+ } else if (this.type_ === ol.geom.GeometryType.MULTI_POLYGON) {
sketchFeature.setGeometry(new ol.geom.MultiPolygon([coordinates]));
}
this.layer_.getVectorSource().addFeatures([sketchFeature]);
@@ -379,13 +379,13 @@ ol.interaction.Draw.prototype.abortDrawing_ = function() {
ol.interaction.Draw.getMode_ = function(type) {
var mode;
if (type === ol.geom.GeometryType.POINT ||
- type === ol.geom.GeometryType.MULTIPOINT) {
+ type === ol.geom.GeometryType.MULTI_POINT) {
mode = ol.interaction.DrawMode.POINT;
- } else if (type === ol.geom.GeometryType.LINESTRING ||
- type === ol.geom.GeometryType.MULTILINESTRING) {
+ } else if (type === ol.geom.GeometryType.LINE_STRING ||
+ type === ol.geom.GeometryType.MULTI_LINE_STRING) {
mode = ol.interaction.DrawMode.LINESTRING;
} else if (type === ol.geom.GeometryType.POLYGON ||
- type === ol.geom.GeometryType.MULTIPOLYGON) {
+ type === ol.geom.GeometryType.MULTI_POLYGON) {
mode = ol.interaction.DrawMode.POLYGON;
}
goog.asserts.assert(goog.isDef(mode));
diff --git a/old/src/ol/interaction/modifyinteraction.exports b/old/src/ol/interaction/modifyinteraction.exports
index 2b7b78bce7..60378a3759 100644
--- a/old/src/ol/interaction/modifyinteraction.exports
+++ b/old/src/ol/interaction/modifyinteraction.exports
@@ -1 +1 @@
-@exportClass ol.interaction.Modify ol.interaction.ModifyOptions
+@exportSymbol ol.interaction.Modify
diff --git a/old/src/ol/interaction/modifyinteraction.js b/old/src/ol/interaction/modifyinteraction.js
index fdef1b88e7..94fde65c71 100644
--- a/old/src/ol/interaction/modifyinteraction.js
+++ b/old/src/ol/interaction/modifyinteraction.js
@@ -38,7 +38,7 @@ ol.interaction.SegmentDataType;
/**
* @constructor
* @extends {ol.interaction.Drag}
- * @param {ol.interaction.ModifyOptions=} opt_options Options.
+ * @param {olx.interaction.ModifyOptions=} opt_options Options.
*/
ol.interaction.Modify = function(opt_options) {
goog.base(this);
@@ -243,18 +243,18 @@ ol.interaction.Modify.prototype.addIndex_ = function(features, layer) {
*/
ol.interaction.Modify.prototype.removeIndex_ = function(features) {
var rBush = this.rBush_;
- var i, feature, nodesToRemove;
+ var nodesToRemove = [];
+ var i, feature;
for (i = features.length - 1; i >= 0; --i) {
feature = features[i];
- nodesToRemove = [];
rBush.forEachInExtent(feature.getGeometry().getBounds(), function(node) {
if (feature === node.feature) {
nodesToRemove.push(node);
}
});
- for (i = nodesToRemove.length - 1; i >= 0; --i) {
- rBush.remove(nodesToRemove[i]);
- }
+ }
+ for (i = nodesToRemove.length - 1; i >= 0; --i) {
+ rBush.remove(nodesToRemove[i]);
}
};
diff --git a/old/src/ol/interaction/selectinteraction.exports b/old/src/ol/interaction/selectinteraction.exports
index a5cd323f10..7a428aa5c9 100644
--- a/old/src/ol/interaction/selectinteraction.exports
+++ b/old/src/ol/interaction/selectinteraction.exports
@@ -1 +1 @@
-@exportClass ol.interaction.Select ol.interaction.SelectOptions
+@exportSymbol ol.interaction.Select
diff --git a/old/src/ol/interaction/selectinteraction.js b/old/src/ol/interaction/selectinteraction.js
index 6442cd9d5b..96cec1ad9d 100644
--- a/old/src/ol/interaction/selectinteraction.js
+++ b/old/src/ol/interaction/selectinteraction.js
@@ -15,7 +15,7 @@ goog.require('ol.layer.Vector');
* Allows the user to select features on the map.
* @constructor
* @extends {ol.interaction.Interaction}
- * @param {ol.interaction.SelectOptions=} opt_options Options.
+ * @param {olx.interaction.SelectOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.Select = function(opt_options) {
diff --git a/old/src/ol/parser/geojsonparser.js b/old/src/ol/parser/geojsonparser.js
index d08d45362d..3b10313acf 100644
--- a/old/src/ol/parser/geojsonparser.js
+++ b/old/src/ol/parser/geojsonparser.js
@@ -410,10 +410,10 @@ ol.parser.GeoJSON.prototype.write = function(obj) {
*/
ol.parser.GeoJSON.GeometryType = {
'Point': ol.geom.GeometryType.POINT,
- 'LineString': ol.geom.GeometryType.LINESTRING,
+ 'LineString': ol.geom.GeometryType.LINE_STRING,
'Polygon': ol.geom.GeometryType.POLYGON,
- 'MultiPoint': ol.geom.GeometryType.MULTIPOINT,
- 'MultiLineString': ol.geom.GeometryType.MULTILINESTRING,
- 'MultiPolygon': ol.geom.GeometryType.MULTIPOLYGON,
- 'GeometryCollection': ol.geom.GeometryType.GEOMETRYCOLLECTION
+ 'MultiPoint': ol.geom.GeometryType.MULTI_POINT,
+ 'MultiLineString': ol.geom.GeometryType.MULTI_LINE_STRING,
+ 'MultiPolygon': ol.geom.GeometryType.MULTI_POLYGON,
+ 'GeometryCollection': ol.geom.GeometryType.GEOMETRY_COLLECTION
};
diff --git a/old/src/ol/parser/gpxparser.js b/old/src/ol/parser/gpxparser.js
index bbe29264f3..a193396976 100644
--- a/old/src/ol/parser/gpxparser.js
+++ b/old/src/ol/parser/gpxparser.js
@@ -21,12 +21,12 @@ goog.require('ol.parser.XML');
* @implements {ol.parser.DomFeatureParser}
* @implements {ol.parser.StringFeatureParser}
* @implements {ol.parser.ObjectFeatureParser}
- * @param {ol.parser.GPXOptions=} opt_options Optional configuration object.
+ * @param {olx.parser.GPXOptions=} opt_options Optional configuration object.
* @extends {ol.parser.XML}
* @todo stability experimental
*/
ol.parser.GPX = function(opt_options) {
- var options = /** @type {ol.parser.GPXOptions} */
+ var options = /** @type {olx.parser.GPXOptions} */
(goog.isDef(opt_options) ? opt_options : {});
this.extractAttributes = goog.isDef(options.extractAttributes) ?
options.extractAttributes : true;
@@ -65,7 +65,7 @@ ol.parser.GPX = function(opt_options) {
},
'rte': function(node, obj) {
if (this.extractRoutes || obj.force) {
- var type = ol.geom.GeometryType.LINESTRING;
+ var type = ol.geom.GeometryType.LINE_STRING;
var container = {
properties: {},
geometry: {
@@ -269,7 +269,7 @@ ol.parser.GPX.prototype.readFeaturesFromObject = function(obj) {
/**
- * @param {ol.parser.GPXWriteOptions} obj Object structure to write out
+ * @param {olx.parser.GPXWriteOptions} obj Object structure to write out
* as GPX.
* @return {string} An string representing the GPX document.
*/
diff --git a/old/src/ol/parser/kmlparser.js b/old/src/ol/parser/kmlparser.js
index a815485d7f..c1cdfc9037 100644
--- a/old/src/ol/parser/kmlparser.js
+++ b/old/src/ol/parser/kmlparser.js
@@ -40,12 +40,12 @@ goog.require('ol.style.Stroke');
* @implements {ol.parser.StringFeatureParser}
* @implements {ol.parser.AsyncObjectFeatureParser}
* @implements {ol.parser.AsyncStringFeatureParser}
- * @param {ol.parser.KMLOptions=} opt_options Optional configuration object.
+ * @param {olx.parser.KMLOptions=} opt_options Optional configuration object.
* @extends {ol.parser.XML}
* @todo stability experimental
*/
ol.parser.KML = function(opt_options) {
- var options = /** @type {ol.parser.KMLOptions} */
+ var options = /** @type {olx.parser.KMLOptions} */
(goog.isDef(opt_options) ? opt_options : {});
this.extractAttributes = goog.isDef(options.extractAttributes) ?
options.extractAttributes : true;
@@ -185,19 +185,19 @@ ol.parser.KML = function(opt_options) {
switch (type) {
case ol.geom.GeometryType.POINT:
obj.geometry = {
- type: ol.geom.GeometryType.MULTIPOINT,
+ type: ol.geom.GeometryType.MULTI_POINT,
parts: parts
};
break;
- case ol.geom.GeometryType.LINESTRING:
+ case ol.geom.GeometryType.LINE_STRING:
obj.geometry = {
- type: ol.geom.GeometryType.MULTILINESTRING,
+ type: ol.geom.GeometryType.MULTI_LINE_STRING,
parts: parts
};
break;
case ol.geom.GeometryType.POLYGON:
obj.geometry = {
- type: ol.geom.GeometryType.MULTIPOLYGON,
+ type: ol.geom.GeometryType.MULTI_POLYGON,
parts: parts
};
break;
@@ -207,7 +207,7 @@ ol.parser.KML = function(opt_options) {
} else {
// mixed collection
obj.geometry = {
- type: ol.geom.GeometryType.GEOMETRYCOLLECTION,
+ type: ol.geom.GeometryType.GEOMETRY_COLLECTION,
parts: parts
};
}
@@ -250,7 +250,7 @@ ol.parser.KML = function(opt_options) {
var coordinates = [];
this.readChildNodes(node, coordinates);
var linestring = {
- type: ol.geom.GeometryType.LINESTRING,
+ type: ol.geom.GeometryType.LINE_STRING,
coordinates: coordinates[0]
};
// in the case of a multi geometry this is parts
@@ -730,7 +730,7 @@ ol.parser.KML = function(opt_options) {
this.setAttributeNS(node, null, 'id', obj.id);
}
var literal = obj.symbolizer.createLiteral(
- ol.geom.GeometryType.LINESTRING);
+ ol.geom.GeometryType.LINE_STRING);
this.writeNode('color', {
color: literal.color.substring(1),
opacity: literal.opacity
@@ -1111,34 +1111,34 @@ ol.parser.KML.prototype.createGeometry_ = function(container) {
case ol.geom.GeometryType.POINT:
geometry = new ol.geom.Point(container.geometry.coordinates);
break;
- case ol.geom.GeometryType.LINESTRING:
+ case ol.geom.GeometryType.LINE_STRING:
geometry = new ol.geom.LineString(container.geometry.coordinates);
break;
case ol.geom.GeometryType.POLYGON:
geometry = new ol.geom.Polygon(container.geometry.coordinates);
break;
- case ol.geom.GeometryType.MULTIPOINT:
+ case ol.geom.GeometryType.MULTI_POINT:
coordinates = [];
for (i = 0, ii = container.geometry.parts.length; i < ii; i++) {
coordinates.push(container.geometry.parts[i].coordinates);
}
geometry = new ol.geom.MultiPoint(coordinates);
break;
- case ol.geom.GeometryType.MULTILINESTRING:
+ case ol.geom.GeometryType.MULTI_LINE_STRING:
coordinates = [];
for (i = 0, ii = container.geometry.parts.length; i < ii; i++) {
coordinates.push(container.geometry.parts[i].coordinates);
}
geometry = new ol.geom.MultiLineString(coordinates);
break;
- case ol.geom.GeometryType.MULTIPOLYGON:
+ case ol.geom.GeometryType.MULTI_POLYGON:
coordinates = [];
for (i = 0, ii = container.geometry.parts.length; i < ii; i++) {
coordinates.push(container.geometry.parts[i].coordinates);
}
geometry = new ol.geom.MultiPolygon(coordinates);
break;
- case ol.geom.GeometryType.GEOMETRYCOLLECTION:
+ case ol.geom.GeometryType.GEOMETRY_COLLECTION:
var geometries = [];
for (i = 0, ii = container.geometry.parts.length; i < ii; i++) {
geometries.push(this.createGeometry_({
diff --git a/old/src/ol/parser/ogc/filterparser_v1.js b/old/src/ol/parser/ogc/filterparser_v1.js
index 3d3ff44d55..2c60548f42 100644
--- a/old/src/ol/parser/ogc/filterparser_v1.js
+++ b/old/src/ol/parser/ogc/filterparser_v1.js
@@ -649,6 +649,6 @@ ol.parser.ogc.Filter_v1.prototype.setSrsName = function(srsName) {
this.srsName = srsName;
if (goog.isDefAndNotNull(this.gmlParser_)) {
this.gmlParser_.applyWriteOptions({},
- /** @type {ol.parser.GMLWriteOptions} */ ({srsName: srsName}));
+ /** @type {olx.parser.GMLWriteOptions} */ ({srsName: srsName}));
}
};
diff --git a/old/src/ol/parser/ogc/gmlparser.js b/old/src/ol/parser/ogc/gmlparser.js
index 894bfe17ec..28c36e0f1a 100644
--- a/old/src/ol/parser/ogc/gmlparser.js
+++ b/old/src/ol/parser/ogc/gmlparser.js
@@ -22,12 +22,12 @@ goog.require('ol.proj');
/**
* @constructor
* @implements {ol.parser.StringFeatureParser}
- * @param {ol.parser.GMLOptions=} opt_options
+ * @param {olx.parser.GMLOptions=} opt_options
* Optional configuration object.
* @extends {ol.parser.XML}
*/
ol.parser.ogc.GML = function(opt_options) {
- var options = /** @type {ol.parser.GMLOptions} */
+ var options = /** @type {olx.parser.GMLOptions} */
(goog.isDef(opt_options) ? opt_options : {});
this.extractAttributes = goog.isDef(options.extractAttributes) ?
options.extractAttributes : true;
@@ -102,7 +102,7 @@ ol.parser.ogc.GML = function(opt_options) {
[node, parts, container]);
this.readChildNodes(node, parts);
container.geometry = {
- type: ol.geom.GeometryType.GEOMETRYCOLLECTION,
+ type: ol.geom.GeometryType.GEOMETRY_COLLECTION,
parts: parts
};
},
@@ -115,7 +115,7 @@ ol.parser.ogc.GML = function(opt_options) {
[node, parts, container]);
this.readChildNodes(node, parts);
container.geometry = {
- type: ol.geom.GeometryType.MULTIPOINT,
+ type: ol.geom.GeometryType.MULTI_POINT,
parts: parts
};
},
@@ -128,7 +128,7 @@ ol.parser.ogc.GML = function(opt_options) {
[node, parts, container]);
this.readChildNodes(node, parts);
container.geometry = {
- type: ol.geom.GeometryType.MULTILINESTRING,
+ type: ol.geom.GeometryType.MULTI_LINE_STRING,
parts: parts
};
},
@@ -141,7 +141,7 @@ ol.parser.ogc.GML = function(opt_options) {
[node, parts, container]);
this.readChildNodes(node, parts);
container.geometry = {
- type: ol.geom.GeometryType.MULTIPOLYGON,
+ type: ol.geom.GeometryType.MULTI_POLYGON,
parts: parts
};
},
@@ -173,7 +173,7 @@ ol.parser.ogc.GML = function(opt_options) {
[node, coordinates, container]);
this.readChildNodes(node, coordinates);
var linestring = {
- type: ol.geom.GeometryType.LINESTRING,
+ type: ol.geom.GeometryType.LINE_STRING,
coordinates: coordinates[0]
};
// in the case of a multi geometry this is parts
@@ -209,7 +209,7 @@ ol.parser.ogc.GML = function(opt_options) {
container.push(coordinates);
} else {
container.geometry = {
- type: ol.geom.GeometryType.LINEARRING,
+ type: ol.geom.GeometryType.LINEAR_RING,
coordinates: coordinates[0]
};
}
@@ -444,20 +444,20 @@ ol.parser.ogc.GML = function(opt_options) {
var type = geometry.getType(), child;
if (type === ol.geom.GeometryType.POINT) {
child = this.writeNode('Point', geometry, null, node);
- } else if (type === ol.geom.GeometryType.MULTIPOINT) {
+ } else if (type === ol.geom.GeometryType.MULTI_POINT) {
child = this.writeNode('MultiPoint', geometry, null, node);
- } else if (type === ol.geom.GeometryType.LINEARRING) {
+ } else if (type === ol.geom.GeometryType.LINEAR_RING) {
child = this.writeNode('LinearRing', geometry.getCoordinates(), null,
node);
- } else if (type === ol.geom.GeometryType.LINESTRING) {
+ } else if (type === ol.geom.GeometryType.LINE_STRING) {
child = this.writeNode('LineString', geometry, null, node);
- } else if (type === ol.geom.GeometryType.MULTILINESTRING) {
+ } else if (type === ol.geom.GeometryType.MULTI_LINE_STRING) {
child = this.writeNode('MultiLineString', geometry, null, node);
} else if (type === ol.geom.GeometryType.POLYGON) {
child = this.writeNode('Polygon', geometry, null, node);
- } else if (type === ol.geom.GeometryType.MULTIPOLYGON) {
+ } else if (type === ol.geom.GeometryType.MULTI_POLYGON) {
child = this.writeNode('MultiPolygon', geometry, null, node);
- } else if (type === ol.geom.GeometryType.GEOMETRYCOLLECTION) {
+ } else if (type === ol.geom.GeometryType.GEOMETRY_COLLECTION) {
child = this.writeNode('GeometryCollection', geometry, null, node);
}
if (goog.isDefAndNotNull(this.srsName)) {
@@ -491,7 +491,7 @@ ol.parser.ogc.GML.prototype.writeGeometry = function(geometry) {
/**
* @param {string|Document|Element|Object} data Data to read.
- * @param {ol.parser.GMLReadOptions=} opt_options Read options.
+ * @param {olx.parser.GMLReadOptions=} opt_options Read options.
* @return {ol.parser.ReadFeaturesResult} An object representing the document.
*/
ol.parser.ogc.GML.prototype.read = function(data, opt_options) {
@@ -570,37 +570,37 @@ ol.parser.ogc.GML.prototype.createGeometry = function(container) {
case ol.geom.GeometryType.POINT:
geometry = new ol.geom.Point(container.geometry.coordinates);
break;
- case ol.geom.GeometryType.LINEARRING:
+ case ol.geom.GeometryType.LINEAR_RING:
geometry = new ol.geom.LinearRing(container.geometry.coordinates);
break;
- case ol.geom.GeometryType.LINESTRING:
+ case ol.geom.GeometryType.LINE_STRING:
geometry = new ol.geom.LineString(container.geometry.coordinates);
break;
case ol.geom.GeometryType.POLYGON:
geometry = new ol.geom.Polygon(container.geometry.coordinates);
break;
- case ol.geom.GeometryType.MULTIPOINT:
+ case ol.geom.GeometryType.MULTI_POINT:
coordinates = [];
for (i = 0, ii = container.geometry.parts.length; i < ii; i++) {
coordinates.push(container.geometry.parts[i].coordinates);
}
geometry = new ol.geom.MultiPoint(coordinates);
break;
- case ol.geom.GeometryType.MULTILINESTRING:
+ case ol.geom.GeometryType.MULTI_LINE_STRING:
coordinates = [];
for (i = 0, ii = container.geometry.parts.length; i < ii; i++) {
coordinates.push(container.geometry.parts[i].coordinates);
}
geometry = new ol.geom.MultiLineString(coordinates);
break;
- case ol.geom.GeometryType.MULTIPOLYGON:
+ case ol.geom.GeometryType.MULTI_POLYGON:
coordinates = [];
for (i = 0, ii = container.geometry.parts.length; i < ii; i++) {
coordinates.push(container.geometry.parts[i].coordinates);
}
geometry = new ol.geom.MultiPolygon(coordinates);
break;
- case ol.geom.GeometryType.GEOMETRYCOLLECTION:
+ case ol.geom.GeometryType.GEOMETRY_COLLECTION:
var geometries = [];
for (i = 0, ii = container.geometry.parts.length; i < ii; i++) {
geometries.push(this.createGeometry({
@@ -630,7 +630,7 @@ ol.parser.ogc.GML.prototype.readFeaturesFromString = function(str) {
* Applies the writeOptions passed into the write function.
* @param {ol.parser.ReadFeaturesResult} obj Object structure to write out as
* GML.
- * @param {ol.parser.GMLWriteOptions=} opt_options Write options.
+ * @param {olx.parser.GMLWriteOptions=} opt_options Write options.
*/
ol.parser.ogc.GML.prototype.applyWriteOptions = function(obj, opt_options) {
// srsName handling: opt_options -> this.writeOptions -> obj.metadata
diff --git a/old/src/ol/parser/ogc/gmlparser_v2.js b/old/src/ol/parser/ogc/gmlparser_v2.js
index 37bdd9d191..a6aaa73c52 100644
--- a/old/src/ol/parser/ogc/gmlparser_v2.js
+++ b/old/src/ol/parser/ogc/gmlparser_v2.js
@@ -11,7 +11,7 @@ goog.require('ol.parser.ogc.GML');
* version 2.1.2
*
* @constructor
- * @param {ol.parser.GMLOptions=} opt_options Optional configuration object.
+ * @param {olx.parser.GMLOptions=} opt_options Optional configuration object.
* @extends {ol.parser.ogc.GML}
* @todo stability experimental
*/
@@ -127,7 +127,7 @@ goog.inherits(ol.parser.ogc.GML_v2, ol.parser.ogc.GML);
/**
* @param {ol.parser.ReadFeaturesResult} obj Object structure to write out as
* GML.
- * @param {ol.parser.GMLWriteOptions=} opt_options Write options.
+ * @param {olx.parser.GMLWriteOptions=} opt_options Write options.
* @return {string} A string representing the GML document.
* @todo stability experimental
*/
diff --git a/old/src/ol/parser/ogc/gmlparser_v3.js b/old/src/ol/parser/ogc/gmlparser_v3.js
index 7c30f85713..b22f755e3e 100644
--- a/old/src/ol/parser/ogc/gmlparser_v3.js
+++ b/old/src/ol/parser/ogc/gmlparser_v3.js
@@ -13,7 +13,7 @@ goog.require('ol.parser.ogc.GML');
* version 3.1.1
*
* @constructor
- * @param {ol.parser.GMLOptions=} opt_options Optional configuration object.
+ * @param {olx.parser.GMLOptions=} opt_options Optional configuration object.
* @extends {ol.parser.ogc.GML}
* @todo stability experimental
*/
@@ -29,18 +29,18 @@ ol.parser.ogc.GML_v3 = function(opt_options) {
var type = geometry.getType(), child;
if (type === ol.geom.GeometryType.POINT) {
child = this.writeNode('Point', geometry, null, node);
- } else if (type === ol.geom.GeometryType.MULTIPOINT) {
+ } else if (type === ol.geom.GeometryType.MULTI_POINT) {
child = this.writeNode('MultiPoint', geometry, null, node);
- } else if (type === ol.geom.GeometryType.LINESTRING) {
+ } else if (type === ol.geom.GeometryType.LINE_STRING) {
if (this.curve === true) {
child = this.writeNode('Curve', geometry, null, node);
} else {
child = this.writeNode('LineString', geometry, null, node);
}
- } else if (type === ol.geom.GeometryType.LINEARRING) {
+ } else if (type === ol.geom.GeometryType.LINEAR_RING) {
child = this.writeNode('LinearRing', geometry.getCoordinates(), null,
node);
- } else if (type === ol.geom.GeometryType.MULTILINESTRING) {
+ } else if (type === ol.geom.GeometryType.MULTI_LINE_STRING) {
if (this.multiCurve === false) {
child = this.writeNode('MultiLineString', geometry, null, node);
} else {
@@ -52,13 +52,13 @@ ol.parser.ogc.GML_v3 = function(opt_options) {
} else {
child = this.writeNode('Polygon', geometry, null, node);
}
- } else if (type === ol.geom.GeometryType.MULTIPOLYGON) {
+ } else if (type === ol.geom.GeometryType.MULTI_POLYGON) {
if (this.multiSurface === false) {
child = this.writeNode('MultiPolygon', geometry, null, node);
} else {
child = this.writeNode('MultiSurface', geometry, null, node);
}
- } else if (type === ol.geom.GeometryType.GEOMETRYCOLLECTION) {
+ } else if (type === ol.geom.GeometryType.GEOMETRY_COLLECTION) {
child = this.writeNode('MultiGeometry', geometry, null, node);
}
if (goog.isDefAndNotNull(this.srsName)) {
@@ -86,7 +86,7 @@ ol.parser.ogc.GML_v3 = function(opt_options) {
[node, coordinates, container]);
this.readChildNodes(node, coordinates);
var linestring = {
- type: ol.geom.GeometryType.LINESTRING,
+ type: ol.geom.GeometryType.LINE_STRING,
coordinates: coordinates[0]
};
// in the case of a multi geometry this is parts
@@ -176,7 +176,7 @@ ol.parser.ogc.GML_v3 = function(opt_options) {
[node, parts, container]);
this.readChildNodes(node, parts);
container.geometry = {
- type: ol.geom.GeometryType.MULTILINESTRING,
+ type: ol.geom.GeometryType.MULTI_LINE_STRING,
parts: parts
};
},
@@ -189,7 +189,7 @@ ol.parser.ogc.GML_v3 = function(opt_options) {
[node, parts, container]);
this.readChildNodes(node, parts);
container.geometry = {
- type: ol.geom.GeometryType.MULTIPOLYGON,
+ type: ol.geom.GeometryType.MULTI_POLYGON,
parts: parts
};
},
@@ -425,7 +425,7 @@ goog.inherits(ol.parser.ogc.GML_v3, ol.parser.ogc.GML);
/**
* @param {ol.parser.ReadFeaturesResult} obj Object structure to write out as
* XML.
- * @param {ol.parser.GMLWriteOptions=} opt_options Write options.
+ * @param {olx.parser.GMLWriteOptions=} opt_options Write options.
* @return {string} An string representing the XML document.
* @todo stability experimental
*/
diff --git a/old/src/ol/parser/ogc/sldparser_v1.js b/old/src/ol/parser/ogc/sldparser_v1.js
index a1516d8c5a..f952d4878f 100644
--- a/old/src/ol/parser/ogc/sldparser_v1.js
+++ b/old/src/ol/parser/ogc/sldparser_v1.js
@@ -89,7 +89,7 @@ ol.parser.ogc.SLD_v1 = function() {
delete config.fill;
config.zIndex = this.featureTypeCounter;
rule.symbolizers.push(
- new ol.style.Text(/** @type {ol.style.TextOptions} */(config))
+ new ol.style.Text(/** @type {olx.style.TextOptions} */(config))
);
},
'Label': function(node, symbolizer) {
@@ -197,7 +197,7 @@ ol.parser.ogc.SLD_v1 = function() {
if (goog.isDef(config.externalGraphic)) {
config.width = config.height = config.size;
symbolizer = new ol.style.Icon(
- /** @type {ol.style.IconOptions} */(config));
+ /** @type {olx.style.IconOptions} */(config));
} else {
symbolizer = new ol.style.Shape(config);
}
@@ -689,7 +689,7 @@ ol.parser.ogc.SLD_v1.prototype.getScaleDenominatorFromResolution_ =
/**
* @param {string|Document|Element} data Data to read.
- * @param {ol.parser.SLDReadOptions=} opt_options Read options.
+ * @param {olx.parser.SLDReadOptions=} opt_options Read options.
* @return {Object} An object representing the document.
*/
ol.parser.ogc.SLD_v1.prototype.read = function(data, opt_options) {
@@ -713,7 +713,7 @@ ol.parser.ogc.SLD_v1.prototype.read = function(data, opt_options) {
/**
* @param {Object} style The style to write out.
- * @param {ol.parser.SLDWriteOptions=} opt_options Write options.
+ * @param {olx.parser.SLDWriteOptions=} opt_options Write options.
* @return {string} The serialized SLD.
*/
ol.parser.ogc.SLD_v1.prototype.write = function(style, opt_options) {
diff --git a/old/src/ol/parser/ogc/wfsparser_v1.js b/old/src/ol/parser/ogc/wfsparser_v1.js
index acc0449c8b..0bd8e4ac8b 100644
--- a/old/src/ol/parser/ogc/wfsparser_v1.js
+++ b/old/src/ol/parser/ogc/wfsparser_v1.js
@@ -28,9 +28,9 @@ ol.parser.ogc.WFS_v1 = function(opt_options) {
this.writers = {};
this.writers[this.defaultNamespaceURI] = {
/**
- * @param {ol.parser.WFSWriteGetFeatureOptions} options Options.
+ * @param {olx.parser.WFSWriteGetFeatureOptions} options Options.
* @return {{node: Node,
- * options: ol.parser.WFSWriteGetFeatureOptions}} Object.
+ * options: olx.parser.WFSWriteGetFeatureOptions}} Object.
* @this {ol.parser.XML}
*/
'GetFeature': function(options) {
@@ -64,7 +64,7 @@ ol.parser.ogc.WFS_v1 = function(opt_options) {
* @param {{inserts: Array.,
* updates: Array.,
* deletes: Array.,
- * options: ol.parser.WFSWriteTransactionOptions}} obj Object.
+ * options: olx.parser.WFSWriteTransactionOptions}} obj Object.
* @return {Element} Node.
* @this {ol.parser.XML}
*/
@@ -120,7 +120,7 @@ ol.parser.ogc.WFS_v1 = function(opt_options) {
},
/**
* @param {{feature: ol.Feature,
- * options: ol.parser.WFSWriteTransactionOptions}} obj Object.
+ * options: olx.parser.WFSWriteTransactionOptions}} obj Object.
* @return {Element} Node.
* @this {ol.parser.XML}
*/
@@ -140,7 +140,7 @@ ol.parser.ogc.WFS_v1 = function(opt_options) {
},
/**
* @param {{feature: ol.Feature,
- * options: ol.parser.WFSWriteTransactionOptions}} obj Object.
+ * options: olx.parser.WFSWriteTransactionOptions}} obj Object.
* @return {Element} Node.
* @this {ol.parser.XML}
*/
@@ -213,7 +213,7 @@ ol.parser.ogc.WFS_v1 = function(opt_options) {
},
/**
* @param {{feature: ol.Feature,
- * options: ol.parser.WFSWriteTransactionOptions}} obj Object.
+ * options: olx.parser.WFSWriteTransactionOptions}} obj Object.
* @return {Element} Node.
* @this {ol.parser.XML}
*/
@@ -338,7 +338,7 @@ ol.parser.ogc.WFS_v1.prototype.read = function(data) {
/**
- * @param {ol.parser.WFSWriteGetFeatureOptions} options Options.
+ * @param {olx.parser.WFSWriteGetFeatureOptions} options Options.
* @return {string} A serialized WFS GetFeature query.
*/
ol.parser.ogc.WFS_v1.prototype.writeGetFeature = function(options) {
@@ -352,7 +352,7 @@ ol.parser.ogc.WFS_v1.prototype.writeGetFeature = function(options) {
* @param {Array.} inserts The features to insert.
* @param {Array.} updates The features to update.
* @param {Array.} deletes The features to delete.
- * @param {ol.parser.WFSWriteTransactionOptions} options Write options.
+ * @param {olx.parser.WFSWriteTransactionOptions} options Write options.
* @return {string} A serialized WFS transaction.
*/
ol.parser.ogc.WFS_v1.prototype.writeTransaction =
diff --git a/old/src/ol/style.exports b/old/src/ol/style.exports
index f46aad4738..87526beedb 100644
--- a/old/src/ol/style.exports
+++ b/old/src/ol/style.exports
@@ -1,9 +1,9 @@
-@exportClass ol.style.Fill ol.style.FillOptions
-@exportClass ol.style.Icon ol.style.IconOptions
-@exportClass ol.style.Rule ol.style.RuleOptions
-@exportClass ol.style.Shape ol.style.ShapeOptions
-@exportClass ol.style.Stroke ol.style.StrokeOptions
-@exportClass ol.style.Style ol.style.StyleOptions
-@exportClass ol.style.Text ol.style.TextOptions
+@exportSymbol ol.style.Fill
+@exportSymbol ol.style.Icon
+@exportSymbol ol.style.Rule
+@exportSymbol ol.style.Shape
+@exportSymbol ol.style.Stroke
+@exportSymbol ol.style.Style
+@exportSymbol ol.style.Text
@exportSymbol ol.style.ShapeType
@exportProperty ol.style.ShapeType.CIRCLE
diff --git a/old/src/ol/style/fillsymbolizer.js b/old/src/ol/style/fillsymbolizer.js
index 7ca87aee96..fca7d3ce9d 100644
--- a/old/src/ol/style/fillsymbolizer.js
+++ b/old/src/ol/style/fillsymbolizer.js
@@ -14,7 +14,7 @@ goog.require('ol.style.Symbolizer');
/**
* @constructor
* @extends {ol.style.Symbolizer}
- * @param {ol.style.FillOptions=} opt_options Polygon options.
+ * @param {olx.style.FillOptions=} opt_options Polygon options.
* @todo stability experimental
*/
ol.style.Fill = function(opt_options) {
@@ -68,7 +68,7 @@ ol.style.Fill.prototype.createLiteral = function(featureOrType) {
var literal = null;
if (type === ol.geom.GeometryType.POLYGON ||
- type === ol.geom.GeometryType.MULTIPOLYGON) {
+ type === ol.geom.GeometryType.MULTI_POLYGON) {
var color = ol.expr.evaluateFeature(this.color_, feature);
goog.asserts.assertString(
diff --git a/old/src/ol/style/iconsymbolizer.js b/old/src/ol/style/iconsymbolizer.js
index 911ea3a968..12e3ab69d7 100644
--- a/old/src/ol/style/iconsymbolizer.js
+++ b/old/src/ol/style/iconsymbolizer.js
@@ -14,7 +14,7 @@ goog.require('ol.style.Point');
/**
* @constructor
* @extends {ol.style.Point}
- * @param {ol.style.IconOptions} options Icon options.
+ * @param {olx.style.IconOptions} options Icon options.
* @todo stability experimental
*/
ol.style.Icon = function(options) {
@@ -112,7 +112,7 @@ ol.style.Icon.prototype.createLiteral = function(featureOrType) {
var literal = null;
if (type === ol.geom.GeometryType.POINT ||
- type === ol.geom.GeometryType.MULTIPOINT) {
+ type === ol.geom.GeometryType.MULTI_POINT) {
var url = ol.expr.evaluateFeature(this.url_, feature);
goog.asserts.assertString(url, 'url must be a string');
diff --git a/old/src/ol/style/rule.js b/old/src/ol/style/rule.js
index d8234de95b..5fa062f285 100644
--- a/old/src/ol/style/rule.js
+++ b/old/src/ol/style/rule.js
@@ -11,7 +11,7 @@ goog.require('ol.style.Symbolizer');
/**
* @constructor
- * @param {ol.style.RuleOptions} options Rule options.
+ * @param {olx.style.RuleOptions} options Rule options.
* @todo stability experimental
*/
ol.style.Rule = function(options) {
diff --git a/old/src/ol/style/shapesymbolizer.js b/old/src/ol/style/shapesymbolizer.js
index 137580b034..ed2845d81a 100644
--- a/old/src/ol/style/shapesymbolizer.js
+++ b/old/src/ol/style/shapesymbolizer.js
@@ -17,7 +17,7 @@ goog.require('ol.style.Stroke');
/**
* @constructor
* @extends {ol.style.Point}
- * @param {ol.style.ShapeOptions} options Shape options.
+ * @param {olx.style.ShapeOptions} options Shape options.
* @todo stability experimental
*/
ol.style.Shape = function(options) {
@@ -84,7 +84,7 @@ ol.style.Shape.prototype.createLiteral = function(featureOrType) {
var literal = null;
if (type === ol.geom.GeometryType.POINT ||
- type === ol.geom.GeometryType.MULTIPOINT) {
+ type === ol.geom.GeometryType.MULTI_POINT) {
var size = Number(ol.expr.evaluateFeature(this.size_, feature));
goog.asserts.assert(!isNaN(size), 'size must be a number');
diff --git a/old/src/ol/style/strokesymbolizer.js b/old/src/ol/style/strokesymbolizer.js
index ab268948ef..9f4e41c6ca 100644
--- a/old/src/ol/style/strokesymbolizer.js
+++ b/old/src/ol/style/strokesymbolizer.js
@@ -16,7 +16,7 @@ goog.require('ol.style.Symbolizer');
/**
* @constructor
* @extends {ol.style.Symbolizer}
- * @param {ol.style.StrokeOptions=} opt_options Stroke options.
+ * @param {olx.style.StrokeOptions=} opt_options Stroke options.
* @todo stability experimental
*/
ol.style.Stroke = function(opt_options) {
@@ -93,8 +93,8 @@ ol.style.Stroke.prototype.createLiteral = function(featureOrType) {
goog.asserts.assert(!isNaN(zIndex), 'zIndex must be a number');
var literal = null;
- if (type === ol.geom.GeometryType.LINESTRING ||
- type === ol.geom.GeometryType.MULTILINESTRING) {
+ if (type === ol.geom.GeometryType.LINE_STRING ||
+ type === ol.geom.GeometryType.MULTI_LINE_STRING) {
literal = new ol.style.LineLiteral({
color: color,
opacity: opacity,
@@ -102,7 +102,7 @@ ol.style.Stroke.prototype.createLiteral = function(featureOrType) {
zIndex: zIndex
});
} else if (type === ol.geom.GeometryType.POLYGON ||
- type === ol.geom.GeometryType.MULTIPOLYGON) {
+ type === ol.geom.GeometryType.MULTI_POLYGON) {
literal = new ol.style.PolygonLiteral({
strokeColor: color,
strokeOpacity: opacity,
diff --git a/old/src/ol/style/textsymbolizer.js b/old/src/ol/style/textsymbolizer.js
index 7b2e8e92cd..d2dc3a679d 100644
--- a/old/src/ol/style/textsymbolizer.js
+++ b/old/src/ol/style/textsymbolizer.js
@@ -13,7 +13,7 @@ goog.require('ol.style.TextLiteral');
/**
* @constructor
* @extends {ol.style.Symbolizer}
- * @param {ol.style.TextOptions} options Text options.
+ * @param {olx.style.TextOptions} options Text options.
*/
ol.style.Text = function(options) {
diff --git a/old/test/spec/ol/expr/expression.test.js b/old/test/spec/ol/expr/expression.test.js
index 35dfa37144..23fa9ec16e 100644
--- a/old/test/spec/ol/expr/expression.test.js
+++ b/old/test/spec/ol/expr/expression.test.js
@@ -792,10 +792,10 @@ describe('ol.expr.lib', function() {
]])
});
- var isPoint = parse('geometryType("point")');
- var isLine = parse('geometryType("linestring")');
- var isPoly = parse('geometryType("polygon")');
- var pointOrPoly = parse('geometryType("point") || geometryType("polygon")');
+ var isPoint = parse('geometryType("Point")');
+ var isLine = parse('geometryType("LineString")');
+ var isPoly = parse('geometryType("Polygon")');
+ var pointOrPoly = parse('geometryType("Point") || geometryType("Polygon")');
it('distinguishes point features', function() {
expect(evaluate(isPoint, point)).to.be(true);
diff --git a/old/test/spec/ol/interaction/drawinteraction.test.js b/old/test/spec/ol/interaction/drawinteraction.test.js
index 9f9867a7b2..8da33d6f95 100644
--- a/old/test/spec/ol/interaction/drawinteraction.test.js
+++ b/old/test/spec/ol/interaction/drawinteraction.test.js
@@ -104,7 +104,7 @@ describe('ol.interaction.Draw', function() {
beforeEach(function() {
map.addInteraction(new ol.interaction.Draw({
layer: layer,
- type: ol.geom.GeometryType.MULTIPOINT
+ type: ol.geom.GeometryType.MULTI_POINT
}));
});
@@ -127,7 +127,7 @@ describe('ol.interaction.Draw', function() {
beforeEach(function() {
map.addInteraction(new ol.interaction.Draw({
layer: layer,
- type: ol.geom.GeometryType.LINESTRING
+ type: ol.geom.GeometryType.LINE_STRING
}));
});
@@ -196,7 +196,7 @@ describe('ol.interaction.Draw', function() {
beforeEach(function() {
map.addInteraction(new ol.interaction.Draw({
layer: layer,
- type: ol.geom.GeometryType.MULTILINESTRING
+ type: ol.geom.GeometryType.MULTI_LINE_STRING
}));
});
@@ -279,7 +279,7 @@ describe('ol.interaction.Draw', function() {
beforeEach(function() {
map.addInteraction(new ol.interaction.Draw({
layer: layer,
- type: ol.geom.GeometryType.MULTIPOLYGON
+ type: ol.geom.GeometryType.MULTI_POLYGON
}));
});
diff --git a/old/test/spec/ol/parser/gpx.test.js b/old/test/spec/ol/parser/gpx.test.js
index 9692184e95..7d0f4d0bfc 100644
--- a/old/test/spec/ol/parser/gpx.test.js
+++ b/old/test/spec/ol/parser/gpx.test.js
@@ -19,7 +19,7 @@ describe('ol.parser.gpx', function() {
feature = obj.features[1];
geom = feature.getGeometry();
var attributes = feature.getAttributes();
- expect(geom.getType()).to.eql(ol.geom.GeometryType.LINESTRING);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.LINE_STRING);
expect(geom.getCoordinates()).to.eql([[-0.1829991904, 51.3761803674],
[-0.1758887005, 51.3697894659], [-0.1833202965, 51.3639790884],
[-0.1751119509, 51.3567607069]]);
@@ -29,7 +29,7 @@ describe('ol.parser.gpx', function() {
feature = obj.features[2];
geom = feature.getGeometry();
attributes = feature.getAttributes();
- expect(geom.getType()).to.eql(ol.geom.GeometryType.LINESTRING);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.LINE_STRING);
expect(geom.getCoordinates()).to.eql([[-0.1721292044, 51.3768216433],
[-0.1649230916, 51.370833767], [-0.1736741378, 51.3644368725],
[-0.166259525, 51.3576354272]]);
diff --git a/old/test/spec/ol/parser/kml.test.js b/old/test/spec/ol/parser/kml.test.js
index 4a165f055b..fcd7f0994d 100644
--- a/old/test/spec/ol/parser/kml.test.js
+++ b/old/test/spec/ol/parser/kml.test.js
@@ -198,7 +198,7 @@ describe('ol.parser.KML', function() {
var stroke = symbolizers[0];
expect(stroke).to.be.a(ol.style.Stroke);
- var literal = stroke.createLiteral(ol.geom.GeometryType.LINESTRING);
+ var literal = stroke.createLiteral(ol.geom.GeometryType.LINE_STRING);
expect(literal).to.be.a(ol.style.LineLiteral);
expect(literal.color).to.eql('#ff0000');
expect(literal.opacity).to.eql(0.5294117647058824);
diff --git a/old/test/spec/ol/parser/ogc/gml_v2.test.js b/old/test/spec/ol/parser/ogc/gml_v2.test.js
index f102f50cdb..780f2f0cf8 100644
--- a/old/test/spec/ol/parser/ogc/gml_v2.test.js
+++ b/old/test/spec/ol/parser/ogc/gml_v2.test.js
@@ -9,7 +9,7 @@ describe('ol.parser.gml_v2', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v2/point-coord.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('point');
+ expect(obj.geometry.type).to.eql('Point');
expect(obj.geometry.coordinates).to.eql([1, 2]);
done();
});
@@ -25,7 +25,7 @@ describe('ol.parser.gml_v2', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('point');
+ expect(obj.geometry.type).to.eql('Point');
expect(obj.geometry.coordinates).to.eql([1, 2]);
done();
});
@@ -34,9 +34,9 @@ describe('ol.parser.gml_v2', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v2/multipoint-coord.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('multipoint');
+ expect(obj.geometry.type).to.eql('MultiPoint');
expect(obj.geometry.parts.length).to.eql(3);
- expect(obj.geometry.parts[0].type).to.eql('point');
+ expect(obj.geometry.parts[0].type).to.eql('Point');
expect(obj.geometry.parts[0].coordinates).to.eql([1, 2]);
expect(obj.geometry.parts[1].coordinates).to.eql([2, 3]);
expect(obj.geometry.parts[2].coordinates).to.eql([3, 4]);
@@ -54,9 +54,9 @@ describe('ol.parser.gml_v2', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multipoint');
+ expect(obj.geometry.type).to.eql('MultiPoint');
expect(obj.geometry.parts.length).to.eql(3);
- expect(obj.geometry.parts[0].type).to.eql('point');
+ expect(obj.geometry.parts[0].type).to.eql('Point');
expect(obj.geometry.parts[0].coordinates).to.eql([1, 2]);
expect(obj.geometry.parts[1].coordinates).to.eql([2, 3]);
expect(obj.geometry.parts[2].coordinates).to.eql([3, 4]);
@@ -67,7 +67,7 @@ describe('ol.parser.gml_v2', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v2/linestring-coord.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('linestring');
+ expect(obj.geometry.type).to.eql('LineString');
expect(obj.geometry.coordinates.length).to.eql(2);
expect(obj.geometry.coordinates).to.eql([[1, 2], [3, 4]]);
done();
@@ -84,7 +84,7 @@ describe('ol.parser.gml_v2', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('linestring');
+ expect(obj.geometry.type).to.eql('LineString');
expect(obj.geometry.coordinates.length).to.eql(2);
expect(obj.geometry.coordinates).to.eql([[1, 2], [3, 4]]);
done();
@@ -94,9 +94,9 @@ describe('ol.parser.gml_v2', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v2/multilinestring-coord.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('multilinestring');
+ expect(obj.geometry.type).to.eql('MultiLineString');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('linestring');
+ expect(obj.geometry.parts[0].type).to.eql('LineString');
expect(obj.geometry.parts[0].coordinates).to.eql([[1, 2], [2, 3]]);
expect(obj.geometry.parts[1].coordinates).to.eql([[3, 4], [4, 5]]);
done();
@@ -113,9 +113,9 @@ describe('ol.parser.gml_v2', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multilinestring');
+ expect(obj.geometry.type).to.eql('MultiLineString');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('linestring');
+ expect(obj.geometry.parts[0].type).to.eql('LineString');
expect(obj.geometry.parts[0].coordinates).to.eql([[1, 2], [2, 3]]);
expect(obj.geometry.parts[1].coordinates).to.eql([[3, 4], [4, 5]]);
done();
@@ -125,7 +125,7 @@ describe('ol.parser.gml_v2', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v2/polygon-coord.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('polygon');
+ expect(obj.geometry.type).to.eql('Polygon');
expect(obj.geometry.coordinates.length).to.eql(3);
expect(obj.geometry.coordinates[0].length).to.eql(4);
expect(obj.geometry.coordinates[0]).to.eql([[1, 2], [3, 4],
@@ -148,7 +148,7 @@ describe('ol.parser.gml_v2', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('polygon');
+ expect(obj.geometry.type).to.eql('Polygon');
done();
});
});
@@ -156,9 +156,9 @@ describe('ol.parser.gml_v2', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v2/multipolygon-coord.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('multipolygon');
+ expect(obj.geometry.type).to.eql('MultiPolygon');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('polygon');
+ expect(obj.geometry.parts[0].type).to.eql('Polygon');
done();
});
});
@@ -173,9 +173,9 @@ describe('ol.parser.gml_v2', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multipolygon');
+ expect(obj.geometry.type).to.eql('MultiPolygon');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('polygon');
+ expect(obj.geometry.parts[0].type).to.eql('Polygon');
done();
});
});
@@ -192,11 +192,11 @@ describe('ol.parser.gml_v2', function() {
delete p.srsName;
delete p.axisOrientation;
expect(goog.dom.xml.loadXml(p.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('geometrycollection');
+ expect(obj.geometry.type).to.eql('GeometryCollection');
expect(obj.geometry.parts.length).to.eql(3);
- expect(obj.geometry.parts[0].type).to.eql('point');
- expect(obj.geometry.parts[1].type).to.eql('linestring');
- expect(obj.geometry.parts[2].type).to.eql('polygon');
+ expect(obj.geometry.parts[0].type).to.eql('Point');
+ expect(obj.geometry.parts[1].type).to.eql('LineString');
+ expect(obj.geometry.parts[2].type).to.eql('Polygon');
done();
});
});
@@ -220,7 +220,7 @@ describe('ol.parser.gml_v2', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v2/linearring-coord.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('linearring');
+ expect(obj.geometry.type).to.eql('LinearRing');
expect(obj.geometry.coordinates).to.eql([[1, 2], [3, 4], [5, 6],
[1, 2]]);
done();
@@ -237,7 +237,7 @@ describe('ol.parser.gml_v2', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('linearring');
+ expect(obj.geometry.type).to.eql('LinearRing');
expect(obj.geometry.coordinates).to.eql([[1, 2], [3, 4], [5, 6],
[1, 2]]);
done();
diff --git a/old/test/spec/ol/parser/ogc/gml_v3.test.js b/old/test/spec/ol/parser/ogc/gml_v3.test.js
index 88da336d8e..246a9da52b 100644
--- a/old/test/spec/ol/parser/ogc/gml_v3.test.js
+++ b/old/test/spec/ol/parser/ogc/gml_v3.test.js
@@ -24,7 +24,7 @@ describe('ol.parser.gml_v3', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('linearring');
+ expect(obj.geometry.type).to.eql('LinearRing');
expect(obj.geometry.coordinates).to.eql([[1, 2], [3, 4], [5, 6],
[1, 2]]);
done();
@@ -41,7 +41,7 @@ describe('ol.parser.gml_v3', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('linestring');
+ expect(obj.geometry.type).to.eql('LineString');
expect(obj.geometry.coordinates).to.eql([[1, 2], [3, 4]]);
done();
});
@@ -51,7 +51,7 @@ describe('ol.parser.gml_v3', function() {
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
// no write test since simple features only does 2D
- expect(obj.geometry.type).to.eql('linestring');
+ expect(obj.geometry.type).to.eql('LineString');
expect(obj.geometry.coordinates).to.eql([[1, 2, 3], [4, 5, 6]]);
done();
});
@@ -68,7 +68,7 @@ describe('ol.parser.gml_v3', function() {
delete p.srsName;
delete p.axisOrientation;
expect(goog.dom.xml.loadXml(p.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('linestring');
+ expect(obj.geometry.type).to.eql('LineString');
expect(obj.geometry.coordinates).to.eql([[1, 2], [3, 4]]);
done();
});
@@ -78,9 +78,9 @@ describe('ol.parser.gml_v3', function() {
afterLoadXml(url, function(xml) {
// no write test for plural, we only write singular
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('multilinestring');
+ expect(obj.geometry.type).to.eql('MultiLineString');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('linestring');
+ expect(obj.geometry.parts[0].type).to.eql('LineString');
done();
});
});
@@ -96,9 +96,9 @@ describe('ol.parser.gml_v3', function() {
delete p.srsName;
delete p.axisOrientation;
expect(goog.dom.xml.loadXml(p.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multilinestring');
+ expect(obj.geometry.type).to.eql('MultiLineString');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('linestring');
+ expect(obj.geometry.parts[0].type).to.eql('LineString');
done();
});
});
@@ -113,9 +113,9 @@ describe('ol.parser.gml_v3', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multilinestring');
+ expect(obj.geometry.type).to.eql('MultiLineString');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('linestring');
+ expect(obj.geometry.parts[0].type).to.eql('LineString');
expect(obj.geometry.parts[0].coordinates).to.eql([[1, 2], [2, 3]]);
done();
});
@@ -132,9 +132,9 @@ describe('ol.parser.gml_v3', function() {
delete p.srsName;
delete p.axisOrientation;
expect(goog.dom.xml.loadXml(p.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multilinestring');
+ expect(obj.geometry.type).to.eql('MultiLineString');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('linestring');
+ expect(obj.geometry.parts[0].type).to.eql('LineString');
expect(obj.geometry.parts[0].coordinates).to.eql([[1, 2], [2, 3]]);
done();
});
@@ -143,9 +143,9 @@ describe('ol.parser.gml_v3', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v3/multipoint-plural.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('multipoint');
+ expect(obj.geometry.type).to.eql('MultiPoint');
expect(obj.geometry.parts.length).to.eql(3);
- expect(obj.geometry.parts[0].type).to.eql('point');
+ expect(obj.geometry.parts[0].type).to.eql('Point');
expect(obj.geometry.parts[0].coordinates).to.eql([1, 2]);
done();
});
@@ -161,9 +161,9 @@ describe('ol.parser.gml_v3', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multipoint');
+ expect(obj.geometry.type).to.eql('MultiPoint');
expect(obj.geometry.parts.length).to.eql(3);
- expect(obj.geometry.parts[0].type).to.eql('point');
+ expect(obj.geometry.parts[0].type).to.eql('Point');
expect(obj.geometry.parts[0].coordinates).to.eql([1, 2]);
done();
});
@@ -172,9 +172,9 @@ describe('ol.parser.gml_v3', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v3/multipolygon-plural.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('multipolygon');
+ expect(obj.geometry.type).to.eql('MultiPolygon');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('polygon');
+ expect(obj.geometry.parts[0].type).to.eql('Polygon');
done();
});
});
@@ -190,9 +190,9 @@ describe('ol.parser.gml_v3', function() {
delete p.srsName;
delete p.axisOrientation;
expect(goog.dom.xml.loadXml(p.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multipolygon');
+ expect(obj.geometry.type).to.eql('MultiPolygon');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('polygon');
+ expect(obj.geometry.parts[0].type).to.eql('Polygon');
done();
});
});
@@ -200,9 +200,9 @@ describe('ol.parser.gml_v3', function() {
var url = 'spec/ol/parser/ogc/xml/gml_v3/multisurface-plural.xml';
afterLoadXml(url, function(xml) {
var obj = parser.read(xml);
- expect(obj.geometry.type).to.eql('multipolygon');
+ expect(obj.geometry.type).to.eql('MultiPolygon');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('polygon');
+ expect(obj.geometry.parts[0].type).to.eql('Polygon');
done();
});
});
@@ -217,9 +217,9 @@ describe('ol.parser.gml_v3', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multipolygon');
+ expect(obj.geometry.type).to.eql('MultiPolygon');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('polygon');
+ expect(obj.geometry.parts[0].type).to.eql('Polygon');
done();
});
});
@@ -235,9 +235,9 @@ describe('ol.parser.gml_v3', function() {
delete p.srsName;
delete p.axisOrientation;
expect(goog.dom.xml.loadXml(p.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('multipolygon');
+ expect(obj.geometry.type).to.eql('MultiPolygon');
expect(obj.geometry.parts.length).to.eql(2);
- expect(obj.geometry.parts[0].type).to.eql('polygon');
+ expect(obj.geometry.parts[0].type).to.eql('Polygon');
done();
});
});
@@ -252,7 +252,7 @@ describe('ol.parser.gml_v3', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('point');
+ expect(obj.geometry.type).to.eql('Point');
expect(obj.geometry.coordinates).to.eql([1, 2]);
done();
});
@@ -268,7 +268,7 @@ describe('ol.parser.gml_v3', function() {
delete parser.srsName;
delete parser.axisOrientation;
expect(goog.dom.xml.loadXml(parser.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('polygon');
+ expect(obj.geometry.type).to.eql('Polygon');
done();
});
});
@@ -284,7 +284,7 @@ describe('ol.parser.gml_v3', function() {
delete p.srsName;
delete p.axisOrientation;
expect(goog.dom.xml.loadXml(p.serialize(node))).to.xmleql(xml);
- expect(obj.geometry.type).to.eql('polygon');
+ expect(obj.geometry.type).to.eql('Polygon');
done();
});
});
diff --git a/old/test/spec/ol/parser/wkt.test.js b/old/test/spec/ol/parser/wkt.test.js
index 059154c285..b2e1d06aac 100644
--- a/old/test/spec/ol/parser/wkt.test.js
+++ b/old/test/spec/ol/parser/wkt.test.js
@@ -40,13 +40,13 @@ describe('ol.parser.WKT', function() {
it('LineString read / written correctly', function() {
var wkt = 'LINESTRING(30 10,10 30,40 40)';
var geom = parser.read(wkt);
- expect(geom.getType()).to.eql(ol.geom.GeometryType.LINESTRING);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.LINE_STRING);
expect(geom.getCoordinates()).to.eql([[30, 10], [10, 30], [40, 40]]);
expect(parser.write(geom)).to.eql(wkt);
// test whitespace when reading
wkt = 'LINESTRING (30 10, 10 30, 40 40)';
geom = parser.read(wkt);
- expect(geom.getType()).to.eql(ol.geom.GeometryType.LINESTRING);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.LINE_STRING);
expect(geom.getCoordinates()).to.eql([[30, 10], [10, 30], [40, 40]]);
});
@@ -54,10 +54,10 @@ describe('ol.parser.WKT', function() {
var wkt = 'MULTILINESTRING((10 10,20 20,10 40),' +
'(40 40,30 30,40 20,30 10))';
var geom = parser.read(wkt);
- expect(geom.getType()).to.eql(ol.geom.GeometryType.MULTILINESTRING);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.MULTI_LINE_STRING);
var components = geom.getComponents();
expect(components.length).to.eql(2);
- expect(components[0].getType()).to.eql(ol.geom.GeometryType.LINESTRING);
+ expect(components[0].getType()).to.eql(ol.geom.GeometryType.LINE_STRING);
expect(components[0].getCoordinates()).to.eql(
[[10, 10], [20, 20], [10, 40]]);
expect(parser.write(geom)).to.eql(wkt);
@@ -65,11 +65,11 @@ describe('ol.parser.WKT', function() {
wkt = 'MULTILINESTRING ( (10 10, 20 20, 10 40), ' +
'(40 40, 30 30, 40 20, 30 10) )';
geom = parser.read(wkt);
- expect(geom.getType()).to.eql(ol.geom.GeometryType.MULTILINESTRING);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.MULTI_LINE_STRING);
components = geom.getComponents();
expect(components.length).to.eql(2);
expect(components[0].getType()).to.eql(
- ol.geom.GeometryType.LINESTRING);
+ ol.geom.GeometryType.LINE_STRING);
expect(components[0].getCoordinates()).to.eql(
[[10, 10], [20, 20], [10, 40]]);
});
@@ -80,7 +80,7 @@ describe('ol.parser.WKT', function() {
expect(geom.getType()).to.eql(ol.geom.GeometryType.POLYGON);
var rings = geom.getRings();
expect(rings.length).to.eql(1);
- expect(rings[0].getType()).to.eql(ol.geom.GeometryType.LINEARRING);
+ expect(rings[0].getType()).to.eql(ol.geom.GeometryType.LINEAR_RING);
expect(rings[0].getCoordinates()).to.eql(
[[30, 10], [10, 20], [20, 40], [40, 40], [30, 10]]);
expect(parser.write(geom)).to.eql(wkt);
@@ -91,8 +91,8 @@ describe('ol.parser.WKT', function() {
expect(geom.getType()).to.eql(ol.geom.GeometryType.POLYGON);
var rings = geom.getRings();
expect(rings.length).to.eql(2);
- expect(rings[0].getType()).to.eql(ol.geom.GeometryType.LINEARRING);
- expect(rings[1].getType()).to.eql(ol.geom.GeometryType.LINEARRING);
+ expect(rings[0].getType()).to.eql(ol.geom.GeometryType.LINEAR_RING);
+ expect(rings[1].getType()).to.eql(ol.geom.GeometryType.LINEAR_RING);
expect(rings[0].getCoordinates()).to.eql(
[[35, 10], [10, 20], [15, 40], [45, 45], [35, 10]]);
expect(rings[1].getCoordinates()).to.eql(
@@ -105,7 +105,7 @@ describe('ol.parser.WKT', function() {
expect(geom.getType()).to.eql(ol.geom.GeometryType.POLYGON);
var rings = geom.getRings();
expect(rings.length).to.eql(1);
- expect(rings[0].getType()).to.eql(ol.geom.GeometryType.LINEARRING);
+ expect(rings[0].getType()).to.eql(ol.geom.GeometryType.LINEAR_RING);
expect(rings[0].getCoordinates()).to.eql(
[[30, 10], [10, 20], [20, 40], [40, 40], [30, 10]]);
});
@@ -115,7 +115,7 @@ describe('ol.parser.WKT', function() {
var wkt = 'MULTIPOLYGON(((40 40,45 30,20 45,40 40)),' +
'((20 35,45 20,30 5,10 10,10 30,20 35),(30 20,20 25,20 15,30 20)))';
var geom = parser.read(wkt);
- expect(geom.getType()).to.eql(ol.geom.GeometryType.MULTIPOLYGON);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.MULTI_POLYGON);
var components = geom.getComponents();
expect(components.length).to.eql(2);
expect(components[0].getType()).to.eql(ol.geom.GeometryType.POLYGON);
@@ -135,7 +135,7 @@ describe('ol.parser.WKT', function() {
'( (20 35, 45 20,30 5,10 10,10 30,20 35), ' +
'( 30 20, 20 25,20 15 ,30 20 ) ))';
geom = parser.read(wkt);
- expect(geom.getType()).to.eql(ol.geom.GeometryType.MULTIPOLYGON);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.MULTI_POLYGON);
var components = geom.getComponents();
expect(components.length).to.eql(2);
expect(components[0].getType()).to.eql(ol.geom.GeometryType.POLYGON);
@@ -155,9 +155,9 @@ describe('ol.parser.WKT', function() {
var geom = parser.read(wkt);
var components = geom.getComponents();
expect(components.length).to.eql(2);
- expect(geom.getType()).to.eql(ol.geom.GeometryType.GEOMETRYCOLLECTION);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.GEOMETRY_COLLECTION);
expect(components[0].getType()).to.eql(ol.geom.GeometryType.POINT);
- expect(components[1].getType()).to.eql(ol.geom.GeometryType.LINESTRING);
+ expect(components[1].getType()).to.eql(ol.geom.GeometryType.LINE_STRING);
expect(components[0].getCoordinates()).to.eql([4, 6]);
expect(components[1].getCoordinates()).to.eql([[4, 6], [7, 10]]);
expect(parser.write(geom)).to.eql(wkt);
@@ -166,10 +166,10 @@ describe('ol.parser.WKT', function() {
geom = parser.read(wkt);
components = geom.getComponents();
expect(components.length).to.eql(2);
- expect(geom.getType()).to.eql(ol.geom.GeometryType.GEOMETRYCOLLECTION);
+ expect(geom.getType()).to.eql(ol.geom.GeometryType.GEOMETRY_COLLECTION);
expect(components[0].getType()).to.eql(ol.geom.GeometryType.POINT);
expect(components[1].getType()).to.eql(
- ol.geom.GeometryType.LINESTRING);
+ ol.geom.GeometryType.LINE_STRING);
expect(components[0].getCoordinates()).to.eql([4, 6]);
expect(components[1].getCoordinates()).to.eql([[4, 6], [7, 10]]);
});
diff --git a/old/test/spec/ol/style/strokesymbolizer.test.js b/old/test/spec/ol/style/strokesymbolizer.test.js
index bd4890fe8c..2436076e28 100644
--- a/old/test/spec/ol/style/strokesymbolizer.test.js
+++ b/old/test/spec/ol/style/strokesymbolizer.test.js
@@ -55,7 +55,7 @@ describe('ol.style.Stroke', function() {
it('applies the default values', function() {
var symbolizer = new ol.style.Stroke({});
- var literal = symbolizer.createLiteral(ol.geom.GeometryType.LINESTRING);
+ var literal = symbolizer.createLiteral(ol.geom.GeometryType.LINE_STRING);
expect(literal).to.be.a(ol.style.LineLiteral);
expect(literal.color).to.be('#696969');
expect(literal.opacity).to.be(0.75);
diff --git a/src/objectliterals.jsdoc b/src/objectliterals.jsdoc
index 5b01f40a5e..8831009077 100644
--- a/src/objectliterals.jsdoc
+++ b/src/objectliterals.jsdoc
@@ -1,5 +1,5 @@
/**
- * @typedef {Object} ol.AttributionOptions
+ * @typedef {Object} olx.AttributionOptions
* @property {string} html HTML markup for this attribution.
* @property {Object.>|undefined} tileRanges
* Tile ranges (FOR INTERNAL USE ONLY).
@@ -7,13 +7,13 @@
*/
/**
- * @typedef {Object} ol.DeviceOrientationOptions
+ * @typedef {Object} olx.DeviceOrientationOptions
* @property {boolean|undefined} tracking Start tracking. Default is `false`.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.GeolocationOptions
+ * @typedef {Object} olx.GeolocationOptions
* @property {boolean|undefined} tracking Start Tracking. Default is `false`.
* @property {GeolocationPositionOptions|undefined} trackingOptions Tracking options.
* @property {ol.proj.ProjectionLike} projection Projection.
@@ -22,7 +22,7 @@
/**
* Object literal with config options for the map.
- * @typedef {Object} ol.MapOptions
+ * @typedef {Object} olx.MapOptions
* @property {ol.Collection|Array.|undefined} controls
* Controls initially added to the map.
* @property {ol.Collection|Array.|undefined} interactions
@@ -40,7 +40,7 @@
/**
* Object literal with config options for the overlay.
- * @typedef {Object} ol.OverlayOptions
+ * @typedef {Object} olx.OverlayOptions
* @property {Element|undefined} element The overlay element.
* @property {ol.Coordinate|undefined} position The overlay position in map
* projection.
@@ -59,7 +59,7 @@
/**
* Object literal with config options for the Proj4js projection.
- * @typedef {Object} ol.Proj4jsProjectionOptions
+ * @typedef {Object} olx.Proj4jsProjectionOptions
* @property {string} code The SRS identifier code, e.g. `EPSG:31256`.
* @property {ol.Extent|undefined} extent The validity extent for the SRS.
* @property {boolean|undefined} global Whether the projection is valid for the
@@ -69,7 +69,7 @@
/**
* Object literal with config options for the projection.
- * @typedef {Object} ol.ProjectionOptions
+ * @typedef {Object} olx.ProjectionOptions
* @property {string} code The SRS identifier code, e.g. `EPSG:4326`.
* @property {ol.proj.Units} units Units.
* @property {ol.Extent|undefined} extent The validity extent for the SRS.
@@ -82,7 +82,7 @@
/**
* Object literal with config options for the view.
- * @typedef {Object} ol.View2DOptions
+ * @typedef {Object} olx.View2DOptions
* @property {ol.Coordinate|undefined} center The initial center for the view.
* The coordinate system for the center is specified with the `projection`
* option. Default is `undefined`, and layer sources will not be fetched if
@@ -122,7 +122,7 @@
*/
/**
- * @typedef {Object} ol.animation.BounceOptions
+ * @typedef {Object} olx.animation.BounceOptions
* @property {number} resolution The resolution to start the bounce from, typically `map.getView().getResolution()`.
* @property {number|undefined} start The start time of the animation. Default is immediately.
* @property {number|undefined} duration The duration of the animation in milliseconds. Default is `1000`.
@@ -131,7 +131,7 @@
*/
/**
- * @typedef {Object} ol.animation.PanOptions
+ * @typedef {Object} olx.animation.PanOptions
* @property {ol.Coordinate} source The location to start panning from, typically `map.getView().getCenter()`.
* @property {number|undefined} start The start time of the animation. Default is immediately.
* @property {number|undefined} duration The duration of the animation in milliseconds. Default is `1000`.
@@ -140,7 +140,7 @@
*/
/**
- * @typedef {Object} ol.animation.RotateOptions
+ * @typedef {Object} olx.animation.RotateOptions
* @property {number} rotation The rotation to apply, in radians.
* @property {number|undefined} start The start time of the animation. Default is immediately.
* @property {number|undefined} duration The duration of the animation in milliseconds. Default is `1000`.
@@ -149,7 +149,7 @@
*/
/**
- * @typedef {Object} ol.animation.ZoomOptions
+ * @typedef {Object} olx.animation.ZoomOptions
* @property {number} resolution number The resolution to begin zooming from, typically `map.getView().getResolution()`.
* @property {number|undefined} start The start time of the animation. Default is immediately.
* @property {number|undefined} duration The duration of the animation in milliseconds. Default is `1000`.
@@ -158,33 +158,33 @@
*/
/**
- * @typedef {Object} ol.control.AttributionOptions
+ * @typedef {Object} olx.control.AttributionOptions
* @property {string|undefined} className CSS class name. Default is `ol-attribution`.
* @property {Element|undefined} target Target.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.control.ControlOptions
+ * @typedef {Object} olx.control.ControlOptions
* @property {Element|undefined} element Element.
* @property {Element|undefined} target Target.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.control.DefaultsOptions
+ * @typedef {Object} olx.control.DefaultsOptions
* @property {boolean|undefined} attribution Attribution.
- * @property {ol.control.AttributionOptions|undefined} attributionOptions
+ * @property {olx.control.AttributionOptions|undefined} attributionOptions
* Attribution options.
* @property {boolean|undefined} logo Logo.
- * @property {ol.control.LogoOptions|undefined} logoOptions Logo options.
+ * @property {olx.control.LogoOptions|undefined} logoOptions Logo options.
* @property {boolean|undefined} zoom Zoom.
- * @property {ol.control.ZoomOptions|undefined} zoomOptions Zoom options.
+ * @property {olx.control.ZoomOptions|undefined} zoomOptions Zoom options.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.control.FullScreenOptions
+ * @typedef {Object} olx.control.FullScreenOptions
* @property {string|undefined} className CSS class name. Default is `ol-full-screen`.
* @property {boolean|undefined} keys Full keyboard access.
* @property {Element|undefined} target Target.
@@ -192,14 +192,14 @@
*/
/**
- * @typedef {Object} ol.control.LogoOptions
+ * @typedef {Object} olx.control.LogoOptions
* @property {string|undefined} className CSS class name. Default is `ol-logo`.
* @property {Element|undefined} target Target.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.control.MousePositionOptions
+ * @typedef {Object} olx.control.MousePositionOptions
* @property {string|undefined} className CSS class name. Default is `ol-mouse-position`.
* @property {ol.CoordinateFormatType|undefined} coordinateFormat Coordinate
* format.
@@ -211,7 +211,7 @@
*/
/**
- * @typedef {Object} ol.control.ScaleLineOptions
+ * @typedef {Object} olx.control.ScaleLineOptions
* @property {string|undefined} className CSS Class name. Default is `ol-scale-line`.
* @property {number|undefined} minWidth Minimum width in pixels.
* @property {Element|undefined} target Target.
@@ -220,7 +220,7 @@
*/
/**
- * @typedef {Object} ol.control.ZoomOptions
+ * @typedef {Object} olx.control.ZoomOptions
* @property {number|undefined} duration Animation duration in milliseconds. Default is `250`.
* @property {string|undefined} className CSS class name. Default is `ol-zoom`.
* @property {number|undefined} delta The zoom delta applied on each click.
@@ -229,7 +229,7 @@
*/
/**
- * @typedef {Object} ol.control.ZoomSliderOptions
+ * @typedef {Object} olx.control.ZoomSliderOptions
* @property {string|undefined} className CSS class name.
* @property {number|undefined} maxResolution Maximum resolution.
* @property {number|undefined} minResolution Minimum resolution.
@@ -237,7 +237,7 @@
*/
/**
- * @typedef {Object} ol.control.ZoomToExtentOptions
+ * @typedef {Object} olx.control.ZoomToExtentOptions
* @property {string|undefined} className Class name. Default is `ol-zoom-extent`.
* @property {Element|undefined} target Target.
* @property {ol.Extent|undefined} extent The extent to zoom to. If
@@ -246,12 +246,12 @@
*/
/**
- * @typedef {Object} ol.format.GeoJSONOptions
+ * @typedef {Object} olx.format.GeoJSONOptions
* @property {ol.proj.ProjectionLike} defaultProjection Default projection.
*/
/**
- * @typedef {Object} ol.interaction.DoubleClickZoomOptions
+ * @typedef {Object} olx.interaction.DoubleClickZoomOptions
* @property {number|undefined} duration Animation duration in milliseconds. Default is `250`.
* @property {number|undefined} delta The zoom delta applied on each double
* click, default is `1`.
@@ -259,7 +259,7 @@
*/
/**
- * @typedef {Object} ol.interaction.DragPanOptions
+ * @typedef {Object} olx.interaction.DragPanOptions
* @property {ol.Kinetic|undefined} kinetic Kinetic inertia to apply to the pan.
* @property {ol.events.ConditionType|undefined} condition A conditional
* modifier (i.e. Shift key) that determines if the interaction is active
@@ -268,7 +268,7 @@
*/
/**
- * @typedef {Object} ol.interaction.DragRotateOptions
+ * @typedef {Object} olx.interaction.DragRotateOptions
* @property {ol.events.ConditionType|undefined} condition A conditional
* modifier (i.e. Shift key) that determines if the interaction is active
* or not, default is both shift and alt keys.
@@ -276,7 +276,7 @@
*/
/**
- * @typedef {Object} ol.interaction.DragRotateAndZoomOptions
+ * @typedef {Object} olx.interaction.DragRotateAndZoomOptions
* @property {ol.events.ConditionType|undefined} condition A conditional
* modifier (i.e. Shift key) that determines if the interaction is active
* or not, default is shify key.
@@ -284,7 +284,7 @@
*/
/**
- * @typedef {Object} ol.interaction.DragZoomOptions
+ * @typedef {Object} olx.interaction.DragZoomOptions
* @property {ol.events.ConditionType|undefined} condition A conditional
* modifier (i.e. Shift key) that determines if the interaction is active
* or not, default is shift key.
@@ -293,7 +293,7 @@
/**
* Interactions for the map. Default is `true` for all options.
- * @typedef {Object} ol.interaction.DefaultsOptions
+ * @typedef {Object} olx.interaction.DefaultsOptions
* @property {boolean|undefined} altShiftDragRotate Whether Alt-Shift-drag
* rotate is desired.
* @property {boolean|undefined} doubleClickZoom Whether double click zoom is
@@ -315,7 +315,7 @@
*/
/**
- * @typedef {Object} ol.interaction.KeyboardPanOptions
+ * @typedef {Object} olx.interaction.KeyboardPanOptions
* @property {ol.events.ConditionType|undefined} condition A conditional
* modifier (i.e. Shift key) that determines if the interaction is active
* or not, default is no modifiers.
@@ -325,7 +325,7 @@
*/
/**
- * @typedef {Object} ol.interaction.KeyboardZoomOptions
+ * @typedef {Object} olx.interaction.KeyboardZoomOptions
* @property {number|undefined} duration Animation duration in milliseconds. Default is `100`.
* @property {ol.events.ConditionType|undefined} condition A conditional
* modifier (i.e. Shift key) that determines if the interaction is active
@@ -335,33 +335,33 @@
*/
/**
- * @typedef {Object} ol.interaction.MouseWheelZoomOptions
+ * @typedef {Object} olx.interaction.MouseWheelZoomOptions
* @property {number|undefined} duration Animation duration in milliseconds. Default is `250`.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.interaction.TouchPanOptions
+ * @typedef {Object} olx.interaction.TouchPanOptions
* @property {ol.Kinetic|undefined} kinetic Kinetic inertia to apply to the
* pan.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.interaction.TouchRotateOptions
+ * @typedef {Object} olx.interaction.TouchRotateOptions
* @property {number|undefined} threshold Minimal angle in radians to start a rotation.
* Default is `0.3`.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.interaction.TouchZoomOptions
+ * @typedef {Object} olx.interaction.TouchZoomOptions
* @property {number|undefined} duration Animation duration in milliseconds. Default is `400`.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.layer.BaseOptions
+ * @typedef {Object} olx.layer.BaseOptions
* @property {number|undefined} brightness Brightness. Default is `0`.
* @property {number|undefined} contrast Contrast. Default is `1`.
* @property {number|undefined} hue Hue. Default is `0`.
@@ -376,7 +376,7 @@
*/
/**
- * @typedef {Object} ol.layer.LayerOptions
+ * @typedef {Object} olx.layer.LayerOptions
* @property {number|undefined} brightness Brightness. Default is `0`.
* @property {number|undefined} contrast Contrast. Default is `1`.
* @property {number|undefined} hue Hue. Default is `0`.
@@ -392,7 +392,7 @@
*/
/**
- * @typedef {Object} ol.layer.GroupOptions
+ * @typedef {Object} olx.layer.GroupOptions
* @property {number|undefined} brightness Brightness. Default is `0`.
* @property {number|undefined} contrast Contrast. Default is `1`.
* @property {number|undefined} hue Hue. Default is `0`.
@@ -408,7 +408,7 @@
*/
/**
- * @typedef {Object} ol.layer.TileOptions
+ * @typedef {Object} olx.layer.TileOptions
* @property {number|undefined} brightness Brightness. Default is `0`.
* @property {number|undefined} contrast Contrast. Default is `1`.
* @property {number|undefined} hue Hue. Default is `0`.
@@ -425,7 +425,7 @@
*/
/**
- * @typedef {Object} ol.layer.VectorOptions
+ * @typedef {Object} olx.layer.VectorOptions
* @property {number|undefined} brightness Brightness.
* @property {number|undefined} contrast Contrast.
* @property {number|undefined} hue Hue.
@@ -438,10 +438,11 @@
* @property {ol.source.Vector} source Source.
* @property {ol.style.StyleFunction|undefined} styleFunction Style function.
* @property {boolean|undefined} visible Visibility. Default is `true` (visible).
+ * @todo stability experimental
*/
/**
- * @typedef {Object} ol.parser.WFSWriteGetFeatureOptions
+ * @typedef {Object} olx.parser.WFSWriteGetFeatureOptions
* @property {string} featureNS The namespace URI used for features.
* @property {string} featurePrefix The prefix for the feature namespace.
* @property {Array.} featureTypes The feature type names.
@@ -454,7 +455,7 @@
*/
/**
- * @typedef {Object} ol.parser.WFSWriteTransactionOptions
+ * @typedef {Object} olx.parser.WFSWriteTransactionOptions
* @property {string} featureNS The namespace URI used for features.
* @property {string} featurePrefix The prefix for the feature namespace.
* @property {string} featureType The feature type name.
@@ -466,7 +467,7 @@
*/
/**
- * @typedef {Object} ol.source.BingMapsOptions
+ * @typedef {Object} olx.source.BingMapsOptions
* @property {string|undefined} culture Culture code. Default is `en-us`.
* @property {string} key Bing Maps API key. Get yours at
* http://bingmapsportal.com/.
@@ -477,7 +478,7 @@
*/
/**
- * @typedef {Object} ol.source.GeoJSONOptions
+ * @typedef {Object} olx.source.GeoJSONOptions
* @property {Array.|undefined} attributions Attributions.
* @property {ol.proj.ProjectionLike} defaultProjection Default projection.
* @property {ol.Extent|undefined} extent Extent.
@@ -490,7 +491,7 @@
*/
/**
- * @typedef {Object} ol.source.MapGuideOptions
+ * @typedef {Object} olx.source.MapGuideOptions
* @property {string|undefined} url The mapagent url.
* @property {number|undefined} metersPerUnit The meters-per-unit value.
* @property {ol.Extent|undefined} extent Extent..
@@ -506,14 +507,14 @@
*/
/**
- * @typedef {Object} ol.source.MapQuestOptions
+ * @typedef {Object} olx.source.MapQuestOptions
* @property {ol.TileLoadFunctionType|undefined} tileLoadFunction Optional
* function to load a tile given a URL.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.source.TileDebugOptions
+ * @typedef {Object} olx.source.TileDebugOptions
* @property {ol.Extent|undefined} extent Extent.
* @property {ol.proj.ProjectionLike} projection Projection.
* @property {ol.tilegrid.TileGrid|undefined} tileGrid Tile grid.
@@ -521,7 +522,7 @@
*/
/**
- * @typedef {Object} ol.source.OSMOptions
+ * @typedef {Object} olx.source.OSMOptions
* @property {Array.|undefined} attributions Attributions.
* @property {number|undefined} maxZoom Max zoom.
* @property {ol.TileLoadFunctionType|undefined} tileLoadFunction Optional
@@ -533,7 +534,7 @@
*/
/**
- * @typedef {Object} ol.source.ImageWMSOptions
+ * @typedef {Object} olx.source.ImageWMSOptions
* @property {Array.|undefined} attributions Attributions.
* @property {null|string|undefined} crossOrigin crossOrigin setting for image
* requests.
@@ -553,7 +554,7 @@
*/
/**
- * @typedef {Object} ol.source.StamenOptions
+ * @typedef {Object} olx.source.StamenOptions
* @property {string} layer Layer.
* @property {number|undefined} minZoom Minimum zoom.
* @property {number|undefined} maxZoom Maximum zoom.
@@ -566,7 +567,7 @@
*/
/**
- * @typedef {Object} ol.source.ImageStaticOptions
+ * @typedef {Object} olx.source.ImageStaticOptions
* @property {Array.|undefined} attributions Attributions.
* @property {null|string|undefined} crossOrigin crossOrigin setting for image
* requests.
@@ -579,7 +580,7 @@
*/
/**
- * @typedef {Object} ol.source.TileJSONOptions
+ * @typedef {Object} olx.source.TileJSONOptions
* @property {null|string|undefined} crossOrigin crossOrigin setting for image
* requests.
* @property {ol.TileLoadFunctionType|undefined} tileLoadFunction Optional
@@ -589,7 +590,7 @@
*/
/**
- * @typedef {Object} ol.source.TileWMSOptions
+ * @typedef {Object} olx.source.TileWMSOptions
* @property {Array.|undefined} attributions Attributions.
* @property {Object.} params WMS request parameters. At least a
* `LAYERS` param is required. `STYLES` is `` by default. `VERSION` is
@@ -598,6 +599,15 @@
* @property {null|string|undefined} crossOrigin crossOrigin setting for image
* requests.
* @property {ol.Extent|undefined} extent Extent.
+ * @property {number|undefined} gutter The size in pixels of the
+ * gutter around image tiles to ignore. By setting this property to a
+ * non-zero value, images will be requested that are wider and taller than
+ * the tile size by a value of `2 x gutter`. Defaults to zero. Using a
+ * non-zero value allows artifacts of rendering at tile edges to be ignored. If
+ * you control the WMS service it is recommended to address "artifacts at tile
+ * edges" issues by properly configuring the WMS service. For example, MapServer
+ * has a `tile_map_edge_buffer` configuration parameter for this. See
+ * http://mapserver.org/output/tile_mode.html.
* @property {string|undefined} logo Logo.
* @property {ol.tilegrid.TileGrid|undefined} tileGrid Tile grid.
* @property {number|undefined} maxZoom Maximum zoom.
@@ -611,7 +621,7 @@
*/
/**
- * @typedef {Object} ol.source.VectorOptions
+ * @typedef {Object} olx.source.VectorOptions
* @property {Array.|undefined} attributions Attributions.
* @property {ol.Extent|undefined} extent Extent.
* @property {Array.|undefined} features Features.
@@ -621,7 +631,7 @@
*/
/**
- * @typedef {Object} ol.source.VectorFileOptions
+ * @typedef {Object} olx.source.VectorFileOptions
* @property {Array.|undefined} attributions Attributions.
* @property {Document|undefined} doc Document.
* @property {ol.Extent|undefined} extent Extent.
@@ -635,7 +645,7 @@
*/
/**
- * @typedef {Object} ol.source.WMTSOptions
+ * @typedef {Object} olx.source.WMTSOptions
* @property {Array.|undefined} attributions Attributions.
* @property {string|null|undefined} crossOrigin crossOrigin setting for image
* requests.
@@ -660,7 +670,7 @@
*/
/**
- * @typedef {Object} ol.source.XYZOptions
+ * @typedef {Object} olx.source.XYZOptions
* @property {Array.|undefined} attributions Attributions.
* @property {null|string|undefined} crossOrigin Cross origin setting for image
* requests.
@@ -681,13 +691,13 @@
*/
/**
- * @typedef {Object} ol.style.FillOptions
+ * @typedef {Object} olx.style.FillOptions
* @property {ol.Color|string|undefined} color Color.
* @todo stability experimental
*/
/**
- * @typedef {Object} ol.style.ImageOptions
+ * @typedef {Object} olx.style.ImageOptions
* @property {ol.Pixel} anchor Anchor.
* @property {null|string|undefined} crossOrigin crossOrigin setting for image.
* @property {HTMLCanvasElement|HTMLVideoElement|Image|undefined} image Image.
@@ -702,7 +712,7 @@
*/
/**
- * @typedef {Object} ol.style.StrokeOptions
+ * @typedef {Object} olx.style.StrokeOptions
* @property {ol.Color|string|undefined} color Color.
* @property {string|undefined} lineCap Line cap style: `butt`, `round`, or `square`. Default is `butt`.
* @property {string|undefined} lineJoin Line join style: `bevel`, `round`, or `miter`. Default is `miter`.
@@ -713,7 +723,7 @@
*/
/**
- * @typedef {Object} ol.style.TextOptions
+ * @typedef {Object} olx.style.TextOptions
* @property {string|undefined} font Font.
* @property {number|undefined} rotation Rotation.
* @property {string|undefined} text Text.
@@ -725,7 +735,7 @@
*/
/**
- * @typedef {Object} ol.style.StyleOptions
+ * @typedef {Object} olx.style.StyleOptions
* @property {ol.style.Fill|undefined} fill Fill style.
* @property {ol.style.Image|undefined} image Image style.
* @property {ol.style.Stroke|undefined} stroke Stroke style.
@@ -735,7 +745,7 @@
*/
/**
- * @typedef {Object} ol.tilegrid.TileGridOptions
+ * @typedef {Object} olx.tilegrid.TileGridOptions
* @property {number|undefined} minZoom Minimum zoom.
* @property {ol.Coordinate|undefined} origin Origin.
* @property {Array.|undefined} origins Origins.
@@ -746,7 +756,7 @@
*/
/**
- * @typedef {Object} ol.tilegrid.WMTSOptions
+ * @typedef {Object} olx.tilegrid.WMTSOptions
* @property {ol.Coordinate|undefined} origin Origin.
* @property {Array.|undefined} origins Origins.
* @property {!Array.} resolutions Resolutions.
@@ -757,7 +767,7 @@
*/
/**
- * @typedef {Object} ol.tilegrid.XYZOptions
+ * @typedef {Object} olx.tilegrid.XYZOptions
* @property {number} maxZoom Maximum zoom.
* @todo stability experimental
*/
diff --git a/src/ol/animation.exports b/src/ol/animation.exports
index 887adf82d7..f887f38c28 100644
--- a/src/ol/animation.exports
+++ b/src/ol/animation.exports
@@ -1,4 +1,4 @@
-@exportFunction ol.animation.bounce ol.animation.BounceOptions ol.PreRenderFunction
-@exportFunction ol.animation.pan ol.animation.PanOptions ol.PreRenderFunction
-@exportFunction ol.animation.rotate ol.animation.RotateOptions ol.PreRenderFunction
-@exportFunction ol.animation.zoom ol.animation.ZoomOptions ol.PreRenderFunction
+@exportSymbol ol.animation.bounce ol.animation.bounce
+@exportSymbol ol.animation.pan ol.animation.pan
+@exportSymbol ol.animation.rotate ol.animation.rotate
+@exportSymbol ol.animation.zoom ol.animation.zoom
diff --git a/src/ol/animation.js b/src/ol/animation.js
index b1a15fa966..17207baea0 100644
--- a/src/ol/animation.js
+++ b/src/ol/animation.js
@@ -8,7 +8,7 @@ goog.require('ol.easing');
/**
- * @param {ol.animation.BounceOptions} options Bounce options.
+ * @param {olx.animation.BounceOptions} options Bounce options.
* @return {ol.PreRenderFunction} Pre-render function.
* @todo stability experimental
*/
@@ -43,7 +43,7 @@ ol.animation.bounce = function(options) {
/**
- * @param {ol.animation.PanOptions} options Pan options.
+ * @param {olx.animation.PanOptions} options Pan options.
* @return {ol.PreRenderFunction} Pre-render function.
* @todo stability experimental
*/
@@ -82,7 +82,7 @@ ol.animation.pan = function(options) {
/**
- * @param {ol.animation.RotateOptions} options Rotate options.
+ * @param {olx.animation.RotateOptions} options Rotate options.
* @return {ol.PreRenderFunction} Pre-render function.
* @todo stability experimental
*/
@@ -119,7 +119,7 @@ ol.animation.rotate = function(options) {
/**
- * @param {ol.animation.ZoomOptions} options Zoom options.
+ * @param {olx.animation.ZoomOptions} options Zoom options.
* @return {ol.PreRenderFunction} Pre-render function.
* @todo stability experimental
*/
diff --git a/src/ol/attribution.exports b/src/ol/attribution.exports
index 27673d4985..053c0abeae 100644
--- a/src/ol/attribution.exports
+++ b/src/ol/attribution.exports
@@ -1 +1 @@
-@exportClass ol.Attribution ol.AttributionOptions
+@exportSymbol ol.Attribution
diff --git a/src/ol/attribution.js b/src/ol/attribution.js
index b762dfb006..3c95c8b83d 100644
--- a/src/ol/attribution.js
+++ b/src/ol/attribution.js
@@ -20,7 +20,7 @@ goog.require('ol.TileRange');
* ..
*
* @constructor
- * @param {ol.AttributionOptions} options Attribution options.
+ * @param {olx.AttributionOptions} options Attribution options.
* @struct
* @todo stability experimental
*/
diff --git a/src/ol/control/attributioncontrol.exports b/src/ol/control/attributioncontrol.exports
index b5e1d2983d..a9fa893101 100644
--- a/src/ol/control/attributioncontrol.exports
+++ b/src/ol/control/attributioncontrol.exports
@@ -1,2 +1,2 @@
-@exportClass ol.control.Attribution ol.control.AttributionOptions
+@exportSymbol ol.control.Attribution
@exportProperty ol.control.Attribution.prototype.setMap
diff --git a/src/ol/control/attributioncontrol.js b/src/ol/control/attributioncontrol.js
index f5d2ed225f..b8e6e63b58 100644
--- a/src/ol/control/attributioncontrol.js
+++ b/src/ol/control/attributioncontrol.js
@@ -21,7 +21,7 @@ goog.require('ol.css');
* be changed by using a css selector for `.ol-attribution`.
* @constructor
* @extends {ol.control.Control}
- * @param {ol.control.AttributionOptions=} opt_options Attribution options.
+ * @param {olx.control.AttributionOptions=} opt_options Attribution options.
* @todo stability experimental
*/
ol.control.Attribution = function(opt_options) {
diff --git a/src/ol/control/control.exports b/src/ol/control/control.exports
index ad6eba3825..1d184d239e 100644
--- a/src/ol/control/control.exports
+++ b/src/ol/control/control.exports
@@ -1,3 +1,3 @@
-@exportClass ol.control.Control ol.control.ControlOptions
+@exportSymbol ol.control.Control
@exportProperty ol.control.Control.prototype.getMap
@exportProperty ol.control.Control.prototype.setMap
diff --git a/src/ol/control/control.js b/src/ol/control/control.js
index b57a732e38..d7b96d18d0 100644
--- a/src/ol/control/control.js
+++ b/src/ol/control/control.js
@@ -15,7 +15,7 @@ goog.require('ol.Object');
* @constructor
* @extends {ol.Object}
* @implements {oli.control.Control}
- * @param {ol.control.ControlOptions} options Control options.
+ * @param {olx.control.ControlOptions} options Control options.
* @todo stability experimental
*/
ol.control.Control = function(options) {
diff --git a/src/ol/control/controldefaults.exports b/src/ol/control/controldefaults.exports
index a3ee165dd7..0023131772 100644
--- a/src/ol/control/controldefaults.exports
+++ b/src/ol/control/controldefaults.exports
@@ -1 +1 @@
-@exportFunction ol.control.defaults ol.control.DefaultsOptions ol.Collection
+@exportSymbol ol.control.defaults ol.control.defaults
diff --git a/src/ol/control/controldefaults.js b/src/ol/control/controldefaults.js
index 0546ee1229..da53820325 100644
--- a/src/ol/control/controldefaults.js
+++ b/src/ol/control/controldefaults.js
@@ -7,7 +7,7 @@ goog.require('ol.control.Zoom');
/**
- * @param {ol.control.DefaultsOptions=} opt_options Defaults options.
+ * @param {olx.control.DefaultsOptions=} opt_options Defaults options.
* @return {ol.Collection} Controls.
* @todo stability experimental
*/
diff --git a/src/ol/control/fullscreencontrol.exports b/src/ol/control/fullscreencontrol.exports
index ab662df885..6b8c9b566c 100644
--- a/src/ol/control/fullscreencontrol.exports
+++ b/src/ol/control/fullscreencontrol.exports
@@ -1 +1 @@
-@exportClass ol.control.FullScreen ol.control.FullScreenOptions
+@exportSymbol ol.control.FullScreen
diff --git a/src/ol/control/fullscreencontrol.js b/src/ol/control/fullscreencontrol.js
index 12f9823f4d..b7a5dac4fd 100644
--- a/src/ol/control/fullscreencontrol.js
+++ b/src/ol/control/fullscreencontrol.js
@@ -22,7 +22,7 @@ goog.require('ol.css');
*
* @constructor
* @extends {ol.control.Control}
- * @param {ol.control.FullScreenOptions=} opt_options Options.
+ * @param {olx.control.FullScreenOptions=} opt_options Options.
* @todo stability experimental
*/
ol.control.FullScreen = function(opt_options) {
diff --git a/src/ol/control/logocontrol.exports b/src/ol/control/logocontrol.exports
index ee50fb83e3..ccae41d4aa 100644
--- a/src/ol/control/logocontrol.exports
+++ b/src/ol/control/logocontrol.exports
@@ -1,2 +1,2 @@
-@exportClass ol.control.Logo ol.control.LogoOptions
+@exportSymbol ol.control.Logo
@exportProperty ol.control.Logo.prototype.setMap
diff --git a/src/ol/control/logocontrol.js b/src/ol/control/logocontrol.js
index 8843e10d7e..e1ebaa359a 100644
--- a/src/ol/control/logocontrol.js
+++ b/src/ol/control/logocontrol.js
@@ -17,7 +17,7 @@ goog.require('ol.css');
* be styled by using a css selector for `.ol-logo`.
* @constructor
* @extends {ol.control.Control}
- * @param {ol.control.LogoOptions=} opt_options Logo options.
+ * @param {olx.control.LogoOptions=} opt_options Logo options.
* @todo stability experimental
*/
ol.control.Logo = function(opt_options) {
diff --git a/src/ol/control/mousepositioncontrol.exports b/src/ol/control/mousepositioncontrol.exports
index 925d6c0720..73f28771eb 100644
--- a/src/ol/control/mousepositioncontrol.exports
+++ b/src/ol/control/mousepositioncontrol.exports
@@ -1,2 +1,2 @@
-@exportClass ol.control.MousePosition ol.control.MousePositionOptions
+@exportSymbol ol.control.MousePosition
@exportProperty ol.control.MousePosition.prototype.setMap
diff --git a/src/ol/control/mousepositioncontrol.js b/src/ol/control/mousepositioncontrol.js
index 3697e9f7b6..c103e9ad84 100644
--- a/src/ol/control/mousepositioncontrol.js
+++ b/src/ol/control/mousepositioncontrol.js
@@ -36,7 +36,8 @@ ol.control.MousePositionProperty = {
*
* @constructor
* @extends {ol.control.Control}
- * @param {ol.control.MousePositionOptions=} opt_options Mouse position options.
+ * @param {olx.control.MousePositionOptions=} opt_options Mouse position
+ * options.
* @todo stability experimental
* @todo observable projection {ol.proj.Projection} the projection to report
* mouse position in
diff --git a/src/ol/control/scalelinecontrol.exports b/src/ol/control/scalelinecontrol.exports
index 6d0cbe1cd1..ccdf40d51b 100644
--- a/src/ol/control/scalelinecontrol.exports
+++ b/src/ol/control/scalelinecontrol.exports
@@ -1,4 +1,4 @@
-@exportClass ol.control.ScaleLine ol.control.ScaleLineOptions
+@exportSymbol ol.control.ScaleLine
@exportProperty ol.control.ScaleLine.prototype.setMap
@exportSymbol ol.control.ScaleLineUnits
diff --git a/src/ol/control/scalelinecontrol.js b/src/ol/control/scalelinecontrol.js
index ccaabb707d..5c18bac16c 100644
--- a/src/ol/control/scalelinecontrol.js
+++ b/src/ol/control/scalelinecontrol.js
@@ -49,7 +49,7 @@ ol.control.ScaleLineUnits = {
*
* @constructor
* @extends {ol.control.Control}
- * @param {ol.control.ScaleLineOptions=} opt_options Scale line options.
+ * @param {olx.control.ScaleLineOptions=} opt_options Scale line options.
* @todo stability experimental
* @todo observable units {ol.control.ScaleLineUnits} the units to use in the
* scale line
diff --git a/src/ol/control/zoomcontrol.exports b/src/ol/control/zoomcontrol.exports
index 91cb9a7fbe..8d8123f761 100644
--- a/src/ol/control/zoomcontrol.exports
+++ b/src/ol/control/zoomcontrol.exports
@@ -1,2 +1,2 @@
-@exportClass ol.control.Zoom ol.control.ZoomOptions
+@exportSymbol ol.control.Zoom
@exportProperty ol.control.Zoom.prototype.setMap
diff --git a/src/ol/control/zoomcontrol.js b/src/ol/control/zoomcontrol.js
index 72f278353b..f31b6aaa66 100644
--- a/src/ol/control/zoomcontrol.js
+++ b/src/ol/control/zoomcontrol.js
@@ -19,7 +19,7 @@ goog.require('ol.easing');
* use css selectors `.ol-zoom-in` and `.ol-zoom-out`.
* @constructor
* @extends {ol.control.Control}
- * @param {ol.control.ZoomOptions=} opt_options Zoom options.
+ * @param {olx.control.ZoomOptions=} opt_options Zoom options.
* @todo stability experimental
*/
ol.control.Zoom = function(opt_options) {
diff --git a/src/ol/control/zoomslidercontrol.exports b/src/ol/control/zoomslidercontrol.exports
index 9b07355c21..3be7924ba6 100644
--- a/src/ol/control/zoomslidercontrol.exports
+++ b/src/ol/control/zoomslidercontrol.exports
@@ -1 +1 @@
-@exportClass ol.control.ZoomSlider ol.control.ZoomSliderOptions
+@exportSymbol ol.control.ZoomSlider
diff --git a/src/ol/control/zoomslidercontrol.js b/src/ol/control/zoomslidercontrol.js
index 52b9e1f2d4..c2cf84481e 100644
--- a/src/ol/control/zoomslidercontrol.js
+++ b/src/ol/control/zoomslidercontrol.js
@@ -37,7 +37,7 @@ ol.control.ZOOMSLIDER_ANIMATION_DURATION = 200;
*
* @constructor
* @extends {ol.control.Control}
- * @param {ol.control.ZoomSliderOptions=} opt_options Zoom slider options.
+ * @param {olx.control.ZoomSliderOptions=} opt_options Zoom slider options.
* @todo stability experimental
*/
ol.control.ZoomSlider = function(opt_options) {
diff --git a/src/ol/control/zoomtoextentcontrol.exports b/src/ol/control/zoomtoextentcontrol.exports
index ca571c4f86..485e551f42 100644
--- a/src/ol/control/zoomtoextentcontrol.exports
+++ b/src/ol/control/zoomtoextentcontrol.exports
@@ -1 +1 @@
-@exportClass ol.control.ZoomToExtent ol.control.ZoomToExtentOptions
+@exportSymbol ol.control.ZoomToExtent
diff --git a/src/ol/control/zoomtoextentcontrol.js b/src/ol/control/zoomtoextentcontrol.js
index f926db5a0d..71fdae3a99 100644
--- a/src/ol/control/zoomtoextentcontrol.js
+++ b/src/ol/control/zoomtoextentcontrol.js
@@ -17,7 +17,7 @@ goog.require('ol.css');
* css selector `.ol-zoom-extent`.
* @constructor
* @extends {ol.control.Control}
- * @param {ol.control.ZoomToExtentOptions=} opt_options Options.
+ * @param {olx.control.ZoomToExtentOptions=} opt_options Options.
* @todo stability experimental
*/
ol.control.ZoomToExtent = function(opt_options) {
diff --git a/src/ol/deviceorientation.exports b/src/ol/deviceorientation.exports
index 31910aa9b1..b0a0b9eaf2 100644
--- a/src/ol/deviceorientation.exports
+++ b/src/ol/deviceorientation.exports
@@ -1,2 +1,2 @@
-@exportClass ol.DeviceOrientation ol.DeviceOrientationOptions
+@exportSymbol ol.DeviceOrientation
@exportSymbol ol.DeviceOrientation.SUPPORTED ol.DeviceOrientation.SUPPORTED
diff --git a/src/ol/deviceorientation.js b/src/ol/deviceorientation.js
index 87c51ec8d1..000494963b 100644
--- a/src/ol/deviceorientation.js
+++ b/src/ol/deviceorientation.js
@@ -67,7 +67,7 @@ ol.DeviceOrientationProperty = {
*
* @constructor
* @extends {ol.Object}
- * @param {ol.DeviceOrientationOptions=} opt_options Options.
+ * @param {olx.DeviceOrientationOptions=} opt_options Options.
* @todo stability experimental
* @todo observable alpha {number} readonly the euler angle in radians of the
* device from the standard X axis
diff --git a/src/ol/format/geojsonformat.exports b/src/ol/format/geojsonformat.exports
index 04b82fa2b4..f185a2af03 100644
--- a/src/ol/format/geojsonformat.exports
+++ b/src/ol/format/geojsonformat.exports
@@ -1 +1 @@
-@exportClass ol.format.GeoJSON ol.format.GeoJSONOptions
+@exportSymbol ol.format.GeoJSON
diff --git a/src/ol/format/geojsonformat.js b/src/ol/format/geojsonformat.js
index ae5d9c76e8..07fb1de43a 100644
--- a/src/ol/format/geojsonformat.js
+++ b/src/ol/format/geojsonformat.js
@@ -22,7 +22,7 @@ goog.require('ol.proj');
/**
* @constructor
* @extends {ol.format.JSON}
- * @param {ol.format.GeoJSONOptions=} opt_options Options.
+ * @param {olx.format.GeoJSONOptions=} opt_options Options.
*/
ol.format.GeoJSON = function(opt_options) {
diff --git a/src/ol/geolocation.exports b/src/ol/geolocation.exports
index 3040f335d7..398f9fefea 100644
--- a/src/ol/geolocation.exports
+++ b/src/ol/geolocation.exports
@@ -1,2 +1,2 @@
-@exportClass ol.Geolocation ol.GeolocationOptions
+@exportSymbol ol.Geolocation
@exportSymbol ol.Geolocation.SUPPORTED ol.Geolocation.SUPPORTED
diff --git a/src/ol/geolocation.js b/src/ol/geolocation.js
index 884cac198d..ffb7a11638 100644
--- a/src/ol/geolocation.js
+++ b/src/ol/geolocation.js
@@ -45,7 +45,7 @@ ol.GeolocationProperty = {
*
* @constructor
* @extends {ol.Object}
- * @param {ol.GeolocationOptions=} opt_options Options.
+ * @param {olx.GeolocationOptions=} opt_options Options.
* @todo stability experimental
* @todo observable accuracy {number} readonly the accuracy of the position
* measurement
diff --git a/src/ol/interaction/doubleclickzoom.exports b/src/ol/interaction/doubleclickzoom.exports
index 43824d9543..796868f1f1 100644
--- a/src/ol/interaction/doubleclickzoom.exports
+++ b/src/ol/interaction/doubleclickzoom.exports
@@ -1 +1 @@
-@exportClass ol.interaction.DoubleClickZoom ol.interaction.DoubleClickZoomOptions
+@exportSymbol ol.interaction.DoubleClickZoom
diff --git a/src/ol/interaction/doubleclickzoominteraction.js b/src/ol/interaction/doubleclickzoominteraction.js
index 1b106052b1..ac4f7c9668 100644
--- a/src/ol/interaction/doubleclickzoominteraction.js
+++ b/src/ol/interaction/doubleclickzoominteraction.js
@@ -14,7 +14,7 @@ goog.require('ol.interaction.Interaction');
*
* @constructor
* @extends {ol.interaction.Interaction}
- * @param {ol.interaction.DoubleClickZoomOptions=} opt_options Options.
+ * @param {olx.interaction.DoubleClickZoomOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.DoubleClickZoom = function(opt_options) {
diff --git a/src/ol/interaction/dragpan.exports b/src/ol/interaction/dragpan.exports
index 6c68510100..dbc71bf21a 100644
--- a/src/ol/interaction/dragpan.exports
+++ b/src/ol/interaction/dragpan.exports
@@ -1 +1 @@
-@exportClass ol.interaction.DragPan ol.interaction.DragPanOptions
+@exportSymbol ol.interaction.DragPan
diff --git a/src/ol/interaction/dragpaninteraction.js b/src/ol/interaction/dragpaninteraction.js
index d1d668d551..d98a801639 100644
--- a/src/ol/interaction/dragpaninteraction.js
+++ b/src/ol/interaction/dragpaninteraction.js
@@ -18,7 +18,7 @@ goog.require('ol.interaction.Drag');
* Allows the user to pan the map by clickng and dragging.
* @constructor
* @extends {ol.interaction.Drag}
- * @param {ol.interaction.DragPanOptions=} opt_options Options.
+ * @param {olx.interaction.DragPanOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.DragPan = function(opt_options) {
diff --git a/src/ol/interaction/dragrotate.exports b/src/ol/interaction/dragrotate.exports
index 1ca795259f..b17241c644 100644
--- a/src/ol/interaction/dragrotate.exports
+++ b/src/ol/interaction/dragrotate.exports
@@ -1 +1 @@
-@exportClass ol.interaction.DragRotate ol.interaction.DragRotateOptions
+@exportSymbol ol.interaction.DragRotate
diff --git a/src/ol/interaction/dragrotateandzoom.exports b/src/ol/interaction/dragrotateandzoom.exports
index c217fc5a82..f39bc1cf2a 100644
--- a/src/ol/interaction/dragrotateandzoom.exports
+++ b/src/ol/interaction/dragrotateandzoom.exports
@@ -1 +1 @@
-@exportClass ol.interaction.DragRotateAndZoom ol.interaction.DragRotateAndZoomOptions
+@exportSymbol ol.interaction.DragRotateAndZoom
diff --git a/src/ol/interaction/dragrotateandzoominteraction.js b/src/ol/interaction/dragrotateandzoominteraction.js
index c479deefbb..b2588a2af3 100644
--- a/src/ol/interaction/dragrotateandzoominteraction.js
+++ b/src/ol/interaction/dragrotateandzoominteraction.js
@@ -26,7 +26,7 @@ ol.interaction.DRAGROTATEANDZOOM_ANIMATION_DURATION = 400;
* This interaction is not included in the default interactions.
* @constructor
* @extends {ol.interaction.Drag}
- * @param {ol.interaction.DragRotateAndZoomOptions=} opt_options Options.
+ * @param {olx.interaction.DragRotateAndZoomOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.DragRotateAndZoom = function(opt_options) {
diff --git a/src/ol/interaction/dragrotateinteraction.js b/src/ol/interaction/dragrotateinteraction.js
index b43aaed167..06a85e3eb9 100644
--- a/src/ol/interaction/dragrotateinteraction.js
+++ b/src/ol/interaction/dragrotateinteraction.js
@@ -21,7 +21,7 @@ ol.interaction.DRAGROTATE_ANIMATION_DURATION = 250;
* it to when the alt and shift keys are held down.
* @constructor
* @extends {ol.interaction.Drag}
- * @param {ol.interaction.DragRotateOptions=} opt_options Options.
+ * @param {olx.interaction.DragRotateOptions=} opt_options Options.
*/
ol.interaction.DragRotate = function(opt_options) {
diff --git a/src/ol/interaction/dragzoom.exports b/src/ol/interaction/dragzoom.exports
index e9f5fb88fb..204afabe7e 100644
--- a/src/ol/interaction/dragzoom.exports
+++ b/src/ol/interaction/dragzoom.exports
@@ -1 +1 @@
-@exportClass ol.interaction.DragZoom ol.interaction.DragZoomOptions
+@exportSymbol ol.interaction.DragZoom
diff --git a/src/ol/interaction/dragzoominteraction.js b/src/ol/interaction/dragzoominteraction.js
index 02a592ca76..b7a6737613 100644
--- a/src/ol/interaction/dragzoominteraction.js
+++ b/src/ol/interaction/dragzoominteraction.js
@@ -34,7 +34,7 @@ ol.SHIFT_DRAG_ZOOM_HYSTERESIS_PIXELS_SQUARED =
* it to when the shift key is held down.
* @constructor
* @extends {ol.interaction.Drag}
- * @param {ol.interaction.DragZoomOptions=} opt_options Options.
+ * @param {olx.interaction.DragZoomOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.DragZoom = function(opt_options) {
diff --git a/src/ol/interaction/interactiondefaults.exports b/src/ol/interaction/interactiondefaults.exports
index 6e30aa7234..2ab5e46392 100644
--- a/src/ol/interaction/interactiondefaults.exports
+++ b/src/ol/interaction/interactiondefaults.exports
@@ -1 +1 @@
-@exportFunction ol.interaction.defaults ol.interaction.DefaultsOptions ol.Collection
+@exportSymbol ol.interaction.defaults ol.interaction.defaults
diff --git a/src/ol/interaction/interactiondefaults.js b/src/ol/interaction/interactiondefaults.js
index b6e39c8752..32b4e5569c 100644
--- a/src/ol/interaction/interactiondefaults.js
+++ b/src/ol/interaction/interactiondefaults.js
@@ -23,7 +23,7 @@ goog.require('ol.interaction.TouchZoom');
* {@link ol.interaction} instances and insert them into an
* {@link ol.Collection} in the order you want before creating your ol.Map
* instance.
- * @param {ol.interaction.DefaultsOptions=} opt_options Defaults options.
+ * @param {olx.interaction.DefaultsOptions=} opt_options Defaults options.
* @return {ol.Collection} A collection of interactions to be used with
* the ol.Map constructor's interactions option.
* @todo stability experimental
diff --git a/src/ol/interaction/keyboardpan.exports b/src/ol/interaction/keyboardpan.exports
index ee8f69fbf0..a09f837004 100644
--- a/src/ol/interaction/keyboardpan.exports
+++ b/src/ol/interaction/keyboardpan.exports
@@ -1 +1 @@
-@exportClass ol.interaction.KeyboardPan ol.interaction.KeyboardPanOptions
+@exportSymbol ol.interaction.KeyboardPan
diff --git a/src/ol/interaction/keyboardpaninteraction.js b/src/ol/interaction/keyboardpaninteraction.js
index ae3b15b8ef..f38e0c004a 100644
--- a/src/ol/interaction/keyboardpaninteraction.js
+++ b/src/ol/interaction/keyboardpaninteraction.js
@@ -24,7 +24,7 @@ ol.interaction.KEYBOARD_PAN_DURATION = 100;
* Allows the user to pan the map using keyboard arrows.
* @constructor
* @extends {ol.interaction.Interaction}
- * @param {ol.interaction.KeyboardPanOptions=} opt_options Options.
+ * @param {olx.interaction.KeyboardPanOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.KeyboardPan = function(opt_options) {
diff --git a/src/ol/interaction/keyboardzoom.exports b/src/ol/interaction/keyboardzoom.exports
index e344610661..01a6a9d315 100644
--- a/src/ol/interaction/keyboardzoom.exports
+++ b/src/ol/interaction/keyboardzoom.exports
@@ -1 +1 @@
-@exportClass ol.interaction.KeyboardZoom ol.interaction.KeyboardZoomOptions
+@exportSymbol ol.interaction.KeyboardZoom
diff --git a/src/ol/interaction/keyboardzoominteraction.js b/src/ol/interaction/keyboardzoominteraction.js
index 6fa1bd4ad0..e43dab79ea 100644
--- a/src/ol/interaction/keyboardzoominteraction.js
+++ b/src/ol/interaction/keyboardzoominteraction.js
@@ -13,7 +13,7 @@ goog.require('ol.interaction.Interaction');
/**
* Allows the user to zoom the map using keyboard + and -.
* @constructor
- * @param {ol.interaction.KeyboardZoomOptions=} opt_options Options.
+ * @param {olx.interaction.KeyboardZoomOptions=} opt_options Options.
* @extends {ol.interaction.Interaction}
* @todo stability experimental
*/
diff --git a/src/ol/interaction/mousewheelzoominteraction.js b/src/ol/interaction/mousewheelzoominteraction.js
index 29999fb194..fb1c229ceb 100644
--- a/src/ol/interaction/mousewheelzoominteraction.js
+++ b/src/ol/interaction/mousewheelzoominteraction.js
@@ -27,7 +27,7 @@ ol.interaction.MOUSEWHEELZOOM_TIMEOUT_DURATION = 80;
* Allows the user to zoom the map by scrolling the mouse wheel.
* @constructor
* @extends {ol.interaction.Interaction}
- * @param {ol.interaction.MouseWheelZoomOptions=} opt_options Options.
+ * @param {olx.interaction.MouseWheelZoomOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.MouseWheelZoom = function(opt_options) {
diff --git a/src/ol/interaction/touchpan.exports b/src/ol/interaction/touchpan.exports
index daf3f02096..e50ab8ec1c 100644
--- a/src/ol/interaction/touchpan.exports
+++ b/src/ol/interaction/touchpan.exports
@@ -1 +1 @@
-@exportClass ol.interaction.TouchPan ol.interaction.TouchPanOptions
+@exportSymbol ol.interaction.TouchPan
diff --git a/src/ol/interaction/touchpaninteraction.js b/src/ol/interaction/touchpaninteraction.js
index 41f494a7b2..3f2efb7cb6 100644
--- a/src/ol/interaction/touchpaninteraction.js
+++ b/src/ol/interaction/touchpaninteraction.js
@@ -15,7 +15,7 @@ goog.require('ol.interaction.Touch');
* on a touch screen.
* @constructor
* @extends {ol.interaction.Touch}
- * @param {ol.interaction.TouchPanOptions=} opt_options Options.
+ * @param {olx.interaction.TouchPanOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.TouchPan = function(opt_options) {
diff --git a/src/ol/interaction/touchrotate.exports b/src/ol/interaction/touchrotate.exports
index 9f00bf6c56..b7045b88ab 100644
--- a/src/ol/interaction/touchrotate.exports
+++ b/src/ol/interaction/touchrotate.exports
@@ -1 +1 @@
-@exportClass ol.interaction.TouchRotate ol.interaction.TouchRotateOptions
+@exportSymbol ol.interaction.TouchRotate
diff --git a/src/ol/interaction/touchrotateinteraction.js b/src/ol/interaction/touchrotateinteraction.js
index 617c522daf..ddf3fcc0e7 100644
--- a/src/ol/interaction/touchrotateinteraction.js
+++ b/src/ol/interaction/touchrotateinteraction.js
@@ -21,7 +21,7 @@ ol.interaction.TOUCHROTATE_ANIMATION_DURATION = 250;
* on a touch screen.
* @constructor
* @extends {ol.interaction.Touch}
- * @param {ol.interaction.TouchRotateOptions=} opt_options Options.
+ * @param {olx.interaction.TouchRotateOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.TouchRotate = function(opt_options) {
diff --git a/src/ol/interaction/touchzoominteraction.js b/src/ol/interaction/touchzoominteraction.js
index 17c2c9f3bc..b642852b82 100644
--- a/src/ol/interaction/touchzoominteraction.js
+++ b/src/ol/interaction/touchzoominteraction.js
@@ -15,7 +15,7 @@ goog.require('ol.interaction.Touch');
* on a touch screen.
* @constructor
* @extends {ol.interaction.Touch}
- * @param {ol.interaction.TouchZoomOptions=} opt_options Options.
+ * @param {olx.interaction.TouchZoomOptions=} opt_options Options.
* @todo stability experimental
*/
ol.interaction.TouchZoom = function(opt_options) {
diff --git a/src/ol/layer/imagelayer.exports b/src/ol/layer/imagelayer.exports
index 81b291a2f1..0027269144 100644
--- a/src/ol/layer/imagelayer.exports
+++ b/src/ol/layer/imagelayer.exports
@@ -1 +1 @@
-@exportClass ol.layer.Image ol.layer.LayerOptions
+@exportSymbol ol.layer.Image
diff --git a/src/ol/layer/imagelayer.js b/src/ol/layer/imagelayer.js
index f3d6b49ac9..d75edf8ded 100644
--- a/src/ol/layer/imagelayer.js
+++ b/src/ol/layer/imagelayer.js
@@ -8,7 +8,7 @@ goog.require('ol.source.Image');
/**
* @constructor
* @extends {ol.layer.Layer}
- * @param {ol.layer.LayerOptions} options Layer options.
+ * @param {olx.layer.LayerOptions} options Layer options.
* @todo stability experimental
*/
ol.layer.Image = function(options) {
diff --git a/src/ol/layer/layer.js b/src/ol/layer/layer.js
index b095c51584..a83bfb9183 100644
--- a/src/ol/layer/layer.js
+++ b/src/ol/layer/layer.js
@@ -12,7 +12,7 @@ goog.require('ol.source.Source');
/**
* @constructor
* @extends {ol.layer.Base}
- * @param {ol.layer.LayerOptions} options Layer options.
+ * @param {olx.layer.LayerOptions} options Layer options.
* @todo stability experimental
* @todo observable brightness {number} the brightness of the layer
* @todo observable contrast {number} the contrast of the layer
@@ -25,7 +25,7 @@ goog.require('ol.source.Source');
*/
ol.layer.Layer = function(options) {
- var baseOptions = /** @type {ol.layer.LayerOptions} */
+ var baseOptions = /** @type {olx.layer.LayerOptions} */
(goog.object.clone(options));
delete baseOptions.source;
diff --git a/src/ol/layer/layerbase.js b/src/ol/layer/layerbase.js
index a6f590de07..389f3afef7 100644
--- a/src/ol/layer/layerbase.js
+++ b/src/ol/layer/layerbase.js
@@ -43,7 +43,7 @@ ol.layer.LayerState;
/**
* @constructor
* @extends {ol.Object}
- * @param {ol.layer.BaseOptions} options Layer options.
+ * @param {olx.layer.BaseOptions} options Layer options.
*/
ol.layer.Base = function(options) {
@@ -71,22 +71,6 @@ ol.layer.Base = function(options) {
values.minResolution : 0;
this.setValues(values);
-
- goog.events.listen(this, [
- ol.Object.getChangeEventType(ol.layer.LayerProperty.BRIGHTNESS),
- ol.Object.getChangeEventType(ol.layer.LayerProperty.CONTRAST),
- ol.Object.getChangeEventType(ol.layer.LayerProperty.HUE),
- ol.Object.getChangeEventType(ol.layer.LayerProperty.OPACITY),
- ol.Object.getChangeEventType(ol.layer.LayerProperty.SATURATION),
- ol.Object.getChangeEventType(ol.layer.LayerProperty.MAX_RESOLUTION),
- ol.Object.getChangeEventType(ol.layer.LayerProperty.MIN_RESOLUTION)
- ],
- this.handleLayerChange, false, this);
-
- goog.events.listen(this,
- ol.Object.getChangeEventType(ol.layer.LayerProperty.VISIBLE),
- this.handleLayerVisibleChange, false, this);
-
};
goog.inherits(ol.layer.Base, ol.Object);
@@ -251,26 +235,6 @@ goog.exportProperty(
ol.layer.Base.prototype.getVisible);
-/**
- * @protected
- */
-ol.layer.Base.prototype.handleLayerChange = function() {
- if (this.getVisible() && this.getSourceState() == ol.source.State.READY) {
- this.dispatchChangeEvent();
- }
-};
-
-
-/**
- * @protected
- */
-ol.layer.Base.prototype.handleLayerVisibleChange = function() {
- if (this.getSourceState() == ol.source.State.READY) {
- this.dispatchChangeEvent();
- }
-};
-
-
/**
* Adjust the layer brightness. A value of -1 will render the layer completely
* black. A value of 0 will leave the brightness unchanged. A value of 1 will
diff --git a/src/ol/layer/layergroup.exports b/src/ol/layer/layergroup.exports
index 58cd20a73c..54bd439663 100644
--- a/src/ol/layer/layergroup.exports
+++ b/src/ol/layer/layergroup.exports
@@ -1 +1 @@
-@exportClass ol.layer.Group ol.layer.GroupOptions
+@exportSymbol ol.layer.Group
diff --git a/src/ol/layer/layergroup.js b/src/ol/layer/layergroup.js
index df7ce69dff..50649459f0 100644
--- a/src/ol/layer/layergroup.js
+++ b/src/ol/layer/layergroup.js
@@ -26,7 +26,7 @@ ol.layer.GroupProperty = {
/**
* @constructor
* @extends {ol.layer.Base}
- * @param {ol.layer.GroupOptions=} opt_options Layer options.
+ * @param {olx.layer.GroupOptions=} opt_options Layer options.
* @todo stability experimental
* @todo observable layers {ol.Collection} collection of layers that are part
* of this group
@@ -34,7 +34,7 @@ ol.layer.GroupProperty = {
ol.layer.Group = function(opt_options) {
var options = goog.isDef(opt_options) ? opt_options : {};
- var baseOptions = /** @type {ol.layer.GroupOptions} */
+ var baseOptions = /** @type {olx.layer.GroupOptions} */
(goog.object.clone(options));
delete baseOptions.layers;
@@ -70,23 +70,15 @@ goog.inherits(ol.layer.Group, ol.layer.Base);
/**
- * @inheritDoc
+ * @private
*/
-ol.layer.Group.prototype.handleLayerChange = function() {
+ol.layer.Group.prototype.handleLayerChange_ = function() {
if (this.getVisible()) {
this.dispatchChangeEvent();
}
};
-/**
- * @inheritDoc
- */
-ol.layer.Group.prototype.handleLayerVisibleChange = function() {
- this.dispatchChangeEvent();
-};
-
-
/**
* @param {goog.events.Event} event Event.
* @private
@@ -113,7 +105,7 @@ ol.layer.Group.prototype.handleLayersChanged_ = function(event) {
layer = layersArray[i];
this.listenerKeys_[goog.getUid(layer).toString()] =
goog.events.listen(layer, goog.events.EventType.CHANGE,
- this.handleLayerChange, false, this);
+ this.handleLayerChange_, false, this);
}
}
@@ -128,7 +120,7 @@ ol.layer.Group.prototype.handleLayersChanged_ = function(event) {
ol.layer.Group.prototype.handleLayersAdd_ = function(collectionEvent) {
var layer = /** @type {ol.layer.Base} */ (collectionEvent.getElement());
this.listenerKeys_[goog.getUid(layer).toString()] = goog.events.listen(
- layer, goog.events.EventType.CHANGE, this.handleLayerChange, false,
+ layer, goog.events.EventType.CHANGE, this.handleLayerChange_, false,
this);
this.dispatchChangeEvent();
};
diff --git a/src/ol/layer/tilelayer.exports b/src/ol/layer/tilelayer.exports
index d3ded24332..941be6ffc8 100644
--- a/src/ol/layer/tilelayer.exports
+++ b/src/ol/layer/tilelayer.exports
@@ -1 +1 @@
-@exportClass ol.layer.Tile ol.layer.TileOptions
+@exportSymbol ol.layer.Tile
diff --git a/src/ol/layer/tilelayer.js b/src/ol/layer/tilelayer.js
index 2bbbde2764..f8ba630d95 100644
--- a/src/ol/layer/tilelayer.js
+++ b/src/ol/layer/tilelayer.js
@@ -16,7 +16,7 @@ ol.layer.TileProperty = {
/**
* @constructor
* @extends {ol.layer.Layer}
- * @param {ol.layer.TileOptions} options Tile layer options.
+ * @param {olx.layer.TileOptions} options Tile layer options.
* @todo stability experimental
* @todo observable preload {number} the level to preload tiles up to
*/
diff --git a/src/ol/layer/vectorlayer.exports b/src/ol/layer/vectorlayer.exports
index 3e32bbc6f4..3dc18a2d27 100644
--- a/src/ol/layer/vectorlayer.exports
+++ b/src/ol/layer/vectorlayer.exports
@@ -1 +1 @@
-@exportClass ol.layer.Vector ol.layer.VectorOptions
+@exportSymbol ol.layer.Vector
diff --git a/src/ol/layer/vectorlayer.js b/src/ol/layer/vectorlayer.js
index cbfae1dac3..e9a9290119 100644
--- a/src/ol/layer/vectorlayer.js
+++ b/src/ol/layer/vectorlayer.js
@@ -17,14 +17,14 @@ ol.layer.VectorProperty = {
/**
* @constructor
* @extends {ol.layer.Layer}
- * @param {ol.layer.VectorOptions=} opt_options Options.
+ * @param {olx.layer.VectorOptions=} opt_options Options.
*/
ol.layer.Vector = function(opt_options) {
var options = goog.isDef(opt_options) ?
- opt_options : /** @type {ol.layer.VectorOptions} */ ({});
+ opt_options : /** @type {olx.layer.VectorOptions} */ ({});
- goog.base(this, /** @type {ol.layer.LayerOptions} */ (options));
+ goog.base(this, /** @type {olx.layer.LayerOptions} */ (options));
// FIXME veryify this
if (goog.isDef(options.styleFunction)) {
diff --git a/src/ol/map.exports b/src/ol/map.exports
index 582049a70f..8031670912 100644
--- a/src/ol/map.exports
+++ b/src/ol/map.exports
@@ -1,4 +1,4 @@
-@exportClass ol.Map ol.MapOptions
+@exportSymbol ol.Map
@exportProperty ol.Map.prototype.addControl
@exportProperty ol.Map.prototype.addInteraction
@exportProperty ol.Map.prototype.addLayer
diff --git a/src/ol/map.js b/src/ol/map.js
index 4aef67403a..8f9443df31 100644
--- a/src/ol/map.js
+++ b/src/ol/map.js
@@ -141,7 +141,7 @@ ol.MapProperty = {
*
* @constructor
* @extends {ol.Object}
- * @param {ol.MapOptions} options Map options.
+ * @param {olx.MapOptions} options Map options.
* @todo stability experimental
* @todo observable layergroup {ol.layer.LayerGroup} a layer group containing
* the layers in this map.
@@ -1224,7 +1224,7 @@ ol.MapOptionsInternal;
/**
- * @param {ol.MapOptions} options Map options.
+ * @param {olx.MapOptions} options Map options.
* @return {ol.MapOptionsInternal} Internal map options.
*/
ol.Map.createOptionsInternal = function(options) {
diff --git a/src/ol/mapbrowserevent.exports b/src/ol/mapbrowserevent.exports
index 86297f9067..500ecb1985 100644
--- a/src/ol/mapbrowserevent.exports
+++ b/src/ol/mapbrowserevent.exports
@@ -1,3 +1,4 @@
+@exportProperty ol.MapBrowserEvent.prototype.getBrowserEvent
@exportProperty ol.MapBrowserEvent.prototype.getCoordinate
@exportProperty ol.MapBrowserEvent.prototype.getPixel
@exportProperty ol.MapBrowserEvent.prototype.preventDefault
diff --git a/src/ol/mapbrowserevent.js b/src/ol/mapbrowserevent.js
index ab26e4da3b..ecbfa18817 100644
--- a/src/ol/mapbrowserevent.js
+++ b/src/ol/mapbrowserevent.js
@@ -49,6 +49,14 @@ ol.MapBrowserEvent = function(type, map, browserEvent, opt_frameState) {
goog.inherits(ol.MapBrowserEvent, ol.MapEvent);
+/**
+ * @return {Event} The underlying browser event object.
+ */
+ol.MapBrowserEvent.prototype.getBrowserEvent = function() {
+ return this.browserEvent.getBrowserEvent();
+};
+
+
/**
* @return {ol.Coordinate} Coordinate.
* @todo stability experimental
diff --git a/src/ol/overlay.exports b/src/ol/overlay.exports
index 74783e7ecb..772a546710 100644
--- a/src/ol/overlay.exports
+++ b/src/ol/overlay.exports
@@ -1,4 +1,4 @@
-@exportClass ol.Overlay ol.OverlayOptions
+@exportSymbol ol.Overlay
@exportSymbol ol.OverlayPositioning
@exportProperty ol.OverlayPositioning.BOTTOM_LEFT
diff --git a/src/ol/overlay.js b/src/ol/overlay.js
index 38233f7953..bd81f321c7 100644
--- a/src/ol/overlay.js
+++ b/src/ol/overlay.js
@@ -55,7 +55,7 @@ ol.OverlayPositioning = {
*
* @constructor
* @extends {ol.Object}
- * @param {ol.OverlayOptions} options Overlay options.
+ * @param {olx.OverlayOptions} options Overlay options.
* @todo stability experimental
* @todo observable element {Element} the Element containing the overlay
* @todo observable map {ol.Map} the map that the overlay is part of
diff --git a/src/ol/proj.exports b/src/ol/proj.exports
index e28a06dadd..18aa42ab25 100644
--- a/src/ol/proj.exports
+++ b/src/ol/proj.exports
@@ -1,4 +1,4 @@
-@exportClass ol.proj.Projection ol.ProjectionOptions
+@exportSymbol ol.proj.Projection
@exportProperty ol.proj.Projection.prototype.getCode
@exportProperty ol.proj.Projection.prototype.getExtent
diff --git a/src/ol/proj/proj.js b/src/ol/proj/proj.js
index 97b2d79b69..bcb3f31e2d 100644
--- a/src/ol/proj/proj.js
+++ b/src/ol/proj/proj.js
@@ -58,7 +58,7 @@ ol.METERS_PER_UNIT[ol.proj.Units.METERS] = 1;
/**
* @constructor
- * @param {ol.ProjectionOptions} options Projection options.
+ * @param {olx.ProjectionOptions} options Projection options.
* @struct
* @todo stability experimental
*/
@@ -199,7 +199,7 @@ ol.proj.Projection.prototype.setDefaultTileGrid = function(tileGrid) {
* @constructor
* @extends {ol.proj.Projection}
* @param {Proj4js.Proj} proj4jsProj Proj4js projection.
- * @param {ol.Proj4jsProjectionOptions} options Proj4js projection options.
+ * @param {olx.Proj4jsProjectionOptions} options Proj4js projection options.
* @private
* @struct
*/
@@ -207,7 +207,7 @@ ol.Proj4jsProjection_ = function(proj4jsProj, options) {
var units = /** @type {ol.proj.Units} */ (proj4jsProj.units);
- var config = /** @type {ol.ProjectionOptions} */ ({
+ var config = /** @type {olx.ProjectionOptions} */ ({
units: units,
axisOrientation: proj4jsProj.axis
});
@@ -493,7 +493,7 @@ ol.proj.get = function(projectionLike) {
/**
- * @param {ol.Proj4jsProjectionOptions} options Proj4js projection options.
+ * @param {olx.Proj4jsProjectionOptions} options Proj4js projection options.
* @private
* @return {ol.Proj4jsProjection_} Proj4js projection.
*/
@@ -506,7 +506,7 @@ ol.proj.getProj4jsProjectionFromCode_ = function(options) {
var srsCode = proj4jsProj.srsCode;
proj4jsProjection = proj4jsProjections[srsCode];
if (!goog.isDef(proj4jsProjection)) {
- var config = /** @type {ol.Proj4jsProjectionOptions} */
+ var config = /** @type {olx.Proj4jsProjectionOptions} */
(goog.object.clone(options));
config.code = srsCode;
proj4jsProjection = new ol.Proj4jsProjection_(proj4jsProj, config);
@@ -711,7 +711,7 @@ ol.proj.transformWithProjections =
/**
- * @param {ol.Proj4jsProjectionOptions} options Proj4js projection options.
+ * @param {olx.Proj4jsProjectionOptions} options Proj4js projection options.
* @return {ol.proj.Projection} Proj4js projection.
* @todo stability experimental
*/
diff --git a/src/ol/renderer/canvas/canvastilelayerrenderer.js b/src/ol/renderer/canvas/canvastilelayerrenderer.js
index ccf6a7f4d0..f019c479b8 100644
--- a/src/ol/renderer/canvas/canvastilelayerrenderer.js
+++ b/src/ol/renderer/canvas/canvastilelayerrenderer.js
@@ -181,6 +181,7 @@ ol.renderer.canvas.TileLayer.prototype.prepareFrame =
if (goog.isNull(tileGrid)) {
tileGrid = ol.tilegrid.getForProjection(projection);
}
+ var tileGutter = tileSource.getGutter();
var z = tileGrid.getZForResolution(view2DState.resolution);
var tileSize = tileGrid.getTileSize(z);
var tileResolution = tileGrid.getResolution(z);
@@ -339,7 +340,9 @@ ol.renderer.canvas.TileLayer.prototype.prepareFrame =
context.clearRect(x, y, tileSize[0], tileSize[1]);
}
if (tileState == ol.TileState.LOADED) {
- context.drawImage(tile.getImage(), x, y);
+ context.drawImage(tile.getImage(),
+ tileGutter, tileGutter, tileSize[0], tileSize[1],
+ x, y, tileSize[0], tileSize[1]);
}
this.renderedTiles_[index] = tile;
}
@@ -358,7 +361,9 @@ ol.renderer.canvas.TileLayer.prototype.prepareFrame =
context.clearRect(x, y, width, height);
}
if (tileState == ol.TileState.LOADED) {
- context.drawImage(tile.getImage(), x, y, width, height);
+ context.drawImage(tile.getImage(),
+ tileGutter, tileGutter, tileSize[0], tileSize[1],
+ x, y, width, height);
}
interimTileRange =
tileGrid.getTileRangeForExtentAndZ(tileExtent, z, tmpTileRange);
diff --git a/src/ol/renderer/dom/domtilelayerrenderer.js b/src/ol/renderer/dom/domtilelayerrenderer.js
index fd88d8cdd9..b04feb155c 100644
--- a/src/ol/renderer/dom/domtilelayerrenderer.js
+++ b/src/ol/renderer/dom/domtilelayerrenderer.js
@@ -98,6 +98,7 @@ ol.renderer.dom.TileLayer.prototype.prepareFrame =
if (goog.isNull(tileGrid)) {
tileGrid = ol.tilegrid.getForProjection(projection);
}
+ var tileGutter = tileSource.getGutter();
var z = tileGrid.getZForResolution(view2DState.resolution);
var tileResolution = tileGrid.getResolution(z);
var center = view2DState.center;
@@ -186,7 +187,7 @@ ol.renderer.dom.TileLayer.prototype.prepareFrame =
}
tilesToDraw = tilesToDrawByZ[tileLayerZKey];
for (tileCoordKey in tilesToDraw) {
- tileLayerZ.addTile(tilesToDraw[tileCoordKey]);
+ tileLayerZ.addTile(tilesToDraw[tileCoordKey], tileGutter);
}
tileLayerZ.finalizeAddTiles();
}
@@ -317,8 +318,9 @@ ol.renderer.dom.TileLayerZ_ = function(tileGrid, tileCoordOrigin) {
/**
* @param {ol.Tile} tile Tile.
+ * @param {number} tileGutter Tile gutter.
*/
-ol.renderer.dom.TileLayerZ_.prototype.addTile = function(tile) {
+ol.renderer.dom.TileLayerZ_.prototype.addTile = function(tile, tileGutter) {
var tileCoord = tile.tileCoord;
goog.asserts.assert(tileCoord.z == this.tileCoordOrigin_.z);
var tileCoordKey = tileCoord.toString();
@@ -327,20 +329,36 @@ ol.renderer.dom.TileLayerZ_.prototype.addTile = function(tile) {
}
var tileSize = this.tileGrid_.getTileSize(tileCoord.z);
var image = tile.getImage(this);
- var style = image.style;
- // Bootstrap sets the style max-width: 100% for all images, which breaks
- // prevents the tile from being displayed in FireFox. Workaround by
- // overriding the max-width style.
- style.maxWidth = 'none';
- style.position = 'absolute';
- style.left =
+ var imageStyle = image.style;
+ // Bootstrap sets the style max-width: 100% for all images, which
+ // prevents the tile from being displayed in FireFox. Workaround
+ // by overriding the max-width style.
+ imageStyle.maxWidth = 'none';
+ var tileElement;
+ var tileElementStyle;
+ if (tileGutter > 0) {
+ tileElement = goog.dom.createElement(goog.dom.TagName.DIV);
+ tileElementStyle = tileElement.style;
+ tileElementStyle.overflow = 'hidden';
+ tileElementStyle.width = tileSize[0] + 'px';
+ tileElementStyle.height = tileSize[1] + 'px';
+ imageStyle.position = 'absolute';
+ imageStyle.left = -tileGutter + 'px';
+ imageStyle.top = -tileGutter + 'px';
+ goog.dom.appendChild(tileElement, image);
+ } else {
+ tileElement = image;
+ tileElementStyle = imageStyle;
+ }
+ tileElementStyle.position = 'absolute';
+ tileElementStyle.left =
((tileCoord.x - this.tileCoordOrigin_.x) * tileSize[0]) + 'px';
- style.top =
+ tileElementStyle.top =
((this.tileCoordOrigin_.y - tileCoord.y) * tileSize[1]) + 'px';
if (goog.isNull(this.documentFragment_)) {
this.documentFragment_ = document.createDocumentFragment();
}
- goog.dom.appendChild(this.documentFragment_, image);
+ goog.dom.appendChild(this.documentFragment_, tileElement);
this.tiles_[tileCoordKey] = tile;
};
diff --git a/src/ol/renderer/webgl/webglmaprenderer.js b/src/ol/renderer/webgl/webglmaprenderer.js
index f940390277..9dea7d1b06 100644
--- a/src/ol/renderer/webgl/webglmaprenderer.js
+++ b/src/ol/renderer/webgl/webglmaprenderer.js
@@ -66,6 +66,26 @@ ol.renderer.webgl.Map = function(container, map) {
this.canvas_.className = ol.css.CLASS_UNSELECTABLE;
goog.dom.insertChildAt(container, this.canvas_, 0);
+ /**
+ * @private
+ * @type {HTMLCanvasElement}
+ */
+ this.clipTileCanvas_ = /** @type {HTMLCanvasElement} */
+ (goog.dom.createElement(goog.dom.TagName.CANVAS));
+
+ /**
+ * @private
+ * @type {ol.Size}
+ */
+ this.clipTileCanvasSize_ = [0, 0];
+
+ /**
+ * @private
+ * @type {CanvasRenderingContext2D}
+ */
+ this.clipTileContext_ = /** @type {CanvasRenderingContext2D} */
+ (this.clipTileCanvas_.getContext('2d'));
+
/**
* @private
* @type {boolean}
@@ -147,9 +167,14 @@ ol.renderer.webgl.Map = function(container, map) {
function(map, frameState) {
if (!this.tileTextureQueue_.isEmpty()) {
this.tileTextureQueue_.reprioritize();
- var tile =
- /** @type {ol.Tile} */ (this.tileTextureQueue_.dequeue()[0]);
- this.bindTileTexture(tile, goog.webgl.LINEAR, goog.webgl.LINEAR);
+ var element = this.tileTextureQueue_.dequeue();
+ var tile = /** @type {ol.Tile} */ (element[0]);
+ var tileWidth = /** @type {number} */ (element[3]);
+ var tileHeight = /** @type {number} */ (element[4]);
+ var tileGutter = /** @type {number} */ (element[5]);
+ this.bindTileTexture(tile,
+ tileWidth, tileHeight, tileGutter,
+ goog.webgl.LINEAR, goog.webgl.LINEAR);
}
}, this);
@@ -167,11 +192,14 @@ goog.inherits(ol.renderer.webgl.Map, ol.renderer.Map);
/**
* @param {ol.Tile} tile Tile.
+ * @param {number} tileWidth Tile width.
+ * @param {number} tileHeight Tile height.
+ * @param {number} tileGutter Tile gutter.
* @param {number} magFilter Mag filter.
* @param {number} minFilter Min filter.
*/
ol.renderer.webgl.Map.prototype.bindTileTexture =
- function(tile, magFilter, minFilter) {
+ function(tile, tileWidth, tileHeight, tileGutter, magFilter, minFilter) {
var gl = this.getGL();
var tileKey = tile.getKey();
if (this.textureCache_.containsKey(tileKey)) {
@@ -191,8 +219,29 @@ ol.renderer.webgl.Map.prototype.bindTileTexture =
} else {
var texture = gl.createTexture();
gl.bindTexture(goog.webgl.TEXTURE_2D, texture);
- gl.texImage2D(goog.webgl.TEXTURE_2D, 0, goog.webgl.RGBA, goog.webgl.RGBA,
- goog.webgl.UNSIGNED_BYTE, tile.getImage());
+ if (tileGutter > 0) {
+ var clipTileCanvas = this.clipTileCanvas_;
+ var clipTileCanvasSize = this.clipTileCanvasSize_;
+ var clipTileContext = this.clipTileContext_;
+ if (clipTileCanvasSize[0] != tileWidth ||
+ clipTileCanvasSize[1] != tileHeight) {
+ clipTileCanvas.width = tileWidth;
+ clipTileCanvas.height = tileHeight;
+ clipTileCanvasSize[0] = tileWidth;
+ clipTileCanvasSize[1] = tileHeight;
+ } else {
+ clipTileContext.clearRect(0, 0, tileWidth, tileHeight);
+ }
+ clipTileContext.drawImage(tile.getImage(), tileGutter, tileGutter,
+ tileWidth, tileHeight, 0, 0, tileWidth, tileHeight);
+ gl.texImage2D(goog.webgl.TEXTURE_2D, 0,
+ goog.webgl.RGBA, goog.webgl.RGBA,
+ goog.webgl.UNSIGNED_BYTE, clipTileCanvas);
+ } else {
+ gl.texImage2D(goog.webgl.TEXTURE_2D, 0,
+ goog.webgl.RGBA, goog.webgl.RGBA,
+ goog.webgl.UNSIGNED_BYTE, tile.getImage());
+ }
gl.texParameteri(
goog.webgl.TEXTURE_2D, goog.webgl.TEXTURE_MAG_FILTER, magFilter);
gl.texParameteri(
diff --git a/src/ol/renderer/webgl/webgltilelayerrenderer.js b/src/ol/renderer/webgl/webgltilelayerrenderer.js
index 5db387cbde..1221abb31d 100644
--- a/src/ol/renderer/webgl/webgltilelayerrenderer.js
+++ b/src/ol/renderer/webgl/webgltilelayerrenderer.js
@@ -132,6 +132,10 @@ ol.renderer.webgl.TileLayer.prototype.prepareFrame =
}
var z = tileGrid.getZForResolution(view2DState.resolution);
var tileResolution = tileGrid.getResolution(z);
+
+ var tileSize = tileGrid.getTileSize(z);
+ var tileGutter = tileSource.getGutter();
+
var center = view2DState.center;
var extent;
if (tileResolution == view2DState.resolution) {
@@ -152,7 +156,6 @@ ol.renderer.webgl.TileLayer.prototype.prepareFrame =
} else {
var tileRangeSize = tileRange.getSize();
- var tileSize = tileGrid.getTileSize(z);
var maxDimension = Math.max(
tileRangeSize[0] * tileSize[0],
@@ -257,7 +260,9 @@ ol.renderer.webgl.TileLayer.prototype.prepareFrame =
framebufferExtentDimension - 1;
goog.vec.Vec4.setFromValues(u_tileOffset, sx, sy, tx, ty);
gl.uniform4fv(this.locations_.u_tileOffset, u_tileOffset);
- mapRenderer.bindTileTexture(tile, goog.webgl.LINEAR, goog.webgl.LINEAR);
+ mapRenderer.bindTileTexture(tile,
+ tileSize[0], tileSize[1], tileGutter,
+ goog.webgl.LINEAR, goog.webgl.LINEAR);
gl.drawArrays(goog.webgl.TRIANGLE_STRIP, 0, 4);
}
}
@@ -290,7 +295,8 @@ ol.renderer.webgl.TileLayer.prototype.prepareFrame =
tileTextureQueue.enqueue([
tile,
tileGrid.getTileCoordCenter(tile.tileCoord),
- tileGrid.getResolution(tile.tileCoord.z)
+ tileGrid.getResolution(tile.tileCoord.z),
+ tileSize[0], tileSize[1], tileGutter
]);
}
}, this);
diff --git a/src/ol/source/bingmapssource.exports b/src/ol/source/bingmapssource.exports
index 7ce0e42656..5f7481f7c9 100644
--- a/src/ol/source/bingmapssource.exports
+++ b/src/ol/source/bingmapssource.exports
@@ -1,2 +1,2 @@
-@exportClass ol.source.BingMaps ol.source.BingMapsOptions
+@exportSymbol ol.source.BingMaps
@exportProperty ol.source.BingMaps.TOS_ATTRIBUTION
diff --git a/src/ol/source/bingmapssource.js b/src/ol/source/bingmapssource.js
index 81820341cb..975c471d9f 100644
--- a/src/ol/source/bingmapssource.js
+++ b/src/ol/source/bingmapssource.js
@@ -18,7 +18,7 @@ goog.require('ol.tilegrid.XYZ');
/**
* @constructor
* @extends {ol.source.TileImage}
- * @param {ol.source.BingMapsOptions} options Bing Maps options.
+ * @param {olx.source.BingMapsOptions} options Bing Maps options.
* @todo stability experimental
*/
ol.source.BingMaps = function(options) {
diff --git a/src/ol/source/debugtilesource.exports b/src/ol/source/debugtilesource.exports
index cc26dab6ad..35fcf0c02e 100644
--- a/src/ol/source/debugtilesource.exports
+++ b/src/ol/source/debugtilesource.exports
@@ -1 +1 @@
-@exportClass ol.source.TileDebug ol.source.TileDebugOptions
+@exportSymbol ol.source.TileDebug
diff --git a/src/ol/source/debugtilesource.js b/src/ol/source/debugtilesource.js
index 32c7a1905f..f0e58f115a 100644
--- a/src/ol/source/debugtilesource.js
+++ b/src/ol/source/debugtilesource.js
@@ -85,7 +85,7 @@ ol.DebugTile_.prototype.getImage = function(opt_context) {
/**
* @constructor
* @extends {ol.source.Tile}
- * @param {ol.source.TileDebugOptions} options Debug tile options.
+ * @param {olx.source.TileDebugOptions} options Debug tile options.
* @todo stability experimental
*/
ol.source.TileDebug = function(options) {
diff --git a/src/ol/source/geojsonsource.exports b/src/ol/source/geojsonsource.exports
index abf4c9f35e..52f49004f2 100644
--- a/src/ol/source/geojsonsource.exports
+++ b/src/ol/source/geojsonsource.exports
@@ -1 +1 @@
-@exportClass ol.source.GeoJSON ol.source.GeoJSONOptions
+@exportSymbol ol.source.GeoJSON
diff --git a/src/ol/source/geojsonsource.js b/src/ol/source/geojsonsource.js
index 5e0613faa3..94da078387 100644
--- a/src/ol/source/geojsonsource.js
+++ b/src/ol/source/geojsonsource.js
@@ -8,7 +8,7 @@ goog.require('ol.source.VectorFile');
/**
* @constructor
* @extends {ol.source.VectorFile}
- * @param {ol.source.GeoJSONOptions=} opt_options Options.
+ * @param {olx.source.GeoJSONOptions=} opt_options Options.
*/
ol.source.GeoJSON = function(opt_options) {
diff --git a/src/ol/source/imagestaticsource.exports b/src/ol/source/imagestaticsource.exports
index 4968e8f6f0..b07c04a34a 100644
--- a/src/ol/source/imagestaticsource.exports
+++ b/src/ol/source/imagestaticsource.exports
@@ -1 +1 @@
-@exportClass ol.source.ImageStatic ol.source.ImageStaticOptions
+@exportSymbol ol.source.ImageStatic
diff --git a/src/ol/source/imagestaticsource.js b/src/ol/source/imagestaticsource.js
index 8a3cae06ca..43ce4f62bd 100644
--- a/src/ol/source/imagestaticsource.js
+++ b/src/ol/source/imagestaticsource.js
@@ -11,7 +11,7 @@ goog.require('ol.source.Image');
/**
* @constructor
* @extends {ol.source.Image}
- * @param {ol.source.ImageStaticOptions} options Options.
+ * @param {olx.source.ImageStaticOptions} options Options.
* @todo stability experimental
*/
ol.source.ImageStatic = function(options) {
diff --git a/src/ol/source/imagewmssource.exports b/src/ol/source/imagewmssource.exports
index 0396ea145e..afd33970c9 100644
--- a/src/ol/source/imagewmssource.exports
+++ b/src/ol/source/imagewmssource.exports
@@ -1,3 +1,3 @@
-@exportClass ol.source.ImageWMS ol.source.ImageWMSOptions
+@exportSymbol ol.source.ImageWMS
@exportProperty ol.source.ImageWMS.prototype.getParams
@exportProperty ol.source.ImageWMS.prototype.updateParams
diff --git a/src/ol/source/imagewmssource.js b/src/ol/source/imagewmssource.js
index af05589762..3a123f93b8 100644
--- a/src/ol/source/imagewmssource.js
+++ b/src/ol/source/imagewmssource.js
@@ -13,7 +13,7 @@ goog.require('ol.source.wms');
/**
* @constructor
* @extends {ol.source.Image}
- * @param {ol.source.ImageWMSOptions} options Options.
+ * @param {olx.source.ImageWMSOptions} options Options.
* @todo stability experimental
*/
ol.source.ImageWMS = function(options) {
diff --git a/src/ol/source/mapguidesource.js b/src/ol/source/mapguidesource.js
index 974c69b1bc..a8ddc8484b 100644
--- a/src/ol/source/mapguidesource.js
+++ b/src/ol/source/mapguidesource.js
@@ -11,7 +11,7 @@ goog.require('ol.source.Image');
/**
* @constructor
* @extends {ol.source.Image}
- * @param {ol.source.MapGuideOptions} options Options.
+ * @param {olx.source.MapGuideOptions} options Options.
*/
ol.source.MapGuide = function(options) {
diff --git a/src/ol/source/mapquestsource.js b/src/ol/source/mapquestsource.js
index 126072087a..68e11dc08a 100644
--- a/src/ol/source/mapquestsource.js
+++ b/src/ol/source/mapquestsource.js
@@ -10,7 +10,7 @@ goog.require('ol.source.XYZ');
/**
* @constructor
* @extends {ol.source.XYZ}
- * @param {ol.source.MapQuestOptions=} opt_options MapQuest options.
+ * @param {olx.source.MapQuestOptions=} opt_options MapQuest options.
* @todo stability experimental
*/
ol.source.MapQuestOSM = function(opt_options) {
@@ -43,7 +43,7 @@ goog.inherits(ol.source.MapQuestOSM, ol.source.XYZ);
/**
* @constructor
* @extends {ol.source.XYZ}
- * @param {ol.source.MapQuestOptions=} opt_options MapQuest options.
+ * @param {olx.source.MapQuestOptions=} opt_options MapQuest options.
* @todo stability experimental
*/
ol.source.MapQuestOpenAerial = function(opt_options) {
diff --git a/src/ol/source/osmsource.js b/src/ol/source/osmsource.js
index 92e13ec6b8..63d57086d9 100644
--- a/src/ol/source/osmsource.js
+++ b/src/ol/source/osmsource.js
@@ -8,7 +8,7 @@ goog.require('ol.source.XYZ');
/**
* @constructor
* @extends {ol.source.XYZ}
- * @param {ol.source.OSMOptions=} opt_options Open Street Map options.
+ * @param {olx.source.OSMOptions=} opt_options Open Street Map options.
* @todo stability experimental
*/
ol.source.OSM = function(opt_options) {
diff --git a/src/ol/source/stamensource.exports b/src/ol/source/stamensource.exports
index 61702ead25..697330485e 100644
--- a/src/ol/source/stamensource.exports
+++ b/src/ol/source/stamensource.exports
@@ -1 +1 @@
-@exportClass ol.source.Stamen ol.source.StamenOptions
+@exportSymbol ol.source.Stamen
diff --git a/src/ol/source/stamensource.js b/src/ol/source/stamensource.js
index 34509ac611..6a269206f7 100644
--- a/src/ol/source/stamensource.js
+++ b/src/ol/source/stamensource.js
@@ -80,7 +80,7 @@ ol.source.StamenProviderConfig = {
/**
* @constructor
* @extends {ol.source.XYZ}
- * @param {ol.source.StamenOptions} options Stamen options.
+ * @param {olx.source.StamenOptions} options Stamen options.
* @todo stability experimental
*/
ol.source.Stamen = function(options) {
diff --git a/src/ol/source/tilejsonsource.exports b/src/ol/source/tilejsonsource.exports
index e05dca5e1d..56b3f56285 100644
--- a/src/ol/source/tilejsonsource.exports
+++ b/src/ol/source/tilejsonsource.exports
@@ -1 +1 @@
-@exportClass ol.source.TileJSON ol.source.TileJSONOptions
+@exportSymbol ol.source.TileJSON
diff --git a/src/ol/source/tilejsonsource.js b/src/ol/source/tilejsonsource.js
index 81e57f6098..2f3768d1d3 100644
--- a/src/ol/source/tilejsonsource.js
+++ b/src/ol/source/tilejsonsource.js
@@ -40,7 +40,7 @@ goog.exportSymbol('grid', grid);
/**
* @constructor
* @extends {ol.source.TileImage}
- * @param {ol.source.TileJSONOptions} options TileJSON options.
+ * @param {olx.source.TileJSONOptions} options TileJSON options.
* @todo stability experimental
*/
ol.source.TileJSON = function(options) {
diff --git a/src/ol/source/tilesource.js b/src/ol/source/tilesource.js
index e40c93d937..541659d2d2 100644
--- a/src/ol/source/tilesource.js
+++ b/src/ol/source/tilesource.js
@@ -106,6 +106,14 @@ ol.source.Tile.prototype.findLoadedTiles = function(loadedTilesByZ,
};
+/**
+ * @return {number} Gutter.
+ */
+ol.source.Tile.prototype.getGutter = function() {
+ return 0;
+};
+
+
/**
* @param {number} z Z.
* @param {number} x X.
diff --git a/src/ol/source/tilewmssource.exports b/src/ol/source/tilewmssource.exports
index 94fb2c22b3..e9049c25f3 100644
--- a/src/ol/source/tilewmssource.exports
+++ b/src/ol/source/tilewmssource.exports
@@ -1,3 +1,3 @@
-@exportClass ol.source.TileWMS ol.source.TileWMSOptions
+@exportSymbol ol.source.TileWMS
@exportProperty ol.source.TileWMS.prototype.getParams
@exportProperty ol.source.TileWMS.prototype.updateParams
diff --git a/src/ol/source/tilewmssource.js b/src/ol/source/tilewmssource.js
index aea2b21084..6eed73c25c 100644
--- a/src/ol/source/tilewmssource.js
+++ b/src/ol/source/tilewmssource.js
@@ -16,7 +16,7 @@ goog.require('ol.source.wms');
/**
* @constructor
* @extends {ol.source.TileImage}
- * @param {ol.source.TileWMSOptions} options Tile WMS options.
+ * @param {olx.source.TileWMSOptions} options Tile WMS options.
* @todo stability experimental
*/
ol.source.TileWMS = function(options) {
@@ -32,6 +32,12 @@ ol.source.TileWMS = function(options) {
urls = ol.TileUrlFunction.expandUrl(options.url);
}
+ /**
+ * @private
+ * @type {number}
+ */
+ this.gutter_ = goog.isDef(options.gutter) ? options.gutter : 0;
+
/**
* @private
* @type {Object}
@@ -49,7 +55,7 @@ ol.source.TileWMS = function(options) {
var tileUrlFunctions = goog.array.map(
urls, function(url) {
return ol.TileUrlFunction.createFromParamsFunction(
- url, this.params_, ol.source.wms.getUrl);
+ url, this.params_, this.gutter_, ol.source.wms.getUrl);
}, this);
tileUrlFunction = ol.TileUrlFunction.createFromTileUrlFunctions(
tileUrlFunctions);
@@ -106,6 +112,14 @@ ol.source.TileWMS = function(options) {
goog.inherits(ol.source.TileWMS, ol.source.TileImage);
+/**
+ * @inheritDoc
+ */
+ol.source.TileWMS.prototype.getGutter = function() {
+ return this.gutter_;
+};
+
+
/**
* @inheritDoc
*/
diff --git a/src/ol/source/vectorfilesource.exports b/src/ol/source/vectorfilesource.exports
index 285db94e72..acd6140571 100644
--- a/src/ol/source/vectorfilesource.exports
+++ b/src/ol/source/vectorfilesource.exports
@@ -1 +1 @@
-@exportClass ol.source.VectorFile ol.source.VectorFileOptions
+@exportSymbol ol.source.VectorFile
diff --git a/src/ol/source/vectorfilesource.js b/src/ol/source/vectorfilesource.js
index 7d4493dec6..8e82084814 100644
--- a/src/ol/source/vectorfilesource.js
+++ b/src/ol/source/vectorfilesource.js
@@ -14,7 +14,7 @@ goog.require('ol.source.Vector');
/**
* @constructor
* @extends {ol.source.Vector}
- * @param {ol.source.VectorFileOptions=} opt_options Options.
+ * @param {olx.source.VectorFileOptions=} opt_options Options.
*/
ol.source.VectorFile = function(opt_options) {
diff --git a/src/ol/source/vectorsource.exports b/src/ol/source/vectorsource.exports
index 8632fdab66..cc76d95621 100644
--- a/src/ol/source/vectorsource.exports
+++ b/src/ol/source/vectorsource.exports
@@ -1,4 +1,4 @@
-@exportClass ol.source.Vector ol.source.VectorOptions
+@exportSymbol ol.source.Vector
@exportProperty ol.source.Vector.prototype.addFeature
@exportProperty ol.source.Vector.prototype.getClosestFeatureToCoordinate
@exportProperty ol.source.Vector.prototype.forEachFeature
diff --git a/src/ol/source/vectorsource.js b/src/ol/source/vectorsource.js
index 49c3edf8c9..776dd2f7b2 100644
--- a/src/ol/source/vectorsource.js
+++ b/src/ol/source/vectorsource.js
@@ -27,7 +27,8 @@ ol.source.VectorEventType = {
/**
* @constructor
* @extends {ol.source.Source}
- * @param {ol.source.VectorOptions=} opt_options Options.
+ * @param {olx.source.VectorOptions=} opt_options Vector source options.
+ * @todo stability experimental
*/
ol.source.Vector = function(opt_options) {
diff --git a/src/ol/source/wmtssource.exports b/src/ol/source/wmtssource.exports
index f29f7d0ec5..a81ed65df0 100644
--- a/src/ol/source/wmtssource.exports
+++ b/src/ol/source/wmtssource.exports
@@ -1,4 +1,4 @@
-@exportClass ol.source.WMTS ol.source.WMTSOptions
+@exportSymbol ol.source.WMTS
@exportProperty ol.source.WMTS.prototype.getDimensions
@exportProperty ol.source.WMTS.prototype.updateDimensions
@exportSymbol ol.source.WMTS.optionsFromCapabilities
diff --git a/src/ol/source/wmtssource.js b/src/ol/source/wmtssource.js
index 7136aaa3d2..15e2aae7bb 100644
--- a/src/ol/source/wmtssource.js
+++ b/src/ol/source/wmtssource.js
@@ -28,7 +28,7 @@ ol.source.WMTSRequestEncoding = {
/**
* @constructor
* @extends {ol.source.TileImage}
- * @param {ol.source.WMTSOptions} options WMTS options.
+ * @param {olx.source.WMTSOptions} options WMTS options.
* @todo stability experimental
*/
ol.source.WMTS = function(options) {
@@ -237,7 +237,7 @@ ol.source.WMTS.prototype.updateDimensions = function(dimensions) {
/**
* @param {Object} wmtsCap An object representing the capabilities document.
* @param {string} layer The layer identifier.
- * @return {ol.source.WMTSOptions} WMTS source options object.
+ * @return {olx.source.WMTSOptions} WMTS source options object.
* @todo stability experimental
*/
ol.source.WMTS.optionsFromCapabilities = function(wmtsCap, layer) {
diff --git a/src/ol/source/xyzsource.exports b/src/ol/source/xyzsource.exports
index 4623a4a9ec..3968a05264 100644
--- a/src/ol/source/xyzsource.exports
+++ b/src/ol/source/xyzsource.exports
@@ -1,2 +1,2 @@
-@exportClass ol.source.XYZ ol.source.XYZOptions
+@exportSymbol ol.source.XYZ
@exportProperty ol.source.XYZ.prototype.setUrl
diff --git a/src/ol/source/xyzsource.js b/src/ol/source/xyzsource.js
index baf5b67b3a..b41ff92de5 100644
--- a/src/ol/source/xyzsource.js
+++ b/src/ol/source/xyzsource.js
@@ -12,7 +12,7 @@ goog.require('ol.tilegrid.XYZ');
/**
* @constructor
* @extends {ol.source.TileImage}
- * @param {ol.source.XYZOptions} options XYZ options.
+ * @param {olx.source.XYZOptions} options XYZ options.
* @todo stability experimental
*/
ol.source.XYZ = function(options) {
diff --git a/src/ol/structs/rbush.js b/src/ol/structs/rbush.js
index 85cefc282d..8f45d27cb6 100644
--- a/src/ol/structs/rbush.js
+++ b/src/ol/structs/rbush.js
@@ -539,7 +539,7 @@ ol.structs.RBush.prototype.getKey_ = function(value) {
*/
ol.structs.RBush.prototype.insert = function(extent, value) {
if (goog.DEBUG && this.readers_) {
- throw Error('cannot insert value while reading');
+ throw new Error('cannot insert value while reading');
}
var key = this.getKey_(value);
goog.asserts.assert(!this.valueExtent_.hasOwnProperty(key));
@@ -589,7 +589,7 @@ ol.structs.RBush.prototype.isEmpty = function() {
*/
ol.structs.RBush.prototype.remove = function(value) {
if (goog.DEBUG && this.readers_) {
- throw Error('cannot remove value while reading');
+ throw new Error('cannot remove value while reading');
}
var key = this.getKey_(value);
goog.asserts.assert(this.valueExtent_.hasOwnProperty(key));
@@ -687,7 +687,7 @@ ol.structs.RBush.prototype.splitRoot_ = function(node1, node2) {
*/
ol.structs.RBush.prototype.update = function(extent, value) {
if (goog.DEBUG && this.readers_) {
- throw Error('cannot update value while reading');
+ throw new Error('cannot update value while reading');
}
var key = this.getKey_(value);
var currentExtent = this.valueExtent_[key];
diff --git a/src/ol/style/fillstyle.exports b/src/ol/style/fillstyle.exports
index 9dd7392396..4c10b8d9ca 100644
--- a/src/ol/style/fillstyle.exports
+++ b/src/ol/style/fillstyle.exports
@@ -1 +1 @@
-@exportClass ol.style.Fill ol.style.FillOptions
+@exportSymbol ol.style.Fill
diff --git a/src/ol/style/fillstyle.js b/src/ol/style/fillstyle.js
index 2d9455a920..438af2e496 100644
--- a/src/ol/style/fillstyle.js
+++ b/src/ol/style/fillstyle.js
@@ -6,7 +6,7 @@ goog.require('ol.color');
/**
* @constructor
- * @param {ol.style.FillOptions} options Options.
+ * @param {olx.style.FillOptions} options Options.
*/
ol.style.Fill = function(options) {
diff --git a/src/ol/style/imagestyle.exports b/src/ol/style/imagestyle.exports
index fb703b2c38..070870ecef 100644
--- a/src/ol/style/imagestyle.exports
+++ b/src/ol/style/imagestyle.exports
@@ -1 +1 @@
-@exportClass ol.style.Image ol.style.ImageOptions
+@exportSymbol ol.style.Image
diff --git a/src/ol/style/imagestyle.js b/src/ol/style/imagestyle.js
index 2320f78ed0..4322dcf9a9 100644
--- a/src/ol/style/imagestyle.js
+++ b/src/ol/style/imagestyle.js
@@ -24,7 +24,7 @@ ol.style.ImageState = {
/**
* @constructor
- * @param {ol.style.ImageOptions} options Options.
+ * @param {olx.style.ImageOptions} options Options.
* @extends {goog.events.EventTarget}
*/
ol.style.Image = function(options) {
diff --git a/src/ol/style/strokestyle.exports b/src/ol/style/strokestyle.exports
index 8fe1512b95..20bb65ff96 100644
--- a/src/ol/style/strokestyle.exports
+++ b/src/ol/style/strokestyle.exports
@@ -1 +1 @@
-@exportClass ol.style.Stroke ol.style.StrokeOptions
+@exportSymbol ol.style.Stroke
diff --git a/src/ol/style/strokestyle.js b/src/ol/style/strokestyle.js
index 0f0021670d..fc5575eff1 100644
--- a/src/ol/style/strokestyle.js
+++ b/src/ol/style/strokestyle.js
@@ -6,7 +6,7 @@ goog.require('ol.color');
/**
* @constructor
- * @param {ol.style.StrokeOptions} options Options.
+ * @param {olx.style.StrokeOptions} options Options.
*/
ol.style.Stroke = function(options) {
diff --git a/src/ol/style/style.exports b/src/ol/style/style.exports
index ccd640f5d9..c6eea6e449 100644
--- a/src/ol/style/style.exports
+++ b/src/ol/style/style.exports
@@ -1 +1 @@
-@exportClass ol.style.Style ol.style.StyleOptions
+@exportSymbol ol.style.Style
diff --git a/src/ol/style/style.js b/src/ol/style/style.js
index edf130ced6..d6e26decac 100644
--- a/src/ol/style/style.js
+++ b/src/ol/style/style.js
@@ -8,7 +8,8 @@ goog.require('ol.style.Image');
/**
* @constructor
- * @param {ol.style.StyleOptions} options Options.
+ * @param {olx.style.StyleOptions} options Style options.
+ * @todo stability experimental
*/
ol.style.Style = function(options) {
diff --git a/src/ol/style/textstyle.exports b/src/ol/style/textstyle.exports
index 989337adcf..8a516470c1 100644
--- a/src/ol/style/textstyle.exports
+++ b/src/ol/style/textstyle.exports
@@ -1 +1 @@
-@exportClass ol.style.Text ol.style.TextOptions
+@exportSymbol ol.style.Text
diff --git a/src/ol/style/textstyle.js b/src/ol/style/textstyle.js
index a3ce1038fb..6e6d6b9b6c 100644
--- a/src/ol/style/textstyle.js
+++ b/src/ol/style/textstyle.js
@@ -4,7 +4,7 @@ goog.provide('ol.style.Text');
/**
* @constructor
- * @param {ol.style.TextOptions} options Options.
+ * @param {olx.style.TextOptions} options Options.
*/
ol.style.Text = function(options) {
diff --git a/src/ol/tilegrid/tilegrid.exports b/src/ol/tilegrid/tilegrid.exports
index fc8f6db1a0..5e1039d79f 100644
--- a/src/ol/tilegrid/tilegrid.exports
+++ b/src/ol/tilegrid/tilegrid.exports
@@ -1,4 +1,4 @@
-@exportClass ol.tilegrid.TileGrid ol.tilegrid.TileGridOptions
+@exportSymbol ol.tilegrid.TileGrid
@exportProperty ol.tilegrid.TileGrid.prototype.getMinZoom
@exportProperty ol.tilegrid.TileGrid.prototype.getOrigin
@exportProperty ol.tilegrid.TileGrid.prototype.getResolutions
diff --git a/src/ol/tilegrid/tilegrid.js b/src/ol/tilegrid/tilegrid.js
index f39badb2fa..36950abc08 100644
--- a/src/ol/tilegrid/tilegrid.js
+++ b/src/ol/tilegrid/tilegrid.js
@@ -27,7 +27,7 @@ ol.DEFAULT_MAX_ZOOM = 42;
/**
* @constructor
- * @param {ol.tilegrid.TileGridOptions} options Tile grid options.
+ * @param {olx.tilegrid.TileGridOptions} options Tile grid options.
* @struct
* @todo stability experimental
*/
diff --git a/src/ol/tilegrid/wmtstilegrid.exports b/src/ol/tilegrid/wmtstilegrid.exports
index 73991a2dbe..654b18d9c8 100644
--- a/src/ol/tilegrid/wmtstilegrid.exports
+++ b/src/ol/tilegrid/wmtstilegrid.exports
@@ -1,2 +1,2 @@
-@exportClass ol.tilegrid.WMTS ol.tilegrid.WMTSOptions
+@exportSymbol ol.tilegrid.WMTS
@exportProperty ol.tilegrid.WMTS.prototype.getMatrixIds
diff --git a/src/ol/tilegrid/wmtstilegrid.js b/src/ol/tilegrid/wmtstilegrid.js
index d0bdcfffe9..e91427a43a 100644
--- a/src/ol/tilegrid/wmtstilegrid.js
+++ b/src/ol/tilegrid/wmtstilegrid.js
@@ -10,7 +10,7 @@ goog.require('ol.tilegrid.TileGrid');
/**
* @constructor
* @extends {ol.tilegrid.TileGrid}
- * @param {ol.tilegrid.WMTSOptions} options WMTS options.
+ * @param {olx.tilegrid.WMTSOptions} options WMTS options.
* @struct
* @todo stability experimental
*/
diff --git a/src/ol/tilegrid/xyztilegrid.exports b/src/ol/tilegrid/xyztilegrid.exports
index dd5b52245c..f05509aca9 100644
--- a/src/ol/tilegrid/xyztilegrid.exports
+++ b/src/ol/tilegrid/xyztilegrid.exports
@@ -1 +1 @@
-@exportClass ol.tilegrid.XYZ ol.tilegrid.XYZOptions
+@exportSymbol ol.tilegrid.XYZ
diff --git a/src/ol/tilegrid/xyztilegrid.js b/src/ol/tilegrid/xyztilegrid.js
index 7aaedc09cd..239e282bc8 100644
--- a/src/ol/tilegrid/xyztilegrid.js
+++ b/src/ol/tilegrid/xyztilegrid.js
@@ -12,7 +12,7 @@ goog.require('ol.tilegrid.TileGrid');
/**
* @constructor
* @extends {ol.tilegrid.TileGrid}
- * @param {ol.tilegrid.XYZOptions} options XYZ options.
+ * @param {olx.tilegrid.XYZOptions} options XYZ options.
* @struct
* @todo stability experimental
*/
diff --git a/src/ol/tileurlfunction.js b/src/ol/tileurlfunction.js
index c883fbfe16..008e609f39 100644
--- a/src/ol/tileurlfunction.js
+++ b/src/ol/tileurlfunction.js
@@ -84,14 +84,16 @@ ol.TileUrlFunction.createFromTileUrlFunctions = function(tileUrlFunctions) {
/**
* @param {string} baseUrl Base URL (may have query data).
- * @param {Object.} params to encode in the URL.
+ * @param {Object.} params Params to encode in the URL.
+ * @param {number} gutter Gutter value.
* @param {function(this: ol.source.TileImage, string, Object.,
* ol.Extent, ol.Size, ol.proj.Projection)} paramsFunction params function.
* @return {ol.TileUrlFunctionType} Tile URL function.
*/
ol.TileUrlFunction.createFromParamsFunction =
- function(baseUrl, params, paramsFunction) {
+ function(baseUrl, params, gutter, paramsFunction) {
var tmpExtent = ol.extent.createEmpty();
+ var tmpSize = [0, 0];
return (
/**
* @this {ol.source.TileImage}
@@ -107,10 +109,14 @@ ol.TileUrlFunction.createFromParamsFunction =
if (goog.isNull(tileGrid)) {
tileGrid = ol.tilegrid.getForProjection(projection);
}
- var size = tileGrid.getTileSize(tileCoord.z);
+ var tileResolution = tileGrid.getResolution(tileCoord.z);
+ var tileSize = tileGrid.getTileSize(tileCoord.z);
+ tmpSize[0] = tileSize[0] + (2 * gutter);
+ tmpSize[1] = tileSize[1] + (2 * gutter);
var extent = tileGrid.getTileCoordExtent(tileCoord, tmpExtent);
+ ol.extent.buffer(extent, tileResolution * gutter);
return paramsFunction.call(this, baseUrl, params,
- extent, size, projection);
+ extent, tmpSize, projection);
}
});
};
diff --git a/src/ol/view2d.exports b/src/ol/view2d.exports
index 9065c75a51..85318dd373 100644
--- a/src/ol/view2d.exports
+++ b/src/ol/view2d.exports
@@ -1,4 +1,4 @@
-@exportClass ol.View2D ol.View2DOptions
+@exportSymbol ol.View2D
@exportProperty ol.View2D.prototype.calculateExtent
@exportProperty ol.View2D.prototype.constrainResolution
@exportProperty ol.View2D.prototype.constrainRotation
diff --git a/src/ol/view2d.js b/src/ol/view2d.js
index e4716f5726..e2c07f90b4 100644
--- a/src/ol/view2d.js
+++ b/src/ol/view2d.js
@@ -84,7 +84,7 @@ ol.View2DProperty = {
* @implements {ol.IView2D}
* @implements {ol.IView3D}
* @extends {ol.View}
- * @param {ol.View2DOptions=} opt_options View2D options.
+ * @param {olx.View2DOptions=} opt_options View2D options.
* @todo stability experimental
* @todo observable center {ol.Coordinate} the center of the view
* @todo observable projection {ol.proj.Projection} the projection of the view
@@ -501,7 +501,7 @@ ol.View2D.prototype.setZoom = function(zoom) {
/**
- * @param {ol.View2DOptions} options View2D options.
+ * @param {olx.View2DOptions} options View2D options.
* @private
* @return {ol.CenterConstraintType}
*/
@@ -516,7 +516,7 @@ ol.View2D.createCenterConstraint_ = function(options) {
/**
* @private
- * @param {ol.View2DOptions} options View2D options.
+ * @param {olx.View2DOptions} options View2D options.
* @return {{constraint: ol.ResolutionConstraintType, maxResolution: number,
* minResolution: number}}
*/
@@ -563,7 +563,7 @@ ol.View2D.createResolutionConstraint_ = function(options) {
/**
* @private
- * @param {ol.View2DOptions} options View2D options.
+ * @param {olx.View2DOptions} options View2D options.
* @return {ol.RotationConstraintType} Rotation constraint.
*/
ol.View2D.createRotationConstraint_ = function(options) {
diff --git a/test/spec/ol/layer/layer.test.js b/test/spec/ol/layer/layer.test.js
index bcb52a8be7..8fd23001e3 100644
--- a/test/spec/ol/layer/layer.test.js
+++ b/test/spec/ol/layer/layer.test.js
@@ -210,6 +210,13 @@ describe('ol.layer.Layer', function() {
expect(layer.getBrightness()).to.be(-0.7);
});
+ it('triggers a change event', function() {
+ var listener = sinon.spy();
+ layer.on(ol.ObjectEventType.CHANGE, listener);
+ layer.setBrightness(0.5);
+ expect(listener.calledOnce).to.be(true);
+ });
+
});
describe('#setContrast', function() {
@@ -238,6 +245,13 @@ describe('ol.layer.Layer', function() {
expect(layer.getContrast()).to.be(42);
});
+ it('triggers a change event', function() {
+ var listener = sinon.spy();
+ layer.on(ol.ObjectEventType.CHANGE, listener);
+ layer.setContrast(43);
+ expect(listener.calledOnce).to.be(true);
+ });
+
});
@@ -277,6 +291,13 @@ describe('ol.layer.Layer', function() {
expect(layer.getHue()).to.be(-100);
});
+ it('triggers a change event', function() {
+ var listener = sinon.spy();
+ layer.on(ol.ObjectEventType.CHANGE, listener);
+ layer.setHue(0.5);
+ expect(listener.calledOnce).to.be(true);
+ });
+
});
@@ -301,6 +322,13 @@ describe('ol.layer.Layer', function() {
expect(layer.getOpacity()).to.be(0.3);
});
+ it('triggers a change event', function() {
+ var listener = sinon.spy();
+ layer.on(ol.ObjectEventType.CHANGE, listener);
+ layer.setOpacity(0.4);
+ expect(listener.calledOnce).to.be(true);
+ });
+
});
@@ -330,25 +358,48 @@ describe('ol.layer.Layer', function() {
expect(layer.getSaturation()).to.be(42);
});
+ it('triggers a change event', function() {
+ var listener = sinon.spy();
+ layer.on(ol.ObjectEventType.CHANGE, listener);
+ layer.setSaturation(42);
+ expect(listener.calledOnce).to.be(true);
+ });
+
});
describe('#setVisible', function() {
- it('sets visible property', function() {
- var layer = new ol.layer.Layer({
+ var layer;
+ beforeEach(function() {
+ layer = new ol.layer.Layer({
source: new ol.source.Source({
projection: ol.proj.get('EPSG:4326')
})
});
+ });
+ afterEach(function() {
+ goog.dispose(layer);
+ });
+
+ it('sets visible property', function() {
layer.setVisible(false);
expect(layer.getVisible()).to.be(false);
layer.setVisible(true);
expect(layer.getVisible()).to.be(true);
+ });
- goog.dispose(layer);
+ it('fires a change event', function() {
+ var listener = sinon.spy();
+ layer.on(ol.ObjectEventType.CHANGE, listener);
+
+ layer.setVisible(false);
+ expect(listener.callCount).to.be(1);
+
+ layer.setVisible(true);
+ expect(listener.callCount).to.be(2);
});
});
@@ -356,6 +407,7 @@ describe('ol.layer.Layer', function() {
});
goog.require('goog.dispose');
+goog.require('ol.ObjectEventType');
goog.require('ol.layer.Layer');
goog.require('ol.proj');
goog.require('ol.source.Source');
diff --git a/test/spec/ol/layer/layergroup.test.js b/test/spec/ol/layer/layergroup.test.js
index 5946ec1d20..cefa283374 100644
--- a/test/spec/ol/layer/layergroup.test.js
+++ b/test/spec/ol/layer/layergroup.test.js
@@ -63,6 +63,45 @@ describe('ol.layer.Group', function() {
});
+ describe('change event', function() {
+
+ var layer, group, listener;
+ beforeEach(function() {
+ layer = new ol.layer.Layer({
+ source: new ol.source.Source({
+ projection: 'EPSG:4326'
+ })
+ });
+ group = new ol.layer.Group({
+ layers: [layer]
+ });
+ listener = sinon.spy();
+ });
+
+ afterEach(function() {
+ goog.dispose(group);
+ goog.dispose(layer);
+ });
+
+ it('is dispatched by the group when layer opacity changes', function() {
+ group.on(ol.ObjectEventType.CHANGE, listener);
+
+ layer.setOpacity(0.5);
+ expect(listener.calledOnce).to.be(true);
+ });
+
+ it('is dispatched by the group when layer visibility changes', function() {
+ group.on(ol.ObjectEventType.CHANGE, listener);
+
+ layer.setVisible(false);
+ expect(listener.callCount).to.be(1);
+
+ layer.setVisible(true);
+ expect(listener.callCount).to.be(2);
+ });
+
+ });
+
describe('constructor (options)', function() {
it('accepts options', function() {
@@ -313,6 +352,7 @@ describe('ol.layer.Group', function() {
});
goog.require('goog.dispose');
+goog.require('ol.ObjectEventType');
goog.require('ol.layer.Layer');
goog.require('ol.layer.Group');
goog.require('ol.source.Source');
diff --git a/test/spec/ol/tileurlfunction.test.js b/test/spec/ol/tileurlfunction.test.js
index 68764b4cb6..6c0e5bcbdd 100644
--- a/test/spec/ol/tileurlfunction.test.js
+++ b/test/spec/ol/tileurlfunction.test.js
@@ -84,7 +84,7 @@ describe('ol.TileUrlFunction', function() {
var fakeTileSource = {getTileGrid: function() {return null;}};
var params = {foo: 'bar'};
var tileUrlFunction = ol.TileUrlFunction.createFromParamsFunction(
- 'url', params, paramsFunction);
+ 'url', params, 0, paramsFunction);
it('calls the passed function with the correct arguments', function() {
var args = tileUrlFunction.call(fakeTileSource,
new ol.TileCoord(0, 0, 0), projection);