A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://developers.google.com/android/reference/com/google/android/gms/common/ConnectionResult below:

ConnectionResult | Google Play services

Stay organized with collections Save and categorize content based on your preferences.

public final class ConnectionResult implements Parcelable

Contains all possible error codes for when a client fails to connect to Google Play services. These error codes are used by .

Summary Constants static final int API_DISABLED = 23

The API being requested is disabled on this device for this application.

static final int API_DISABLED_FOR_CONNECTION = 24

The API being requested is disabled for this connection attempt, but may work for other connections.

static final int API_UNAVAILABLE = 16

One of the API components you attempted to connect to is not available.

static final int CANCELED = 13

The connection was canceled.

static final Parcelable.Creator<ConnectionResult> CREATOR static final int DEVELOPER_ERROR = 10

The application is misconfigured.

static final int DRIVE_EXTERNAL_STORAGE_REQUIRED = 1500

This field is deprecated.

External storage is no longer required.

static final int INTERNAL_ERROR = 8

An internal error occurred.

static final int INTERRUPTED = 15

An interrupt occurred while waiting for the connection complete.

static final int INVALID_ACCOUNT = 5

The client attempted to connect to the service with an invalid account name specified.

static final int LICENSE_CHECK_FAILED = 11

The application is not licensed to the user.

static final int NETWORK_ERROR = 7

A network error occurred.

static final int RESOLUTION_ACTIVITY_NOT_FOUND = 22

There was a user-resolvable issue connecting to Google Play services, but when attempting to start the resolution, the activity was not found.

static final int RESOLUTION_REQUIRED = 6

Completing the connection requires some form of resolution.

static final int RESTRICTED_PROFILE = 20

The current user profile is restricted and cannot use authenticated features.

static final int SERVICE_DISABLED = 3

The installed version of Google Play services has been disabled on this device.

static final int SERVICE_INVALID = 9

The version of the Google Play services installed on this device is not authentic.

static final int SERVICE_MISSING = 1

Google Play services is missing on this device.

static final int SERVICE_MISSING_PERMISSION = 19

Google Play service doesn't have one or more required permissions.

static final int SERVICE_UPDATING = 18

Google Play service is currently being updated on this device.

static final int SERVICE_VERSION_UPDATE_REQUIRED = 2

The installed version of Google Play services is out of date.

static final int SIGN_IN_FAILED = 17

The client attempted to connect to the service but the user is not signed in.

static final int SIGN_IN_REQUIRED = 4

The client attempted to connect to the service but the user is not signed in.

static final int SUCCESS = 0

The connection was successful.

static final int TIMEOUT = 14

The timeout was exceeded while waiting for the connection to complete.

Constants
public static final int API_DISABLED = 23

The API being requested is disabled on this device for this application. Trying again at a later time may succeed.

API_DISABLED_FOR_CONNECTION

public static final int API_DISABLED_FOR_CONNECTION = 24

The API being requested is disabled for this connection attempt, but may work for other connections.

public static final int API_UNAVAILABLE = 16

One of the API components you attempted to connect to is not available. The API will not work on this device or for your app or for this particular account, and updating Google Play services will not likely solve the problem.

public static final int CANCELED = 13

The connection was canceled. This is returned in two situations:

public static final int DEVELOPER_ERROR = 10

The application is misconfigured. This error is not recoverable and will be treated as fatal. The developer should look at the logs after this to determine more actionable information.

DRIVE_EXTERNAL_STORAGE_REQUIRED

public static final int DRIVE_EXTERNAL_STORAGE_REQUIRED = 1500
This field is deprecated.

External storage is no longer required.

The Drive API requires external storage (such as an SD card), but no external storage is mounted. This error is recoverable if the user installs external storage (if none is present) and ensures that it is mounted (which may involve disabling USB storage mode, formatting the storage, or other initialization as required by the device).

This error should never be returned on a device with emulated external storage. On devices with emulated external storage, the emulated "external storage" is always present regardless of whether the device also has removable storage.

public static final int INTERNAL_ERROR = 8

An internal error occurred. Retrying should resolve the problem.

public static final int INTERRUPTED = 15

An interrupt occurred while waiting for the connection complete. Only returned by blockingConnect.

public static final int INVALID_ACCOUNT = 5

The client attempted to connect to the service with an invalid account name specified.

public static final int LICENSE_CHECK_FAILED = 11

The application is not licensed to the user. This error is not recoverable and will be treated as fatal.

public static final int NETWORK_ERROR = 7

