Package org.apache.qpid.jms.provider
Interface AsyncResult
-
- All Known Implementing Classes:
AmqpTransactionContext.DischargeCompletion,BalancedProviderFuture,ConservativeProviderFuture,FailoverProvider.CreateConnectionRequest,FailoverProvider.FailoverRequest,NoOpAsyncResult,ProgressiveProviderFuture,ProviderFuture,WrappedAsyncResult
public interface AsyncResultDefines a result interface for Asynchronous operations.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanisComplete()Returns true if the AsyncResult has completed.voidonFailure(ProviderException result)If the operation fails this method is invoked with the Exception that caused the failure.voidonSuccess()If the operation succeeds the resulting value produced is set to null and the waiting parties are signaled.
-
-
-
Method Detail
-
onFailure
void onFailure(ProviderException result)
If the operation fails this method is invoked with the Exception that caused the failure.- Parameters:
result- The error that resulted in this asynchronous operation failing.
-
onSuccess
void onSuccess()
If the operation succeeds the resulting value produced is set to null and the waiting parties are signaled.
-
isComplete
boolean isComplete()
Returns true if the AsyncResult has completed. The task is considered complete regardless if it succeeded or failed.- Returns:
- returns true if the asynchronous operation has completed.
-
-