Task<TState>
|
addOnCompleteListener(OnCompleteListener<TState> listener)
Adds a listener that is called when the Task completes.
|
Task<TState>
|
addOnCompleteListener(Activity activity, OnCompleteListener<TState> listener)
Adds an Activity-scoped listener that is called when the Task completes.
|
Task<TState>
|
addOnCompleteListener(Executor executor, OnCompleteListener<TState> listener)
Adds a listener that is called when the Task completes.
|
abstract
Task<TState>
|
addOnFailureListener(Activity activity, OnFailureListener listener)
Adds an Activity-scoped listener that is called if the Task fails.
|
abstract
Task<TState>
|
addOnFailureListener(OnFailureListener listener)
Adds a listener that is called if the Task fails.
|
abstract
Task<TState>
|
addOnFailureListener(Executor executor, OnFailureListener listener)
Adds a listener that is called if the Task fails.
|
abstract
Task<TState>
|
addOnSuccessListener(Executor executor, OnSuccessListener<? super TResult> listener)
Adds a listener that is called if the Task completes successfully.
|
abstract
Task<TState>
|
addOnSuccessListener(OnSuccessListener<? super TResult> listener)
Adds a listener that is called if the Task completes successfully.
|
abstract
Task<TState>
|
addOnSuccessListener(Activity activity, OnSuccessListener<? super TResult> listener)
Adds an Activity-scoped listener that is called if the Task completes
successfully.
|
<TContinuationResult>
Task<TContinuationResult>
|
continueWith(Continuation<TState, TContinuationResult> continuation)
Returns a new Task that will be completed with the result of applying the specified
Continuation to this Task.
|
<TContinuationResult>
Task<TContinuationResult>
|
continueWith(Executor executor, Continuation<TState, TContinuationResult> continuation)
Returns a new Task that will be completed with the result of applying the specified
Continuation to this Task.
|
<TContinuationResult>
Task<TContinuationResult>
|
continueWithTask(Continuation<TState, Task<TContinuationResult>> continuation)
Returns a new Task that will be completed with the result of applying the specified
Continuation to this Task.
|
<TContinuationResult>
Task<TContinuationResult>
|
continueWithTask(Executor executor, Continuation<TState, Task<TContinuationResult>> continuation)
Returns a new Task that will be completed with the result of applying the specified
Continuation to this Task.
|
abstract
Exception
|
getException()
Returns the exception that caused the Task to fail.
|
abstract
TState
|
getResult()
Gets the result of the Task, if it has already completed.
|
abstract
<X extends Throwable>
TState
|
getResult(Class<X> exceptionType)
Gets the result of the Task, if it has already completed.
|
abstract
boolean
|
isComplete()
Returns true if the Task is complete; false otherwise.
|
abstract
boolean
|
isSuccessful()
Returns true if the Task has completed successfully; false otherwise.
|