getAvailableUpdate

Checks if a tileset update is available for the specified region. This is a convenience method that uses a default age threshold of 0 minutes, meaning any version difference will trigger an update recommendation.

Return

Cancelable operation that can be cancelled

Parameters

regionId

The ID of the region to check for updates

callback

Callback to receive the update availability result


abstract fun getAvailableUpdate(regionId: String, maxAllowedAgeDifferenceMinutes: Long, callback: TilesetVersionManager.TilesetUpdatesCallback): Cancelable

Checks if a tileset update is available for the specified region based on age threshold. The method compares the currently downloaded tileset version with the latest available version and determines if an update is needed based on:

  • Version differences (if versions don't match)

  • Age threshold (if current version is older than the specified threshold)

  • Blocked versions (if current version is marked as blocked)

Return

Cancelable operation that can be cancelled

Parameters

regionId

The ID of the region to check for updates

maxAllowedAgeDifferenceMinutes

Maximum age difference in minutes before update is recommended

callback

Callback to receive the update availability result


abstract suspend fun getAvailableUpdate(regionId: String, maxAllowedAgeDifferenceMinutes: Long = 0): Expected<Throwable, TilesetUpdateAvailabilityResult>

Checks if a tileset update is available for the specified region based on age threshold.

Return

Expected containing either the update availability result or an error

Parameters

regionId

The ID of the region to check for updates

maxAllowedAgeDifferenceMinutes

Maximum age difference in minutes before update is recommended