WebAppInstallRequest
open class WebAppInstallRequest
| kotlin.Any | |
| ↳ | android.content.pm.webapp.WebAppInstallRequest |
Encapsulates the parameters and callback for installing a Web App.
Instances of this class are created using the Builder and passed to WebAppManager.install(WebAppInstallRequest,Executor,ObjIntConsumer).
Summary
| Nested classes | |
|---|---|
|
Builder for creating |
|
| Constants | |
|---|---|
| static Int |
The installation was cancelled by the user. |
| static Int |
An installation request for the same Web App is already in progress. |
| static Int |
The installation failed due to an internal system error. |
| static Int |
The provided arguments (e.g., manifest URL) are invalid. |
| static Int |
The installation failed due to network connectivity issues or timeout. |
| static Int |
The calling app does not have the necessary permission to install Web Apps. |
| static Int |
The installation was blocked due to security check failures. |
| static Int |
The installation completed successfully. |
| static Int |
The installation failed due to the service being unavailable. |
| static Int |
The installation result is unknown. |
| Public methods | |
|---|---|
| open String |
Returns the PWA manifest URL. |
| open CharSequence |
getTitle()Returns the title provided for the installation request. |
Constants
RESULT_CANCELLED_BY_USER
static val RESULT_CANCELLED_BY_USER: Int
The installation was cancelled by the user.
Value: 6RESULT_DUPLICATED_REQUEST
static val RESULT_DUPLICATED_REQUEST: Int
An installation request for the same Web App is already in progress.
Value: 4RESULT_INTERNAL_ERROR
static val RESULT_INTERNAL_ERROR: Int
The installation failed due to an internal system error.
Value: 2RESULT_INVALID_ARGUMENTS
static val RESULT_INVALID_ARGUMENTS: Int
The provided arguments (e.g., manifest URL) are invalid.
Value: 5RESULT_NETWORK_ERROR
static val RESULT_NETWORK_ERROR: Int
The installation failed due to network connectivity issues or timeout.
Value: 1RESULT_PERMISSION_DENIED
static val RESULT_PERMISSION_DENIED: Int
The calling app does not have the necessary permission to install Web Apps.
The caller must be eligible to hold the android.app.role.RoleManager#ROLE_BROWSER role.
Value: 3RESULT_SECURITY_ERROR
static val RESULT_SECURITY_ERROR: Int
The installation was blocked due to security check failures.
Value: 7RESULT_SUCCESS
static val RESULT_SUCCESS: Int
The installation completed successfully.
Value: 0RESULT_UNAVAILABLE
static val RESULT_UNAVAILABLE: Int
The installation failed due to the service being unavailable.
Value: 8RESULT_UNKNOWN
static val RESULT_UNKNOWN: Int
The installation result is unknown.
Value: 9Public methods
getManifestUrl
open fun getManifestUrl(): String
Returns the PWA manifest URL.
| Return | |
|---|---|
String |
This value cannot be null. |
getTitle
open fun getTitle(): CharSequence
Returns the title provided for the installation request.
| Return | |
|---|---|
CharSequence |
This value cannot be null. |