# Interface TileSource

All Known Implementing Classes:
  `BundledTileSource, DemoTileSource, HttpTileSource, MvtTileSource, RasterTileSource`

public interface TileSource
Supplies tile payloads to the `VectorMapEngine` given a slippy-map `z/x/y` address. Two flavors exist: vector sources (`isVector()` true) returning MVT protobuf bytes that the engine decodes and styles, and raster sources returning encoded-image bytes that the engine simply blits. The bundled `BundledTileSource`, the networked `MvtTileSource` and the keyless `RasterTileSource` cover the universal, vector and zero-config cases respectively.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `fetchTile(int z, int x, int y, TileCallback callback)`
  Requests the tile at `z/x/y`, delivering the result to `callback` on the event dispatch thread.
  `String`
  `getAttribution()`
  Attribution text that must be displayed over the map.
  `int`
  `getMaxZoom()`
  The largest zoom level this source serves.
  `int`
  `getMinZoom()`
  The smallest zoom level this source serves.
  `int`
  `getTileSize()`
  The tile edge in pixels (almost always 256).
  `boolean`
  `isVector()`
  True for MVT vector tiles, false for raster image tiles.

- ## Method Details

  - ### isVector

    boolean isVector()
    True for MVT vector tiles, false for raster image tiles.

  - ### getTileSize

    int getTileSize()
    The tile edge in pixels (almost always 256).

  - ### getMinZoom

    int getMinZoom()
    The smallest zoom level this source serves.

  - ### getMaxZoom

    int getMaxZoom()
    The largest zoom level this source serves.

  - ### getAttribution

    String getAttribution()
    Attribution text that must be displayed over the map.

  - ### fetchTile

    void fetchTile(int z, int x, int y, TileCallback callback)
    Requests the tile at `z/x/y`, delivering the result to `callback` on the event dispatch thread.