VectorTileDataProviderBase.GetStream(Int64, Int64, Int64) Method
In This Article
Returns a stream that contains a vector tile with specific coordinates at a specified zoom level.
Namespace: DevExpress.Xpf.Map
Assembly: DevExpress.Xpf.Map.v24.2.dll
NuGet Package: DevExpress.Wpf.Map
#Declaration
#Parameters
Name | Type | Description |
---|---|---|
x | Int64 | An x-coordinate of a tile in the grid. |
y | Int64 | A y-coordinate of a tile in the grid. |
level | Int64 | A zoom level. |
#Returns
Type | Description |
---|---|
Stream | A stream that contains a tile. |
#Remarks
Follow the steps below to implement a provider that loads tiles from a custom source.
- Create a provider class that implements VectorTileDataProviderBase.
- Implement the VectorTileDataProviderBase.GetStream method so that it returns a tile as a sequence of bytes for specific coordinates in the tile grid at the specified zoom level.
Assign the provider to the ImageLayer.DataProvider property. Note that the ImageLayer.DataProvider is a content property. You can declare a provider in XAML directly after a layer’s declaration without wrapping it in opening and closing ImageLayer.DataProvider tags.
<dxm:MapControl> <dxm:ImageLayer> <local:VectorTileProvider/> </dxm:ImageLayer> </dxm:MapControl>
See Also