Summary: Constants | Inherited Constants | Methods | Inherited Methods | [Expand All]
public class

# NearbyMessagesStatusCodes

extends CommonStatusCodes

java.lang.Object
↳ | com.google.android.gms.common.api.CommonStatusCodes
| ↳ | com.google.android.gms.nearby.messages.NearbyMessagesStatusCodes

## Class Overview

Nearby.Messages specific status codes, for use in `getStatusCode()`.

## Summary

Constants
int | APP_NOT_OPTED_IN | Status code indicating that the User has not granted the calling application permission to use Nearby.Messages.
int | APP_QUOTA_LIMIT_REACHED | The app has reached its quota limit to use Nearby Messages API.
int | BLE_ADVERTISING_UNSUPPORTED | The client requested an operation that requires Bluetooth Low Energy advertising (such as publishing with `BLE_ONLY`), but this feature is not supported.
int | BLE_SCANNING_UNSUPPORTED | The client requested an operation that requires Bluetooth Low Energy scanning (such as subscribing with `BLE_ONLY`), but this feature is not supported.
int | BLUETOOTH_OFF | Bluetooth is currently off.
int | DISALLOWED_CALLING_CONTEXT | The app is issuing an operation using a `GoogleApiClient` bound to an inappropriate Context; see the relevant method's documentation (for example, `publish(GoogleApiClient, Message, PublishOptions)`) to see its list of allowed Contexts.
int | FORBIDDEN | The request could not be completed because it was disallowed.
int | MISSING_PERMISSIONS | The request could not be completed because it was disallowed.
int | NOT_AUTHORIZED |
int | TOO_MANY_PENDING_INTENTS | The app has issued more than 5 `PendingIntent` to the Messages#subscribe.

[Expand] Inherited Constants
From class com.google.android.gms.common.api.CommonStatusCodes
int | API_NOT_CONNECTED | The client attempted to call a method from an API that failed to connect.
int | CANCELED | The result was canceled either due to client disconnect or `cancel()`.
int | DEVELOPER_ERROR | The application is misconfigured.
int | ERROR | The operation failed with no more detailed information.
int | INTERNAL_ERROR | An internal error occurred.
int | INTERRUPTED | A blocking call was interrupted while waiting and did not run to completion.
int | INVALID_ACCOUNT | The client attempted to connect to the service with an invalid account name specified.
int | NETWORK_ERROR | A network error occurred.
int | RESOLUTION_REQUIRED | Completing the operation requires some form of resolution.
int | SERVICE_DISABLED | This constant is deprecated. This case handled during connection, not during API requests. No results should be returned with this status code.
int | SERVICE_VERSION_UPDATE_REQUIRED | This constant is deprecated. This case handled during connection, not during API requests. No results should be returned with this status code.
int | SIGN_IN_REQUIRED | The client attempted to connect to the service but the user is not signed in.
int | SUCCESS | The operation was successful.
int | SUCCESS_CACHE | The operation was successful, but was used the device's cache.
int | TIMEOUT | Timed out while awaiting the result.

Public Methods
static String | getStatusCodeString(int statusCode)

[Expand] Inherited Methods
From class com.google.android.gms.common.api.CommonStatusCodes
static String | getStatusCodeString(int statusCode)
From class java.lang.Object
Object | clone()
boolean | equals(Object arg0)
void | finalize()
final Class<?> | getClass()
int | hashCode()
final void | notify()
final void | notifyAll()
String | toString()
final void | wait(long arg0, int arg1)
final void | wait(long arg0)
final void | wait()

## Constants

#### public static final int APP_NOT_OPTED_IN

Status code indicating that the User has not granted the calling application permission to use Nearby.Messages. Resolution: The application can use the returned PendingIntent to request user consent.

Constant Value: 2802 (0x00000af2)

#### public static final int APP_QUOTA_LIMIT_REACHED

The app has reached its quota limit to use Nearby Messages API. Use the Quota request form for the Nearby Messages API in your project's developer console to request more quota.

Constant Value: 2804 (0x00000af4)

#### public static final int BLE_ADVERTISING_UNSUPPORTED

The client requested an operation that requires Bluetooth Low Energy advertising (such as publishing with `BLE_ONLY`), but this feature is not supported.

##### See Also

- Bluetooth Low Energy | Android Developers

Constant Value: 2821 (0x00000b05)

#### public static final int BLE_SCANNING_UNSUPPORTED

The client requested an operation that requires Bluetooth Low Energy scanning (such as subscribing with `BLE_ONLY`), but this feature is not supported.

##### See Also

- Bluetooth Low Energy | Android Developers

Constant Value: 2822 (0x00000b06)

#### public static final int BLUETOOTH_OFF

Bluetooth is currently off.

Constant Value: 2820 (0x00000b04)

#### public static final int DISALLOWED_CALLING_CONTEXT

The app is issuing an operation using a `GoogleApiClient` bound to an inappropriate Context; see the relevant method's documentation (for example, `publish(GoogleApiClient, Message, PublishOptions)`) to see its list of allowed Contexts.

Constant Value: 2803 (0x00000af3)

#### public static final int FORBIDDEN

The request could not be completed because it was disallowed. The issue is not resolvable by the client, and the request should not be retried.

Constant Value: 2806 (0x00000af6)

#### public static final int MISSING_PERMISSIONS

The request could not be completed because it was disallowed. Check the error message to see what permission is missing and make sure the right `NearbyPermissions` is specified for `setPermissions(int)`.

Constant Value: 2807 (0x00000af7)

#### public static final int NOT_AUTHORIZED

Constant Value: 2805 (0x00000af5)

#### public static final int TOO_MANY_PENDING_INTENTS

The app has issued more than 5 `PendingIntent` to the Messages#subscribe. Some requests need to be removed before adding more.

Constant Value: 2801 (0x00000af1)

## Public Methods

#### public static String getStatusCodeString (int statusCode)

##### Returns

- An untranslated debug (not user-friendly!) string based on the given status code.