java.lang.Object | |
↳ | android.os.MessageQueue |
Low-level class holding the list of messages to be dispatched by a Looper. Messages are not added directly to a MessageQueue, but rather through MessageQueue.IdleHandler objects associated with the Looper.
You can retrieve the MessageQueue for the current thread with Looper.myQueue().
Nested Classes | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
MessageQueue.IdleHandler | Callback interface for discovering when a thread is going to block waiting for more messages. |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Add a new MessageQueue.IdleHandler to this message queue.
| |||||||||||
Remove an MessageQueue.IdleHandler from the queue that was previously added
with addIdleHandler(MessageQueue.IdleHandler).
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class java.lang.Object
|
Add a new MessageQueue.IdleHandler to this message queue. This may be removed automatically for you by returning false from IdleHandler.queueIdle() when it is invoked, or explicitly removing it with removeIdleHandler(MessageQueue.IdleHandler).
This method is safe to call from any thread.
handler | The IdleHandler to be added. |
---|
Remove an MessageQueue.IdleHandler from the queue that was previously added with addIdleHandler(MessageQueue.IdleHandler). If the given object is not currently in the idle list, nothing is done.
handler | The IdleHandler to be removed. |
---|