public class ChainedExecutor extends java.lang.Object implements java.util.concurrent.Executor, ExternalResourceReleasable
构造器和说明 |
---|
ChainedExecutor(ChannelEventRunnableFilter filter,
java.util.concurrent.Executor cur,
java.util.concurrent.Executor next)
Create a new
ChainedExecutor which will used the given
ChannelEventRunnableFilter to see if the cur Executor should get
used. |
限定符和类型 | 方法和说明 |
---|---|
void |
execute(java.lang.Runnable command)
Execute the passed
ChannelEventRunnable with the current Executor if the
ChannelEventRunnableFilter match. |
void |
releaseExternalResources()
Releases the external resources that this object depends on.
|
public ChainedExecutor(ChannelEventRunnableFilter filter, java.util.concurrent.Executor cur, java.util.concurrent.Executor next)
ChainedExecutor
which will used the given
ChannelEventRunnableFilter
to see if the cur
Executor
should get
used. Otherwise it will pass the work to the next
Executor
filter
- the ChannelEventRunnableFilter
which will be used to check if the
ChannelEventRunnable
should be passed to the cur or next Executor
cur
- the Executor
to use if the ChannelEventRunnableFilter
matchnext
- the Executor
to use if the ChannelEventRunnableFilter
does not matchpublic void execute(java.lang.Runnable command)
ChannelEventRunnable
with the current Executor
if the
ChannelEventRunnableFilter
match. Otherwise pass it to the next Executor
in
the chain.execute
在接口中 java.util.concurrent.Executor
public void releaseExternalResources()
ExternalResourceReleasable