public abstract class AbstractScheduledEventExecutor extends AbstractEventExecutor
EventExecutor
。
Modifier | Constructor and Description |
---|---|
protected |
AbstractScheduledEventExecutor() |
protected |
AbstractScheduledEventExecutor(EventExecutorGroup parent) |
Modifier and Type | Method and Description |
---|---|
protected void |
cancelScheduledTasks()
取消所有计划任务。
|
protected boolean |
hasScheduledTasks()
如果计划任务已准备好处理,则返回
true 。
|
protected static long |
nanoTime() |
protected long |
nextScheduledTaskNano()
当下一个计划任务准备好运行时返回纳秒
-1 如果没有计划任务,则返回
-1 。
|
protected java.lang.Runnable |
pollScheduledTask() |
protected java.lang.Runnable |
pollScheduledTask(long nanoTime)
返回
Runnable ,准备
nanoTime 给定的
nanoTime 执行。
|
<V> ScheduledFuture<V> |
schedule(java.util.concurrent.Callable<V> callable, long delay, java.util.concurrent.TimeUnit unit) |
ScheduledFuture<?> |
schedule(java.lang.Runnable command, long delay, java.util.concurrent.TimeUnit unit) |
ScheduledFuture<?> |
scheduleAtFixedRate(java.lang.Runnable command, long initialDelay, long period, java.util.concurrent.TimeUnit unit) |
ScheduledFuture<?> |
scheduleWithFixedDelay(java.lang.Runnable command, long initialDelay, long delay, java.util.concurrent.TimeUnit unit) |
inEventLoop, iterator, newFailedFuture, newProgressivePromise, newPromise, newSucceededFuture, newTaskFor, newTaskFor, next, parent, safeExecute, shutdown, shutdownGracefully, shutdownNow, submit, submit, submit
invokeAll, invokeAll, invokeAny, invokeAny
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
inEventLoop
isShuttingDown, shutdownGracefully, terminationFuture
protected AbstractScheduledEventExecutor()
protected AbstractScheduledEventExecutor(EventExecutorGroup parent)
protected static long nanoTime()
protected void cancelScheduledTasks()
AbstractEventExecutor.inEventLoop()
是true
时, 才必须调用此方法。
protected final java.lang.Runnable pollScheduledTask()
pollScheduledTask(long)
protected final java.lang.Runnable pollScheduledTask(long nanoTime)
Runnable
,准备nanoTime
给定的nanoTime
执行。
您应该使用nanoTime()
来检索正确的nanoTime
。
protected final long nextScheduledTaskNano()
-1
如果没有计划任务,则返回
-1
。
protected final boolean hasScheduledTasks()
true
。
public ScheduledFuture<?> schedule(java.lang.Runnable command, long delay, java.util.concurrent.TimeUnit unit)
schedule
在界面
EventExecutorGroup
schedule
,界面
java.util.concurrent.ScheduledExecutorService
schedule
在课堂
AbstractEventExecutor
public <V> ScheduledFuture<V> schedule(java.util.concurrent.Callable<V> callable, long delay, java.util.concurrent.TimeUnit unit)
schedule
在界面
EventExecutorGroup
schedule
在界面
java.util.concurrent.ScheduledExecutorService
schedule
在课堂
AbstractEventExecutor
public ScheduledFuture<?> scheduleAtFixedRate(java.lang.Runnable command, long initialDelay, long period, java.util.concurrent.TimeUnit unit)
scheduleAtFixedRate
,界面
EventExecutorGroup
scheduleAtFixedRate
,界面
java.util.concurrent.ScheduledExecutorService
scheduleAtFixedRate
在课堂
AbstractEventExecutor
public ScheduledFuture<?> scheduleWithFixedDelay(java.lang.Runnable command, long initialDelay, long delay, java.util.concurrent.TimeUnit unit)
scheduleWithFixedDelay
,界面
EventExecutorGroup
scheduleWithFixedDelay
在界面
java.util.concurrent.ScheduledExecutorService
scheduleWithFixedDelay
在课堂
AbstractEventExecutor
Copyright © 2008–2018 The Netty Project. All rights reserved.