public interface

PendingResult

implements Releasable
com.google.android.gms.common.api.PendingResult<R extends com.google.android.gms.common.api.Result, C>

Class Overview

Represents a pending result from calling an API method in Google Play services. The final result object from a PendingResult is of class R, which can be retrieved in one of two ways.

Some method calls may hold resources that need to be closed (e.g. any DataBuffer in the result). Resources can be released individually, or all resources that are part of the final result can be released by calling release(). Note it is safe to release resources before the final results.

Summary

Public Methods
abstract void addResultCallback(C callback)
Add your callback here if you want the result to be delivered via a callback when the result is ready.
abstract R await()
Blocks until the task is completed.
abstract R await(long time, TimeUnit units)
Blocks until the task is completed or has timed out waiting for the result.
abstract void release()
Releases any open resources.
[Expand]
Inherited Methods
From interface com.google.android.gms.common.api.Releasable

Public Methods

public abstract void addResultCallback (C callback)

Add your callback here if you want the result to be delivered via a callback when the result is ready.

public abstract R await ()

Blocks until the task is completed. This is not allowed on the UI thread. The returned result object can have an additional failure mode of INTERRUPTED.

public abstract R await (long time, TimeUnit units)

Blocks until the task is completed or has timed out waiting for the result. This is not allowed on the UI thread. The returned result object can have an additional failure mode of INTERRUPTED.

public abstract void release ()

Releases any open resources. This is safe to call before results are ready.