public interface AsynchronousModelFilter extends Model
TreeModel, NodeModel (ExtendedNodeModel)
and TableModel can be called synchronously in AWT thread as a direct
response to user action (this is the default behavior),
or asynchronously in a Request Processor or other thread.
Register an implementation of this along with other models,
if you need to change the original threading.| Modifier and Type | Interface and Description |
|---|---|
static class |
AsynchronousModelFilter.CALL
This enumeration identifies method(s) of view models for which
threading information is provided by
asynchronous(java.util.concurrent.Executor, org.netbeans.spi.viewmodel.AsynchronousModelFilter.CALL, java.lang.Object) method. |
| Modifier and Type | Field and Description |
|---|---|
static Executor |
CURRENT_THREAD
Executor for invocation of models method calls in the current thread.
|
static Executor |
DEFAULT
Executor, which uses a shared
RequestProcessor with
throughoutput = 1 for models method calls, making the method invocation
asynchronous. |
| Modifier and Type | Method and Description |
|---|---|
Executor |
asynchronous(Executor original,
AsynchronousModelFilter.CALL asynchCall,
Object node)
Change the threading information for view models method calls.
|
static final Executor CURRENT_THREAD
AsynchronousModelFilter.CALL.DISPLAY_NAME and
AsynchronousModelFilter.CALL.SHORT_DESCRIPTION.static final Executor DEFAULT
RequestProcessor with
throughoutput = 1 for models method calls, making the method invocation
asynchronous. The UI gives a visual feedback to the user if models method
calls take a long time. Use this to keep the UI responsive.
This is the default executor for AsynchronousModelFilter.CALL.CHILDREN and
AsynchronousModelFilter.CALL.VALUE.Executor asynchronous(Executor original, AsynchronousModelFilter.CALL asynchCall, Object node) throws UnknownTypeException
AsynchronousModelFilter.CALL enum.original - The original ExecutorasynchCall - Identification of the method callnode - Object nodeUnknownTypeExceptionBuilt on June 18 2013. | Portions Copyright 1997-2013 Oracle. All rights reserved.