Back to Devexpress

VectorTileDataProviderBase.GetStream(Int64, Int64, Int64) Method

wpf-devexpress-dot-xpf-dot-map-dot-vectortiledataproviderbase-dot-getstream-x28-system-dot-int64-system-dot-int64-system-dot-int64-x29.md

latest2.4 KB
Original Source

VectorTileDataProviderBase.GetStream(Int64, Int64, Int64) Method

Returns a stream that contains a vector tile with specific coordinates at a specified zoom level.

Namespace : DevExpress.Xpf.Map

Assembly : DevExpress.Xpf.Map.v25.2.dll

NuGet Package : DevExpress.Wpf.Map

Declaration

csharp
public virtual Stream GetStream(
    long x,
    long y,
    long level
)
vb
Public Overridable Function GetStream(
    x As Long,
    y As Long,
    level As Long
) As Stream

Parameters

NameTypeDescription
xInt64

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

TypeDescription
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.

See Also

VectorTileDataProviderBase Class

VectorTileDataProviderBase Members

DevExpress.Xpf.Map Namespace