Nearby.Messages specific status codes, for use in Status.getStatusCode()
.
Constant Summary
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 Strategy.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 Strategy.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,
Messages.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. |
Inherited Constant Summary
Public Method Summary
static String |
getStatusCodeString(int statusCode)
|
Inherited Method Summary
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.
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.
public static final int BLE_ADVERTISING_UNSUPPORTED
The client requested an operation that requires Bluetooth Low Energy advertising
(such as publishing with Strategy.BLE_ONLY
),
but this feature is not supported.
public static final int BLE_SCANNING_UNSUPPORTED
The client requested an operation that requires Bluetooth Low Energy scanning (such
as subscribing with Strategy.BLE_ONLY
),
but this feature is not supported.
public static final int BLUETOOTH_OFF
Bluetooth is currently off.
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,
Messages.publish(GoogleApiClient, Message, PublishOptions)
) to see its list
of allowed Contexts.
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.
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
MessagesOptions.Builder.setPermissions(int)
.
public static final int NOT_AUTHORIZED
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.
Public Methods
public static String getStatusCodeString (int statusCode)
Returns
- An untranslated debug (not user-friendly!) string based on the given status code.