Class
OsmTileMapSource

Open street base map source.

Definition

Namespace:Telerik.Windows.Controls.Map

Assembly:Telerik.Windows.Controls.DataVisualization.dll

Syntax:

cs-api-definition
public class OsmTileMapSource : TiledMapSource, IMapSource

Inheritance: objectMultiScaleTileSourceTiledMapSourceOsmTileMapSource

Derived Classes: OpenStreetCycleSourceOpenStreetCycleTransportSourceOpenStreetHumanitarianSourceOpenStreetMapnikSourceOpenStreetOsmarenderSourceOsmBasedMapSource

Implements: IMapSource

Inherited Members TiledMapSource.OpacityPropertyTiledMapSource.CacheTile(int, int, int, Uri, DateTime, byte[])TiledMapSource.IsLevelSupported(int)TiledMapSource.ConvertTileToZoomLevel(int)TiledMapSource.ConvertZoomToTileLevel(int)TiledMapSource.GetCachedTileName(int, int, int)TiledMapSource.GetCachedTile(int, int, int)TiledMapSource.GetCachedTileAsync(int, int, int, Action<byte[]>)TiledMapSource.GetTileLayers(int, int, int, IList<object>)TiledMapSource.IsValidTileLevel(int)TiledMapSource.InvalidateNullTiles()TiledMapSource.RaiseInitializeCompleted()TiledMapSource.RaiseInitializationFaulted(string, Exception)TiledMapSource.CacheStorageTiledMapSource.CultureTiledMapSource.IsTileCachingEnabledTiledMapSource.OpacityTiledMapSource.UniqueIdTiledMapSource.MinZoomLevelTiledMapSource.MaxZoomLevelTiledMapSource.InitializeCompletedTiledMapSource.InitializationFaultedMultiScaleTileSource.InvalidateTileLayer(int, int, int, int)MultiScaleTileSource.SetTileCacheSize(int)MultiScaleTileSource.OnHttpAuthenticationRequired(Uri, string, Dictionary<string, string>)MultiScaleTileSource.RequestCredentialsMultiScaleTileSource.WebHeaders

Constructors

OsmTileMapSource(string)

Initializes a new instance of the OsmTileMapSource class.

Declaration

cs-api-definition
[SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "0#")]
protected OsmTileMapSource(string tileUrlFormat)

Parameters

tileUrlFormat

string

Format string for the tile renderer.

OsmTileMapSource(string, string)

Initializes a new instance of the OsmTileMapSource class with API key.

Declaration

cs-api-definition
protected OsmTileMapSource(string tileUrlFormat, string key)

Parameters

tileUrlFormat

string

Format string for the tile renderer.

key

string

The API key for Cycle/Transport maps.

OsmTileMapSource(string, string[], int)

Initializes a new instance of the OsmTileMapSource class.

Declaration

cs-api-definition
[SuppressMessage("Microsoft.Design", "CA1054:UriParametersShouldNotBeStrings", MessageId = "0#")]
protected OsmTileMapSource(string tileUrlFormat, string[] tilePathPrefixes, int maxZoomLevel = 18)

Parameters

tileUrlFormat

string

Format string for the tile renderer.

tilePathPrefixes

string[]

Path prefixes for tile URL.

maxZoomLevel

int

Optional max zoom level. Default value for OSM is 18.

Fields

DefaultMaxZoomLevel

Default max zoom level for OpenStreet Maps.

Declaration

cs-api-definition
public const int DefaultMaxZoomLevel = 18

Field Value

int

Properties

APIKey

The API key needed for Transport and Cycle modes of OpenStreetMap.

Declaration

cs-api-definition
public string APIKey { get; set; }

Property Value

string

Methods

GetTile(int, int, int)

Gets the image URI.

Declaration

cs-api-definition
protected override Uri GetTile(int tileLevel, int tilePositionX, int tilePositionY)

Parameters

tileLevel

int

Tile level.

tilePositionX

int

Tile X.

tilePositionY

int

Tile Y.

Returns

Uri

URI of image.

Overrides TiledMapSource.GetTile(int, int, int)

Initialize()

Initialize provider.

Declaration

cs-api-definition
public override void Initialize()

Overrides TiledMapSource.Initialize()

IsValidCacheUri(int, int, int, Uri)

Validates loaded uri to tile position. Should be overridden if the provider loads the same tile from different http addresses.

Declaration

cs-api-definition
protected override bool IsValidCacheUri(int tileLevel, int tilePositionX, int tilePositionY, Uri uri)

Parameters

tileLevel

int

The MSI tile Level.

tilePositionX

int

The number of tiles from the left (0 based) for this tile level.

tilePositionY

int

The number of tiles from the top (0 based) for this tile level.

uri

Uri

Uri.

Returns

bool

True if the loaded uri is valid.

Overrides TiledMapSource.IsValidCacheUri(int, int, int, Uri)