HmsApiAvailability class

Constructors

HmsApiAvailability()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
setResultListener AvailabilityResultListener
Sets an AvailabilityResultListener for activity results and on dialog cancellations.
no getter

Methods

destroyStreams() Future<bool>
Destroys the event channel and stream handler.
getApiMap() Future<Map>
Obtains the API version number of each service.
getErrorDialog(int errorCode, int requestCode, [bool? useCancelListener]) → void
Displays a notification or dialog box for the result code returned by the isHMSAvailableWithApkVersion method.
getErrorString(int errorCode) Future<String>
Displays a readable text result code returned by the isHMSAvailableWithApkVersion method.
getServicesVersionCode() Future<int?>
Obtains the minimum version number of HMS Core that is supported currently.
isHMSAvailable() Future<int>
Checks whether HMS Core (APK) is successfully installed and integrated on a device, and whether the version of the installed APK is that required by the client or is later than the required version.
isHMSAvailableWithApkVersion(int minApkVersion) Future<int>
Checks whether HMS Core (APK) is successfully installed and integrated on a device, and whether the version of the installed APK is that required by the client or is later than the required version.
isHuaweiMobileNoticeAvailable() Future<int>
Checks whether the HMS Core (APK) version supports notice obtaining.
isUserResolvableError(int errorCode, [bool? usePendingIntent]) Future<bool>
Checks whether an exception is rectified through user operations.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
resolveError(int errorCode, int requestCode, [bool? usePendingIntent]) → void
Displays a notification or dialog box is displayed for the returned result code if an exception can be rectified through user operations.
setupStreams() → void
Sets up streams for activity results and on dialog cancellations.
showErrorDialogFragment(int errorCode, int requestCode, [bool? useCancelListener]) Future<bool>
Creates and displays a dialog box for a result code.
showErrorNotification(int errorCode) → void
Creates and displays a dialog box for a result code.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

ACTIVITY_NAME → const String
Name of the activity of HMS Core (APK).
HMS_API_NAME_GAME → const String
API name of the HUAWEI Game service.
HMS_API_NAME_IAP → const String
API name of the HUAWEI IAP service.
HMS_API_NAME_ID → const String
API name of the HUAWEI ID service.
HMS_API_NAME_OD → const String
API name of the open device service.
HMS_API_NAME_PAY → const String
API name of the HUAWEI Pay service.
HMS_API_NAME_PPS → const String
API name of the HUAWEI PPS service.
HMS_API_NAME_PUSH → const String
API name of the HUAWEI Push service.
HMS_API_NAME_SNS → const String
API name of the SNS service.
HMS_JSON_VERSION_MIN → const int
Earliest HMS Core (APK) version required by each service of the JSON version.
HMS_SDK_VERSION_CODE → const int
Version number of the HMS Core SDK.
HMS_SDK_VERSION_NAME → const String
Version name of the HMS Core SDK.
HMS_VERSION_CODE_GAME → const int
Version number of the HUAWEI Game service.
HMS_VERSION_CODE_IAP → const int
Version number of the HUAWEI IAP service.
HMS_VERSION_CODE_ID → const int
Version number of the HUAWEI ID service.
HMS_VERSION_CODE_MIN → const int
Earliest version that can be configured for a developer.
HMS_VERSION_CODE_OD → const int
Version number of the open device service.
HMS_VERSION_CODE_PAY → const int
Version number of the HUAWEI Pay service.
HMS_VERSION_CODE_PPS → const int
Version number of the HUAWEI PPS service.
HMS_VERSION_CODE_PUSH → const int
Version number of the HUAWEI Push service.
HMS_VERSION_CODE_SNS → const int
Version number of the SNS service.
HMS_VERSION_MAX → const int
Latest version that can be configured for a developer.
HMS_VERSION_MIN → const int
Earliest HMS Core (APK) version required by each service.
NOTICE_VERSION_CODE → const int
Version of HMS Core (APK) required by the client to obtain notices.
NULL_PARAMETER → const String
Specified parameter is null.
OBJECT_NOT_INITIALIZED → const String
Attempted to use destroyStreams method without initializing the streams
SERVICES_ACTION → const String
Action of the service of HMS Core (APK).
SERVICES_PACKAGE → const String
Package name of HMS Core (APK).