Deprecated
Experimental API
A Task is a function that takes an instance of Complete and returns nothing.
Complete is a handler that needs to be actively called to complete the Task.
Callable<T> worker = ...;
Future<T> result = Future.run(complete -> complete.with(Try.of(worker::call)));
| Modifier and Type | Class and Description |
|---|---|
| public static interface |
| Modifier and Type | Method and Description |
|---|---|
| public void |
| run | back to summary |
|---|---|
| public void run(Task. Runs the task. Non-fatal errors are catched by a | |
| Modifier and Type | Method and Description |
|---|---|
| public boolean |
| with | back to summary |
|---|---|
| public boolean with(Try<? extends T> value) A function that takes a
| |