Skip to content

Commit

Permalink
DefaultTask: fix up class javadoc
Browse files Browse the repository at this point in the history
  • Loading branch information
ctrueden committed Jun 11, 2024
1 parent e9552bc commit d4ab47a
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions src/main/java/org/scijava/task/DefaultTask.java
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,9 @@
* Default implementation of {@link Task}. Throughout the task (or job),
* {@link Task#setProgressValue(long)} can be called to inform
* how the job is progressing.
*
* <p>
* Asynchronous case:
* - A job (runnable) is sent for execution to the linked {@link ThreadService}.
* A job (runnable) is sent for execution to the linked {@link ThreadService}.
* It reports status updates via the linked {@link EventService}.
* A {@link org.scijava.task.event.TaskEvent} is sent before the job
* is started and when finished.
Expand All @@ -50,18 +50,21 @@
* by calling {@link Future#cancel(boolean)}.
* This default behaviour can be supplemented by an additional
* custom callback which can be set in {@link Task#setCancelCallBack(Runnable)}.
*
* </p>
* <p>
* Synchronous case:
* - A job that reports its status in between calls of {@link Task#start()},
* A job that reports its status in between calls of {@link Task#start()},
* and {@link Task#finish()}. It also reports its status via
* the linked {@link EventService}.
* Start and finish calls allow publishing proper {@link org.scijava.task.event.TaskEvent}
* to subscribers (with the EventService).
* Upon cancellation of a synchronous task, it is the responsibility
* of the synchronous task to handle its own cancellation through
* a custom callback which can be set via {@link Task#setCancelCallBack(Runnable)}.
* </p>
*
* @author Curtis Rueden, Nicolas Chiaruttini
* @author Curtis Rueden
* @author Nicolas Chiaruttini
*/
public class DefaultTask implements Task {

Expand Down

0 comments on commit d4ab47a

Please sign in to comment.