Loading...
Searching...
No Matches
HttpTileSource Class Reference

HTTP XYZ source for outdoor vector tiles. More...

Public Member Functions

 HttpTileSource (this.urlTemplate, this.headers, this.queryParameters)
 Default constructor.
 

Public Attributes

String urlTemplate
 HTTPS XYZ template with {z}, {x}, {y}.
 

Detailed Description

HTTP XYZ source for outdoor vector tiles.

urlTemplate must contain {z}, {x}, {y}. Optional query parameters (API keys such as key, access_token, apikey) are appended to each request. Optional headers cover Authorization, Referer, or a custom User-Agent. The SDK always sends an identifying User-Agent unless the headers map already has one. Keys may also be baked into urlTemplate.

Referenced from TileProvider.

Definition at line 31 of file http_tile_source.dart.

Constructor & Destructor Documentation

◆ HttpTileSource()

HttpTileSource.HttpTileSource ( this. urlTemplate,
this. headers,
this. queryParameters )

Default constructor.

Member Data Documentation

◆ urlTemplate

String HttpTileSource.urlTemplate

HTTPS XYZ template with {z}, {x}, {y}.

Dart code snippet:

final http = HttpTileSource(
urlTemplate: "https://api.maptiler.com/tiles/v3-openmaptiles/{z}/{x}/{y}.pbf",
headers: null,
queryParameters: {"key": "YOUR_MAPTILER_KEY"},
);

Definition at line 43 of file http_tile_source.dart.


The documentation for this class was generated from the following file: