FMTCTileProvider constructor

FMTCTileProvider({
  1. required StoreDirectory storeDirectory,
  2. required FMTCTileProviderSettings? settings,
  3. Map<String, String> headers = const {},
  4. HttpClient? httpClient,
})

'flutter_map_tile_caching's custom TileProvider for use in a TileLayer

Usually created from the store directory chain, eg. StoreDirectory.getTileProvider.

This contains the logic for the tile provider, such as browse caching and using bulk downloaded tiles.

Implementation

FMTCTileProvider({
  required this.storeDirectory,
  required FMTCTileProviderSettings? settings,
  super.headers,
  HttpClient? httpClient,
})  : settings =
          settings ?? FMTC.instance.settings.defaultTileProviderSettings,
      httpClient = httpClient ?? HttpClient()
        ..userAgent = null;