com.sun.javafx.runtime.async
public abstract Class AbstractAsyncOperation<V>
extends Object
implements AsyncOperation, Callable<V>
- Class Inheritance
-
- All Implemented Interfaces
- java.util.concurrent.Callable, com.sun.javafx.runtime.async.AsyncOperation
- Known Direct Subclasses
- com.sun.javafx.runtime.async.AbstractRemoteResource
- Imports
- java.util.concurrent.Callable, .ExecutionException, .FutureTask, javafx.application.Platform
AbstractAsyncOperation. Base class for result-bearing, asynchronous operations. Some operations are asynchronous
because they would potentially block the EDT for unacceptably long. Since JFX lacks a clear concurrency model,
allowing users to execute arbitrary JFX code in background threads would invariably cause problems. Therefore,
we provide a number of Java classes for async operations, which will execute in a background thread, such as
"fetch a resource over the web". Async operations should not access any JFX state except the immutable parameters
passed in, and should not have side effects other than those managed by thread-safe Java classes.
Async operations are one-time use; subclasses should not attempt to reuse them.
Field Summary
| Modifier and Type | Field and Description
|
|---|
| private int |
|
| protected final FutureTask<V> |
|
| private int |
|
| protected final AsyncOperationListener<V> |
|
| private int |
|
| private int |
|
| private int |
|
| private int |
|
Constructor Summary
| Access | Constructor and Description
|
|---|
| protected |
|
Method Detail
| getProgressGranularity | back to summary
|
|---|
| protected int getProgressGranularity()
|
| setProgressGranularity | back to summary
|
|---|
| protected void setProgressGranularity(int progressGranularity)
|
| setProgressMax | back to summary
|
|---|
| protected void setProgressMax(int progressMax)
|