Package zendesk.belvedere
Class Callback<E>
- java.lang.Object
-
- zendesk.belvedere.Callback<E>
-
- Type Parameters:
E- The result type.
public abstract class Callback<E> extends java.lang.ObjectSimple Callback used to deliver results asynchronously.As always, keep a strong reference to the callback in your
Activity/Fragment. Don't forget to callCallback.cancel()and revoke the reference to this callback when yourActivity/Fragmentgets destroyed.
-
-
Constructor Summary
Constructors Constructor and Description Callback()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method and Description voidcancel()Cancel this callback.abstract voidsuccess(E result)Method used to deliver results.
-
-
-
Method Detail
-
cancel
public void cancel()
Cancel this callback.Callback.success(Object)won't be called.
-
success
public abstract void success(E result)
Method used to deliver results.Will be invoked on the main thread.
- Parameters:
result- The result.
-
-