Package io.sentry.android.distribution
Class DistributionIntegration
-
- All Implemented Interfaces:
-
io.sentry.IDistributionApi,io.sentry.Integration
@ApiStatus.Experimental() public final class DistributionIntegration implements Integration, IDistributionApiThe public Android SDK for Sentry Build Distribution.
Provides functionality to check for app updates and download new versions from Sentry's preprod artifacts system.
-
-
Constructor Summary
Constructors Constructor Description DistributionIntegration(Context context)
-
Method Summary
Modifier and Type Method Description Unitregister(IScopes scopes, SentryOptions options)Registers the Distribution integration with Sentry. UpdateStatuscheckForUpdateBlocking()Check for available updates synchronously (blocking call). Future<UpdateStatus>checkForUpdate()Check for available updates asynchronously. UnitdownloadUpdate(UpdateInfo info)Download and install the provided update by opening the download URL in the default browser or appropriate application. BooleanisEnabled()Check if the distribution integration is enabled. -
-
Constructor Detail
-
DistributionIntegration
DistributionIntegration(Context context)
-
-
Method Detail
-
register
Unit register(IScopes scopes, SentryOptions options)
Registers the Distribution integration with Sentry.
- Parameters:
scopes- the Scopesoptions- the options
-
checkForUpdateBlocking
UpdateStatus checkForUpdateBlocking()
Check for available updates synchronously (blocking call). This method will block the calling thread while making the network request. Consider using checkForUpdate with callback for non-blocking behavior.
- Returns:
UpdateStatus indicating if an update is available, up to date, or error
-
checkForUpdate
Future<UpdateStatus> checkForUpdate()
Check for available updates asynchronously.
- Returns:
Future that will resolve to an UpdateStatus result
-
downloadUpdate
Unit downloadUpdate(UpdateInfo info)
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
-
-
-
-