@ThreadSafe public interface ClosureQueue
| 限定符和类型 | 方法和说明 |
|---|---|
void |
appendPendingClosure(Closure closure)
Append a new closure into queue.
|
void |
clear()
Clear all closure in queue.
|
long |
popClosureUntil(long endIndex,
List<Closure> closures)
Pop closure from queue until index(inclusion), returns the first
popped out index, returns -1 when out of range, returns index+1
when not found.
|
long |
popClosureUntil(long endIndex,
List<Closure> closures,
List<TaskClosure> taskClosures)
Pop closure from queue until index(inclusion), returns the first
popped out index, returns -1 when out of range, returns index+1
when not found.
|
void |
resetFirstIndex(long firstIndex)
Reset the first index in queue.
|
void clear()
void resetFirstIndex(long firstIndex)
firstIndex - the first index of queuevoid appendPendingClosure(Closure closure)
closure - the closure to appendlong popClosureUntil(long endIndex,
List<Closure> closures)
endIndex - the index of queueclosures - closure listlong popClosureUntil(long endIndex,
List<Closure> closures,
List<TaskClosure> taskClosures)
endIndex - the index of queueclosures - closure listtaskClosures - task closure listCopyright © 2021. All rights reserved.