fetchAndCacheTile

abstract suspend fun fetchAndCacheTile(z: Int, x: Int, y: Int, overrideCache: Boolean = false): Boolean

Fetch the tile at (z, x, y) through the cache-then-network pipeline, write the result through to the cache on network success, and report whether the tile is now in the cache.

Returns true when the tile is in the cache (either already cached or fetched and written); false on permanent miss (no such tile) or unrecoverable network failure. Cancellation propagates by re-throwing the cancellation exception.

Parameters

overrideCache

when true, skip the cache lookup and force a fresh network fetch + write-through for every tile. Mirrors pre-refactor's makeLocal overrideCache for the image-tile case.