public abstract class

DynamicLayer

extends Layer
implements PopupLayer
java.lang.Object
   ↳ com.esri.android.map.Layer
     ↳ com.esri.android.map.DynamicLayer
Known Direct Subclasses

Class Overview

DynamicLayer is the base class for all map services that contain dynamic layers and can be added to a map. You would work with one of the sub-classes of this abstract class. (for example, ArcGISDynamicMapServiceLayer - used to represent map services that contain dynamic layers).

Summary

Fields
protected SpatialReference[] supportedSRs
[Expand]
Inherited Fields
From class com.esri.android.map.Layer
Public Constructors
DynamicLayer(String url)
Constructs a dynamic layer from the service URL.
Public Methods
void cancelPendingTasks()
Cancel pending tasks.
float getBrightness()
Gets the brightness of the DynamicLayer.
float getContrast()
Gets the contrast of the DynamicLayer.
float getGamma()
Gets the gamma of the DynamicLayer.
boolean isPopupAllowGeometryUpdate(Feature feature)
Returns true if the popup allow the geometry to be updated, potentially based on some information carried by the Feature provided.
boolean isPopupDeletable(Feature feature)
Returns true if the popup created is deletable, potentially based on some information carried by the Feature provided.
boolean isPopupEditable(Feature feature)
Returns true if the popup created is editable, potentially based on some information carried by the Feature provided.
void recycle()
Releases resources referenced by the Layer so that they can be recycled.
void refresh()
Invoke this method to fetch the map image from the associated map service and update the MapView.
void setBrightness(float brightness)
Sets the brightness of the DynamicLayer.
void setContrast(float contrast)
Sets the contrast of the DynamicLayer.
void setGamma(float gamma)
Sets the gamma of the DynamicLayer.
void setImageFilter(ImageFilter filter)
Sets an ImageFilter on the DynamicLayer.
void setRenderNativeResolution(boolean renderNativeResolution)
Sets the rendering of the dynamic layer in native resolution.
Protected Methods
long create()
double getCenterMeridan()
return central meridan value
abstract byte[] getImage(int width, int height, Envelope extent)
void getImageAsych(int w, int h, Envelope extent, CallbackListener<byte[]> imagecallback)
void initLayer()
Initializes the layer.
boolean isCrossDateline()
is cross date line.
boolean isWrapAroundEnabled()
Returns whether or not wraparound is enabled on the underlying MapView.
void requestImage(int width, int height, double minx, double miny, double maxx, double maxy)
[Expand]
Inherited Methods
From class com.esri.android.map.Layer
From class java.lang.Object
From interface com.esri.android.map.popup.PopupLayer

Fields

protected SpatialReference[] supportedSRs

Public Constructors

public DynamicLayer (String url)

Constructs a dynamic layer from the service URL.

Parameters
url String: a service URL

Public Methods

public void cancelPendingTasks ()

Cancel pending tasks.

public float getBrightness ()

Gets the brightness of the DynamicLayer.

Returns
float Returns the brightness.

public float getContrast ()

Gets the contrast of the DynamicLayer.

Returns
float Returns the contrast.

public float getGamma ()

Gets the gamma of the DynamicLayer.

Returns
float Returns the gamma.

public boolean isPopupAllowGeometryUpdate (Feature feature)

Returns true if the popup allow the geometry to be updated, potentially based on some information carried by the Feature provided.

Returns
boolean

public boolean isPopupDeletable (Feature feature)

Returns true if the popup created is deletable, potentially based on some information carried by the Feature provided.

Returns
boolean

public boolean isPopupEditable (Feature feature)

Returns true if the popup created is editable, potentially based on some information carried by the Feature provided.

Returns
boolean

public void recycle ()

Releases resources referenced by the Layer so that they can be recycled.

public void refresh ()

Invoke this method to fetch the map image from the associated map service and update the MapView.

public void setBrightness (float brightness)

Sets the brightness of the DynamicLayer.

Parameters
brightness float: The brightness to set.

public void setContrast (float contrast)

Sets the contrast of the DynamicLayer.

Parameters
contrast float: The contrast to set.

public void setGamma (float gamma)

Sets the gamma of the DynamicLayer.

Parameters
gamma float: The gamma to set.

public void setImageFilter (ImageFilter filter)

Sets an ImageFilter on the DynamicLayer. Any images that are retrieved from the server will be passed through the filter before being rendered. This allows customizing the look of the DynamicLayer. To remove the filter, call this method with a value of null.

Parameters
filter ImageFilter: the ImageFilter to be applied to the DynamicLayer

public void setRenderNativeResolution (boolean renderNativeResolution)

Sets the rendering of the dynamic layer in native resolution. This property does not have any effect on low-resolution devices. You can take advantage of high-resolution display to show high quality images on the screen by enabling this property. Enabling this property will use more memory and network bandwidth. Call this method after adding the dynamic layer to the map. If called before adding the layer, this method will have no effect.

Parameters
renderNativeResolution boolean: whether to render the dynamic layer at native resolution.

Protected Methods

protected long create ()

Returns
long

protected double getCenterMeridan ()

return central meridan value

Returns
double double

protected abstract byte[] getImage (int width, int height, Envelope extent)

Parameters
width int
height int
extent Envelope
Returns
byte[]
Throws
Exception

protected void getImageAsych (int w, int h, Envelope extent, CallbackListener<byte[]> imagecallback)

Parameters
w int
h int
extent Envelope
imagecallback CallbackListener

protected void initLayer ()

Initializes the layer. The implementation should submit the OnStatusChangedListener.STATUS event accordingly.

protected boolean isCrossDateline ()

is cross date line.

Returns
boolean boolean

protected boolean isWrapAroundEnabled ()

Returns whether or not wraparound is enabled on the underlying MapView. If the MapView has not finished loading, this will return false. This call should not be made until MapView has finished loading.

Returns
boolean whether or not wraparound is enabled on the underlying MapView

protected void requestImage (int width, int height, double minx, double miny, double maxx, double maxy)

Parameters
width int
height int
minx double
miny double
maxx double
maxy double