A network error occurred. Retrying should resolve the problem.

RESOLUTION_ACTIVITY_NOT_FOUND

public static final int RESOLUTION_ACTIVITY_NOT_FOUND = 22

There was a user-resolvable issue connecting to Google Play services, but when attempting to start the resolution, the activity was not found.

This can occur when attempting to resolve issues connecing to Google Play services on emulators with Google APIs but not Google Play Store.

public static final int RESOLUTION_REQUIRED = 6

Completing the connection requires some form of resolution. A resolution will be available to be started with startResolutionForResult. If the result returned is RESULT_OK, then further attempts to connect should either complete or continue on to the next issue that needs to be resolved.

public static final int RESTRICTED_PROFILE = 20

The current user profile is restricted and cannot use authenticated features. (Jelly Bean MR2+ Restricted Profiles for Android tablets)

public static final int SERVICE_DISABLED = 3

The installed version of Google Play services has been disabled on this device. The calling activity should pass this error code to getErrorDialog to get a localized error dialog that will resolve the error when shown.

public static final int SERVICE_INVALID = 9

The version of the Google Play services installed on this device is not authentic.

public static final int SERVICE_MISSING = 1

Google Play services is missing on this device. The calling activity should pass this error code to getErrorDialog to get a localized error dialog that will resolve the error when shown.

SERVICE_MISSING_PERMISSION

public static final int SERVICE_MISSING_PERMISSION = 19

Google Play service doesn't have one or more required permissions. The client may call startResolutionForResult to prompt the user to fix the issue. After activity returns with RESULT_OK further attempts to connect should succeed.

public static final int SERVICE_UPDATING = 18

Google Play service is currently being updated on this device.

SERVICE_VERSION_UPDATE_REQUIRED

public static final int SERVICE_VERSION_UPDATE_REQUIRED = 2

The installed version of Google Play services is out of date. The calling activity should pass this error code to getErrorDialog to get a localized error dialog that will resolve the error when shown.

public static final int SIGN_IN_FAILED = 17

The client attempted to connect to the service but the user is not signed in. An error may have occurred when signing in the user and the error can not be recovered with any user interaction. Alternately, the API may have been requested with addApiIfAvailable and it may be the case that no required APIs needed authentication, so authentication did not occur.

When seeing this error code,there is no resolution for the sign-in failure.

public static final int SIGN_IN_REQUIRED = 4

The client attempted to connect to the service but the user is not signed in. The client may choose to continue without using the API. Alternately, if hasResolution returns true the client may call startResolutionForResult to prompt the user to sign in. After the sign in activity returns with RESULT_OK further attempts should succeed.

public static final int SUCCESS = 0

The connection was successful.

public static final int TIMEOUT = 14

The timeout was exceeded while waiting for the connection to complete. Only returned by blockingConnect.

Public constructors
public ConnectionResult(int statusCode)

Creates a connection result.

Parameters int statusCode

The status code.

Public methods
public int getErrorCode()

Indicates the type of error that interrupted connection.

Returns int

the error code, or SUCCESS if no error occurred.

public boolean hasResolution()

Returns true if calling startResolutionForResult will start any intents requiring user interaction.

Returns boolean

true if there is a resolution that can be started.

public boolean isSuccess()

Returns true if the connection was successful.

Returns boolean

true if the connection was successful, false if there was an error.

public void startResolutionForResult(Activity activity, int requestCode)

Resolves an error by starting any intents requiring user interaction. See SIGN_IN_REQUIRED, and RESOLUTION_REQUIRED.

Parameters Activity activity

An Activity context to use to resolve the issue. The activity's onActivityResult method will be invoked after the user is done. If the resultCode is RESULT_OK, the application should try to connect again.

int requestCode

The request code to pass to onActivityResult.

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-04-14 UTC.

[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-04-14 UTC."],[[["The `ConnectionResult` class provides information about the success or failure of a connection attempt to a Google API service, including error codes and potential resolution strategies."],["If the connection fails, the `ConnectionResult` object contains details about the error, such as an error code and an optional error message."],["Developers can use methods like `isSuccess()`, `getErrorCode()`, and `hasResolution()` to determine the connection status and whether a resolution is available."],["When a resolution is available, the `startResolutionForResult()` method can be used to initiate the resolution process, often involving user interaction."],["Common error codes include `SUCCESS`, `SERVICE_MISSING`, `SERVICE_VERSION_UPDATE_REQUIRED`, `SIGN_IN_REQUIRED`, and others, each indicating a specific connection issue."]]],[]]


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4