C# Class csShared.Geo.Esri.WebTileLayer2

OpenStreetMap tiled layer. Note, use of the OpenStreetMapLayer in your map application requires attribution. Please read the usage guidelines for using OpenStreetMap tile layers in your application.

To use an OpenStreetMap tile layer in your map, add the OpenStreetMapLayer, select a style, and add attribution.

<esri:Map x:Name="MyMap"> <esri:OpenStreetMapLayer Style="Mapnik" /> </esri:Map>
<esri:Attribution Layers="{Binding ElementName=MyMap, Path=Layers}" />

When including the OpenStreetMapLayer in your map application, you must also include attribution. For the latest information, please read the usage guidelines for using OpenStreetMap tile layers in your application.

OpenStreetMap is released under the Create Commons "Attribution-Share Alike 2.0 Generic" license.

Inheritance: TiledMapServiceLayer, IAttribution, ITileCache
Exibir arquivo Open project: TNOCS/csTouch

Public Properties

Property Type Description
TileCacheFolder string

Public Methods

Method Description
GetTileUrl ( int level, int row, int col ) : string

Returns a url to the specified tile

Initialize ( ) : void

Initializes the resource.

Override this method if your resource requires asyncronous requests to initialize, and call the base method when initialization is completed.

Upon completion of initialization, check the ESRI.ArcGIS.Client.Layer.InitializationFailure for any possible errors.

ReadFully ( Stream stream ) : byte[]
WebTileLayer2 ( ) : System

Initializes a new instance of the OpenStreetMapLayer class.

Protected Methods

Method Description
GetTileSource ( int level, int row, int col, Action onComplete ) : void

Private Methods

Method Description
BindImage ( BitmapImage image, byte img, Action onComplete ) : void
CreateAttributionTemplate ( ) : void
GetTileSourceInternal ( int level, int row, int col, Action onComplete, bool internalCall ) : void
OnStylePropertyChanged ( DependencyObject d, System.Windows.DependencyPropertyChangedEventArgs e ) : void
StopProcessing ( object sender, System.Windows.ExitEventArgs e ) : void

Method Details

GetTileSource() protected method

protected GetTileSource ( int level, int row, int col, Action onComplete ) : void
level int
row int
col int
onComplete Action
return void

GetTileUrl() public method

Returns a url to the specified tile
public GetTileUrl ( int level, int row, int col ) : string
level int Layer level
row int Tile row
col int Tile column
return string

Initialize() public method

Initializes the resource.

Override this method if your resource requires asyncronous requests to initialize, and call the base method when initialization is completed.

Upon completion of initialization, check the ESRI.ArcGIS.Client.Layer.InitializationFailure for any possible errors.

public Initialize ( ) : void
return void

ReadFully() public method

public ReadFully ( Stream stream ) : byte[]
stream Stream
return byte[]

WebTileLayer2() public method

Initializes a new instance of the OpenStreetMapLayer class.
public WebTileLayer2 ( ) : System
return System

Property Details

TileCacheFolder public_oe property

public string TileCacheFolder
return string