Package io.jmix.flowui.backgroundtask
Interface BackgroundTask.ProgressListener<T,V>
- Type Parameters:
T- progress measurement unitV- result type
- All Known Implementing Classes:
BackgroundTask.ProgressListenerAdapter
- Enclosing class:
- BackgroundTask<T,
V>
public static interface BackgroundTask.ProgressListener<T,V>
Listener of the task life cycle events, complementary to the tasks own methods:
BackgroundTask.progress(List), BackgroundTask.done(Object),
BackgroundTask.canceled().-
Method Summary
Modifier and TypeMethodDescriptionvoidonCancel()Called by the execution environment in UI thread if the task is canceled.voidCalled by the execution environment in UI thread when the task is completed.voidonProgress(List<T> changes) Called by the execution environment in UI thread on progress change.
-
Method Details
-
onProgress
Called by the execution environment in UI thread on progress change.- Parameters:
changes- list of changes since previous invocation
-
onDone
Called by the execution environment in UI thread when the task is completed.- Parameters:
result- result of execution returned byBackgroundTask.run(TaskLifeCycle)method
-
onCancel
void onCancel()Called by the execution environment in UI thread if the task is canceled.
-