| CLASS info |
| public final class Status extends Result implements Parcelable |
| Represents the task processing result. |
| Type | Name | Desc |
| StatusCreator< Scope > | CREATOR | The creator attribute that is mandatory for implementing the Parcelable API. |
| Status | SUCCESS | Status indicating a successful operation. |
| Status | FAILURE | Status indicating a failed operation. |
| Status | MessageNotFound | Status of 404, indicating no resource found. |
| Status | CoreException | Status of 500, indicating internal server error. |
| Constructor name |
| public Status(int code) Creates a status based on the task processing result. |
| public Status(int statusCode, String statusMessage) Creates a representation of the status based on the task processing result. |
| public Status(int statusCode, String statusMessage, PendingIntent pendingIntent) Creates a representation of the status based on the task processing result. |
| Return type | Method name |
| String | public int getStatusCode() |
| boolean | public String getStatusMessage() |
| int | public PendingIntent getResolution() |
| void | public boolean isSuccess() |
| int | public boolean hasResolution() |
| String | public void startResolutionForResult(Activity activity, int requestCode) |
| boolean | public boolean equals(Object o) () |
| int | public int describeContents() |
| void | public void writeToParcel(Parcel parcel, int i) |
| int | public final int hashCode() |
| String | public final String toString() |
| Constant |
| public static final StatusCreator< Scope > CREATOR |
| The creator attribute that is mandatory for implementing the Parcelable API. |
| Constant |
| public static final Status SUCCESS |
| Status indicating a successful operation. Constant Value: new Status(0) |
| Constant |
| public static final Status FAILURE |
| Status indicating a failed operation. Constant Value: new Status(1) |
| Constant |
| public static final Status MessageNotFound |
| Status of 404, indicating no resource found. Constant Value: new Status(404) |
| Constant |
| public static final Status CoreException |
| Status of 500, indicating internal server error. Constant Value: new Status(500) |
| constructor |
public Status(int code) |
| Creates a status based on the task processing result. |
Parameters
| Parameter name | Parameter desc |
| code | Status code: 0: success. 1: failure. 404: no resource found. 500: internal error. |
| constructor |
public Status(int statusCode, String statusMessage) |
| Creates a representation of the status based on the task processing result. |
Parameters
| Parameter name | Parameter desc |
| statusCode | Status code: 0: success. 1: failure. 404: no resource found. 500: internal error. |
| statusMessage | Status description. |
| constructor |
public Status(int statusCode, String statusMessage, PendingIntent pendingIntent) |
| Creates a representation of the status based on the task processing result. |
Parameters
| Parameter name | Parameter desc |
| statusCode | Status code: 0: success. 1: failure. 404: no resource found. 500: internal error. |
| statusMessage | Status description. |
| pendingIntent | Pending intent that will resolve the issue through user interaction. |
| Method |
public int getStatusCode() |
| Obtains the status code. |
Return
| type | desc |
| int | Status code: 0: success. 1: failure. 404: no resource found. 500: internal error. |
| Method |
public String getStatusMessage() |
| Obtains the error description. |
Return
| type | desc |
| String | Status description. |
| Method |
public PendingIntent getResolution() |
| Obtains the pending intent to resolve the failure. |
Return
| type | desc |
| PendingIntent | Pending intent that can resolve the issue. This intent can be started with the startResolutionForResult method to present UI to resolve the issue. |
| Method |
public boolean isSuccess() |
| Checks whether the status is success. |
Return
| type | desc |
| boolean | true for a task processing success, and false for a task processing failure. |
| Method |
public boolean hasResolution() |
| Checks whether there is a pending intent that will resolve the issue. If true is returned, startResolutionForResult can be called to enable the pending intent, which will resolve the failure through user interaction. |
Return
| type | desc |
| boolean | Returns true if any resolution intent is available. |
| Method |
public void startResolutionForResult(Activity activity, int requestCode) |
| Starts a pending intent to resolve a failure through user interaction. |
Parameters
| Parameter name | Parameter desc |
| activity | Activity context used to resolve the issue. The activity’s onActivityResult method will be called after the user is done. If the resultCode indicates a success, another connection can be requested. |
| requestCode | Request code passed to onActivityResult. |
| Method |
public boolean equals(Object o) |
| Method |
public int describeContents() |
| Method |
public void writeToParcel(Parcel parcel, int i) |
| Method |
public final int hashCode() |
| Method |
public final String toString() |