OpenLayers. Layer. ArcIMS

Instances of OpenLayers.Layer.ArcIMS are used to display data from ESRI ArcIMS Mapping Services.  Create a new ArcIMS layer with the OpenLayers.Layer.ArcIMS constructor.

Inherits from

Summary
OpenLayers. Layer. ArcIMSInstances of OpenLayers.Layer.ArcIMS are used to display data from ESRI ArcIMS Mapping Services.
Constants
DEFAULT_PARAMS{Object} Default query string parameters.
Properties
tileSize{OpenLayers.Size} Size for tiles.
featureCoordSys{String} Code for feature coordinate system.
filterCoordSys{String} Code for filter coordinate system.
layers{Array} An array of objects with layer properties.
async{Boolean} Request images asynchronously.
name{String} Layer name.
isBaseLayer{Boolean} The layer is a base layer.
Constants
DEFAULT_OPTIONS{Object} Default layers properties.
Constructor
OpenLayers. Layer. ArcIMSCreate a new ArcIMS layer object.
Functions
destroyDestroy this layer
getURLReturn an image url this layer.
getURLasyncGet an image url this layer asynchronously, and execute a callback when the image url is generated.
getUrlOrImageExtract a url or image from the ArcXML image output.
setLayerQuerySet the query definition on this layer.
getFeatureInfoGet feature information from ArcIMS.
cloneCreate a clone of this layer
addTileaddTile creates a tile, initializes it, and adds it to the layer div.

Constants

DEFAULT_PARAMS

{Object} Default query string parameters.

Properties

tileSize

{OpenLayers.Size} Size for tiles.  Default is 512x512.

featureCoordSys

{String} Code for feature coordinate system.  Default is “4326”.

filterCoordSys

{String} Code for filter coordinate system.  Default is “4326”.

layers

{Array} An array of objects with layer properties.

async

{Boolean} Request images asynchronously.  Default is true.

name

{String} Layer name.  Default is “ArcIMS”.

isBaseLayer

{Boolean} The layer is a base layer.  Default is true.

Constants

DEFAULT_OPTIONS

{Object} Default layers properties.

Constructor

OpenLayers. Layer. ArcIMS

Create a new ArcIMS layer object.

Example

var arcims = new OpenLayers.Layer.ArcIMS(
    "Global Sample",
    "http://sample.avencia.com/servlet/com.esri.esrimap.Esrimap",
    {
        service: "OpenLayers_Sample",
        layers: [
            // layers to manipulate
            {id: "1", visible: true}
        ]
    }
);

Parameters

name{String} A name for the layer
url{String} Base url for the ArcIMS server
options{Object} Optional object with properties to be set on the layer.

Functions

destroy

destroy: function()

Destroy 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.

getURLasync

getURLasync: function(bounds,
scope,
prop,
callback)

Get an image url this layer asynchronously, and execute a callback when the image url is generated.

Parameters

bounds{OpenLayers.Bounds} A bounds representing the bbox for the request.
scope{Object} The scope of the callback method.
prop{String} The name of the property in the scoped object to recieve the image url.
callback{Function} Function to call when image url is retrieved.

getUrlOrImage

getUrlOrImage: function(output)

Extract a url or image from the ArcXML image output.

Parameters

output{Object} The image.output property of the object returned from the ArcXML format read method.

Returns

{String} A URL for an image (potentially with the data protocol).

setLayerQuery

setLayerQuery: function(id,
querydef)

Set the query definition on this layer.  Query definitions are used to render parts of the spatial data in an image, and can be used to filter features or layers in the ArcIMS service.

Parameters

id{String} The ArcIMS layer ID.
queryDef{Object} The query definition to apply to this layer.

getFeatureInfo

getFeatureInfo: function(geometry,
layer,
options)

Get feature information from ArcIMS.  Using the applied geometry, apply the options to the query (buffer, area/envelope intersection), and query the ArcIMS service.

A note about accuracy

ArcIMS interprets the accuracy attribute in feature requests to be something like the ‘modulus’ operator on feature coordinates, applied to the database geometry of the feature.  It doesn’t round, so your feature coordinates may be up to (1 x accuracy) offset from the actual feature coordinates.  If the accuracy of the layer is not specified, the accuracy will be computed to be approximately 1 feature coordinate per screen pixel.

Parameters

geometry{OpenLayers.LonLat} or {OpenLayers.Geometry.Polygon} The geometry to use when making the query.  This should be a closed polygon for behavior approximating a free selection.
layer{Object} The ArcIMS layer definition.  This is an anonymous object that looks like:
{
    id: "ArcXML layer ID",  // the ArcXML layer ID
    query: {
        where: "STATE = 'PA'",  // the where clause of the query
        accuracy: 100           // the accuracy of the returned feature
    }
}
options{Object} Object with non-default properties to set on the layer.  Supported properties are buffer, callback, scope, and any other properties applicable to the ArcXML format.  Set the ‘callback’ and ‘scope’ for an object and function to recieve the parsed features from ArcIMS.

clone

clone: function (obj)

Create a clone of this layer

Returns

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

addTile

addTile:function(bounds,
position)

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

Parameters

bounds{OpenLayers.Bounds}
position{OpenLayers.Pixel}

Returns

{OpenLayers.Tile.Image} The added image tile.

Instances of this class represent a width/height pair
destroy: function()
Destroy this layer
getURL: function(bounds)
Return an image url this layer.
getURLasync: function(bounds,
scope,
prop,
callback)
Get an image url this layer asynchronously, and execute a callback when the image url is generated.
getUrlOrImage: function(output)
Extract a url or image from the ArcXML image output.
setLayerQuery: function(id,
querydef)
Set the query definition on this layer.
getFeatureInfo: function(geometry,
layer,
options)
Get feature information from ArcIMS.
clone: function (obj)
Create a clone of this layer
addTile:function(bounds,
position)
addTile creates a tile, initializes it, and adds it to the layer div.
Create a new ArcIMS layer object.
Base class for layers that use a lattice of tiles.
Instances of this class represent bounding boxes.
This class represents a longitude and latitude pair
Polygon is a collection of Geometry.LinearRings.
This class represents a screen coordinate, in x and y coordinates
Instances of OpenLayers.Tile.Image are used to manage the image tiles used by various layers.
Close