OpenLayers.Layer.ArcGIS93Rest

Instances of OpenLayers.Layer.ArcGIS93Rest are used to display data from ESRI ArcGIS Server 9.3 (and up?)  Mapping Services using the REST API.  Create a new ArcGIS93Rest layer with the OpenLayers.Layer.ArcGIS93Rest constructor.  More detail on the REST API is available at http://sampleserver1.arcgisonline.com/ArcGIS/SDK/REST/index.html ; specifically, the URL provided to this layer should be an export service URL: http://sampleserver1.arcgisonline.com/ArcGIS/SDK/REST/export.html

Inherits from

Summary
OpenLayers.Layer.ArcGIS93RestInstances of OpenLayers.Layer.ArcGIS93Rest are used to display data from ESRI ArcGIS Server 9.3 (and up?)
Constants
DEFAULT_PARAMS{Object} Hashtable of default parameter key/value pairs
Properties
isBaseLayer{Boolean} Default is true for ArcGIS93Rest layer
Constructor
OpenLayers.Layer.ArcGIS93RestCreate a new ArcGIS93Rest layer object.
Functions
cloneCreate a clone of this layer
getURLReturn an image url this layer.
setLayerFilteraddTile creates a tile, initializes it, and adds it to the layer div.
clearLayerFilterClears layer filters, either from a specific layer, or all of them.
mergeNewParamsCatch changeParams and uppercase the new params to be merged in before calling changeParams on the super class.

Constants

DEFAULT_PARAMS

{Object} Hashtable of default parameter key/value pairs

Properties

isBaseLayer

{Boolean} Default is true for ArcGIS93Rest layer

Constructor

OpenLayers.Layer.ArcGIS93Rest

Create a new ArcGIS93Rest layer object.

Example

var arcims = new OpenLayers.Layer.ArcGIS93Rest("MyName",
                                   "http://sampleserver1.arcgisonline.com/ArcGIS/rest/services/Specialty/ESRI_StateCityHighway_USA/MapServer/export",
                                   {
                                     layers: "show:0,1,2"
                                   });

Parameters

name{String} A name for the layer
url{String} Base url for the ArcGIS server REST service
params{Object} An object with key/value pairs representing the query string parameters and values.
options{Object} Hashtable of extra options to tag onto the layer.

Valid Query Parameters

format{String} MIME type of desired image type.  Default is ‘png’
layers{String} Comma-separated list of layers to display (requires show: command).
srs{String} Projection ID.
transparent{Boolean} sets transparency of images.  May apply some alphaHack magic.

Functions

clone

clone: function (obj)

Create a clone of this layer

Returns

{OpenLayers.Layer.ArcGIS93Rest} An exact clone of this layer

getURL

getURL: function (bounds)

Return an image url this layer.

Parameters

bounds{OpenLayers.Bounds} A bounds representing the bbox for the request.

Returns

{String} A string with the map image’s url.

setLayerFilter

setLayerFilter: function (id,
queryDef)

addTile creates a tile, initializes it, and adds it to the layer div.

Parameters

id{String} The id of the layer to which the filter applies.
queryDef{String} A sql-ish query filter, for more detail see the ESRI documentation at http://sampleserver1.arcgisonline.com/ArcGIS/SDK/REST/export.html

clearLayerFilter

clearLayerFilter: function (id)

Clears layer filters, either from a specific layer, or all of them.

Parameters

id{String} The id of the layer from which to remove any filter.  If unspecified/blank, all filters will be removed.

mergeNewParams

mergeNewParams:function(newParams)

Catch changeParams and uppercase the new params to be merged in before calling changeParams on the super class.

Once params have been changed, the tiles will be reloaded with the new parameters.

Parameters

newParams{Object} Hashtable of new params to use
clone: function (obj)
Create a clone of this layer
getURL: function (bounds)
Return an image url this layer.
setLayerFilter: function (id,
queryDef)
addTile creates a tile, initializes it, and adds it to the layer div.
clearLayerFilter: function (id)
Clears layer filters, either from a specific layer, or all of them.
mergeNewParams:function(newParams)
Catch changeParams and uppercase the new params to be merged in before calling changeParams on the super class.
Create a new ArcGIS93Rest layer object.
Instances of this class represent bounding boxes.
Close