Add support for ArcGIS Rest Services

Adding a data source to support ArcGIS Map Server and Image Server.
Functionality is similar to the ArcGIS93Rest Layer in OpenLayers 2.
This commit is contained in:
cwgrant
2015-02-16 18:37:13 -05:00
parent 3fbc6fa361
commit f63a856741
5 changed files with 626 additions and 0 deletions

28
examples/arcgis-tiled.js Normal file
View File

@@ -0,0 +1,28 @@
goog.require('ol.Map');
goog.require('ol.View');
goog.require('ol.layer.Tile');
goog.require('ol.source.MapQuest');
goog.require('ol.source.TileArcGISRest');
var url = 'http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/' +
'Specialty/ESRI_StateCityHighway_USA/MapServer';
var layers = [
new ol.layer.Tile({
source: new ol.source.MapQuest({layer: 'sat'})
}),
new ol.layer.Tile({
extent: [-13884991, 2870341, -7455066, 6338219],
source: new ol.source.TileArcGISRest({
url: url
})
})
];
var map = new ol.Map({
layers: layers,
target: 'map',
view: new ol.View({
center: [-10997148, 4569099],
zoom: 4
})
});