Package io.sentry
Interface IDistributionApi
- All Known Implementing Classes:
NoOpDistributionApi
@Experimental
public interface IDistributionApi
API for Sentry Build Distribution functionality.
Provides methods to check for app updates and download new versions from Sentry's preprod artifacts system.
-
Method Summary
Modifier and TypeMethodDescription@NotNull Future<UpdateStatus>Check for available updates asynchronously.@NotNull UpdateStatusCheck for available updates synchronously (blocking call).voiddownloadUpdate(@NotNull UpdateInfo info) Download and install the provided update by opening the download URL in the default browser or appropriate application.booleanCheck if the distribution integration is enabled.
-
Method Details
-
checkForUpdateBlocking
Check for available updates synchronously (blocking call). This method will block the calling thread while making the network request. Consider using checkForUpdate for non-blocking behavior.- Returns:
- UpdateStatus indicating if an update is available, up to date, or error
-
checkForUpdate
Check for available updates asynchronously.- Returns:
- Future that will resolve to an UpdateStatus result
-
downloadUpdate
Download and install the provided update by opening the download URL in the default browser or appropriate application.- Parameters:
info- Information about the update to download
-
isEnabled
boolean isEnabled()Check if the distribution integration is enabled.- Returns:
- true if the distribution integration is enabled, false otherwise
-