This page describes an older version, please read about the latest version at:
https://developers.arcgis.com/en/flex/api-reference/
Packagecom.esri.ags.layers
Classpublic class DynamicMapServiceLayer
InheritanceDynamicMapServiceLayer Inheritance Layer Inheritance mx.core.UIComponent
SubclassesArcGISDynamicMapServiceLayer, ArcGISImageServiceLayer, ArcIMSMapServiceLayer, GPResultImageLayer

Base class for all dynamic layers that can be added to a map.



Public Properties
 PropertyDefined by
 InheritedinitialExtent : Extent
The initial extent of the layer.
Layer
 InheritedisInScaleRange : Boolean
Returns true if the current scale of the map is between the maximum and minimum scale of the layer [added in version 1.3].
Layer
 Inheritedloaded : Boolean
When the layer is loaded, the value becomes "true" and layer properties can be accessed.
Layer
 Inheritedmap : Map
A reference to the Map this layer is in.
Layer
 InheritedmaxScale : Number = 0
The maximum scale of the layer [added in version 1.3].
Layer
 InheritedminScale : Number = 0
The minimum scale of the layer [added in version 1.3].
Layer
 InheritedspatialReference : SpatialReference
The spatial reference of the layer.
Layer
 Inheritedunits : String
The units of the layer.
Layer
Public Methods
 MethodDefined by
  
Creates a new DynamicLayer object.
DynamicMapServiceLayer
 Inherited
refresh():void
Causes the layer to redraw or reload its content.
Layer
Protected Methods
 MethodDefined by
 Inherited
Adds listeners for ExtentEvent.EXTENT_CHANGE, ZoomEvent.ZOOM_START, ZoomEvent.ZOOM_UPDATE and ZoomEvent.ZOOM_END.
Layer
 Inherited
When an EXTENT_CHANGE event occurs, this calls invalidateLayer();
Layer
 Inherited
hideHandler(event:FlexEvent):void
When the layer is hidden (visible is set to false), this calls removeMapListeners().
Layer
 Inherited
Subclasses should call this whenever they would like to have updateLayer() called on them.
Layer
  
loadMapImage(loader:Loader):void
Subclasses must override this method.
DynamicMapServiceLayer
 Inherited
Removes all the layers children.
Layer
 Inherited
Removes the four event listeners added by addMapListeners();
Layer
 Inherited
setLoaded(value:Boolean):void
Subclasses must call this when they've loaded all their properties and are ready to load their content.
Layer
 Inherited
showHandler(event:FlexEvent):void
When the layer is shown (visible is set to true), this calls addMapListeners() and invalidateLayer().
Layer
 Inherited
toScreenX(mapX:Number):Number
Converts the x-coordinate of map point to a screen point.
Layer
 Inherited
toScreenY(mapY:Number):Number
Converts the y-coordinate of map point to a screen point.
Layer
 Inherited
updateLayer():void
Subclasses must override this method.
Layer
 Inherited
Finishes the zoom animation.
Layer
 Inherited
Prepares the zoom animation by taking a bitmap of the layer.
Layer
 Inherited
Redraws the bitmap of the layer.
Layer
Events
 EventSummaryDefined by
   Dispatched when the download of the map image is complete.DynamicMapServiceLayer
   Dispatched when an input/output error occurs when downloading the map image.DynamicMapServiceLayer
 Inherited Fires after layer properties for the layer are successfully populated.Layer
 Inherited Fires if the layer is unable to load.Layer
Constructor detail
DynamicMapServiceLayer()constructor
public function DynamicMapServiceLayer()

Creates a new DynamicLayer object.

Method detail
loadMapImage()method
protected function loadMapImage(loader:Loader):void

Subclasses must override this method. The subclass is responsible for calling the loader.load() method.

Parameters
loader:Loader — The loader instance to use.

See also

Event detail
completeevent 
Event object type: flash.events.Event

Dispatched when the download of the map image is complete.

ioErrorevent  
Event object type: flash.events.IOErrorEvent

Dispatched when an input/output error occurs when downloading the map image.