Class OsmBasedMapProvider
Represents the Open Street Map based class.
Inherited Members
Namespace: Telerik.Windows.Controls.Map
Assembly: Telerik.Windows.Controls.DataVisualization.dll
Syntax
public class OsmBasedMapProvider : TiledProvider, IDisposable, ICloneable
Constructors
OsmBasedMapProvider()
Initializes a new instance of the OsmBasedMapProvider class.
Declaration
public OsmBasedMapProvider()
Fields
MaxSourceZoomLevelProperty
Identifies the MaxSourceZoomLevel dependency property.
Declaration
public static readonly DependencyProperty MaxSourceZoomLevelProperty
Field Value
System.
|
SourceFormatProperty
Identifies the UriFormat dependency property.
Declaration
public static readonly DependencyProperty SourceFormatProperty
Field Value
System.
|
Properties
MaxSourceZoomLevel
Gets or sets the maximum Zoom Level this tile source of SourceFormat supports.
Declaration
public int MaxSourceZoomLevel { get; set; }
Property Value
System.
|
SourceFormat
Gets or sets the source format (template for Url to tiles on the map server).
Declaration
public string SourceFormat { get; set; }
Property Value
System.
|
Examples
This example demonstrates how to bind the provider to the german open street site.
<telerik:RadMap x:Name="radMap">
<telerik:RadMap.Providers>
<telerik:OsmBasedMapProvider x:Name="provider"
MaxSourceZoomLevel="18"
SourceFormat="http://[a,b,c,d].tile.openstreetmap.de/tiles/osmde/{z}/{x}/{y}.png"/>
</telerik:RadMap.Providers>
</telerik:RadMap>
SpatialReference
Returns the SpatialReference for the map provider.
Declaration
public override ISpatialReference SpatialReference { get; }
Property Value
Overrides
Methods
AddTileSource(String, Int32)
Added source according to the format like the format which is used for OSM layer in OpenLayers API.
Declaration
public OsmBasedMapSource AddTileSource(string format, int maxZoomLevel = 18)
Parameters
System. The source format like the following: .
|
System. Optional max zoom level. Default value for OSM is 18. |
Returns
Osm Added instance of OsmBasedMapSource. |
Examples
This example demonstrates how to create map provider for the german open street site.
OsmBasedMapProvider osmDe = new OsmBasedMapProvider();
TiledMapSource source = osmDe.AddTileSource("http://[a,b,c,d].tile.openstreetmap.de/tiles/osmde/{z}/{x}/{y}.png");
this.radMap.Provider = osmDe;
Clone()
Implements the ICloneable interface.
Declaration
public object Clone()
Returns
System. Cloned object. |
SetMapSourceToClone(MapProviderBase, String)
Set specific map source to clone of map provider.
Declaration
public override void SetMapSourceToClone(MapProviderBase clone, string uniqueId)
Parameters
Map Clone of map provider. |
System. Id of map source. |