|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.grizzly.arp.DefaultAsyncHandler
public class DefaultAsyncHandler
Default implementation of AsyncHandler. This class handle
the aysnchronous execution of a ProcessorTask. The request
processing is executed by doing:
(1) Wrap the ProcessorTask using an instance of
AsyncTask
(2) Execute the AsyncTask using the wrapped
ProcessorTask ExecutorService
(3) If the AsyncTask has been interrupted but ready
to be removed from the interrupted queue, remove it and execute the
remaining operations.
| Constructor Summary | |
|---|---|
DefaultAsyncHandler()
|
|
| Method Summary | |
|---|---|
void |
addAsyncFilter(AsyncFilter asyncFilter)
Add an AsyncFilter |
void |
handle(Task task)
Handle an instance of a Task. |
protected AsyncExecutor |
newAsyncExecutor(AsyncTask asyncTask)
Create an instance of DefaultAsyncExecutor |
boolean |
removeAsyncFilter(AsyncFilter asyncFilter)
Remove an AsyncFilter |
void |
returnTask(AsyncTask asyncTask)
Return th Task to the pool |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DefaultAsyncHandler()
| Method Detail |
|---|
protected AsyncExecutor newAsyncExecutor(AsyncTask asyncTask)
DefaultAsyncExecutor
public void handle(Task task)
Task. This method is invoked
first by a ProcessorTask, which delegate its execution to
this handler. This method will uses an AsyncTask to start
the execution of the defined AsyncFilter.
handle in interface AsyncHandlerpublic void returnTask(AsyncTask asyncTask)
Task to the pool
returnTask in interface AsyncHandlerpublic void addAsyncFilter(AsyncFilter asyncFilter)
AsyncFilter
addAsyncFilter in interface AsyncHandlerpublic boolean removeAsyncFilter(AsyncFilter asyncFilter)
AsyncFilter
removeAsyncFilter in interface AsyncHandler
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||