java.lang.Object | ||
↳ | com.facebook.common.executors.StatefulRunnable<T> | |
↳ | com.facebook.imagepipeline.producers.StatefulProducerRunnable<T> |
StatefulRunnable
intended to be used by producers.
Class implements common functionality related to handling producer instrumentation and resource management.
[Expand]
Inherited Constants | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
com.facebook.common.executors.StatefulRunnable
|
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
com.facebook.common.executors.StatefulRunnable
|
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
StatefulProducerRunnable(Consumer<T> consumer, ProducerListener2 producerListener, ProducerContext producerContext, String producerName) |
Protected Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
abstract void |
disposeResult(T result)
Called after onSuccess callback completes in order to dispose the result.
| ||||||||||
Map<String, String> |
getExtraMapOnCancellation()
Create extra map for cancellation
| ||||||||||
Map<String, String> |
getExtraMapOnFailure(Exception exception)
Create extra map for exception
| ||||||||||
Map<String, String> |
getExtraMapOnSuccess(T result)
Create extra map for result
| ||||||||||
void |
onCancellation()
Called when the runnable is cancelled.
| ||||||||||
void |
onFailure(Exception e)
Called if exception occurred during computation.
| ||||||||||
void |
onSuccess(T result)
Called after computing result successfully.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
com.facebook.common.executors.StatefulRunnable
| |||||||||||
From class
java.lang.Object
| |||||||||||
From interface
java.lang.Runnable
|
Called after onSuccess callback completes in order to dispose the result.
Create extra map for cancellation
Create extra map for exception
Create extra map for result
Called when the runnable is cancelled.
Called if exception occurred during computation.
Called after computing result successfully.