Hide Table of Contents
esri/dijit/util
esri/layer/pixelFilters
esri/process
esri/support
esri/workers
Class: MapImage

require(["esri/layers/MapImage"], function(MapImage) { /* code goes here */ });

Description

(Added at v1.0)
Represents the data object for the dynamically generated map. This is returned after a successful export operation on ArcGISDynamicMapServiceLayer and Geoprocessor.getResultImage in the callback and in the event result. The MapImage class can also be used to create a geo-referenced image file for use with the MapImageLayer.

Samples

Search for samples that use this class.

Constructors

NameSummary
new MapImage(options)Creates a new Map Image object.

Properties

NameTypeSummary
extentExtentExtent of exported map.
heightNumberRequested image height in pixels.
hrefStringURL to returned image.
scaleNumberScale of requested dynamic map.
widthNumberRequested image width in pixels.
Constructor Details

new MapImage(options)

Creates a new Map Image object.
Parameters:
<Object> options Required An object that defines the map image options.
options properties:
<Extent> extent Optional Specfiy an extent for the image.
<String> href Optional Specify the url of the image.
Sample:
require([
  "esri/layers/MapImage", ... 
], function(MapImage, ... ) {
  var mi = new MapImage({
    'extent': { 'xmin': -8864908, 'ymin': 3885443, 'xmax': -8762763, 'ymax': 3976997, 'spatialReference': { 'wkid': 3857 }},
    'href': imageURL
  });
  ...
});
Property Details

<Extent> extent

Extent of exported map.

<Number> height

Requested image height in pixels.

<String> href

URL to returned image. The image format must be of a type supported by the HTML img tag.
Known values: gif | jpg | png | bmp

<Number> scale

Scale of requested dynamic map.

<Number> width

Requested image width in pixels.
Show Modal