toDownloadable method
DownloadableRegion<List<Object> >
toDownloadable(
- TileLayer options, {
- Crs crs = const Epsg3857(),
- dynamic errorHandler()?,
Convert this region into a downloadable region
Implementation
DownloadableRegion toDownloadable(
TileLayer options, {
Crs crs = const Epsg3857(),
Function(Object?)? errorHandler,
}) {
final BaseRegion region = type == RegionType.rectangle
? RectangleRegion(bounds!)
: type == RegionType.circle
? CircleRegion(center!, radius!)
: LineRegion(line!, radius!);
return DownloadableRegion._(
points: type == RegionType.line
? (region as LineRegion).toOutlines()
: region.toOutline(),
minZoom: minZoom,
maxZoom: maxZoom,
options: options,
type: type,
originalRegion: region,
parallelThreads: parallelThreads,
preventRedownload: preventRedownload,
seaTileRemoval: seaTileRemoval,
start: start,
end: end,
crs: crs,
errorHandler: errorHandler,
);
}