public class

MessageUtil

extends Object
java.lang.Object
   ↳ com.davidluoye.support.thread.MessageUtil

Summary

Public Constructors
MessageUtil()
Public Methods
static void waitForIdle(MessageQueue queue, Runnable callback)
Schedule a callback for when the target thread goes idle.
static void waitForIdle(Handler handler, Runnable callback)
Schedule a callback for when the target thread goes idle.
static void waitForIdle(Looper looper, Runnable callback)
Schedule a callback for when the target thread goes idle.
void waitForIdle()
Wait util the application's main thread goes idle.
static void waitForIdle(Runnable callback)
Schedule a callback for when the application's main thread goes idle.
[Expand]
Inherited Methods
From class java.lang.Object

Public Constructors

public MessageUtil ()

Public Methods

public static void waitForIdle (MessageQueue queue, Runnable callback)

Schedule a callback for when the target thread goes idle.

Parameters
queue MessageQueue in target thread.
callback Called when the thread's message queue is idle.

public static void waitForIdle (Handler handler, Runnable callback)

Schedule a callback for when the target thread goes idle.

Parameters
handler Handler in target thread.
callback Called when the thread's message queue is idle.

public static void waitForIdle (Looper looper, Runnable callback)

Schedule a callback for when the target thread goes idle.

Parameters
looper Looper in target thread.
callback Called when the thread's message queue is idle.

public void waitForIdle ()

Wait util the application's main thread goes idle.

public static void waitForIdle (Runnable callback)

Schedule a callback for when the application's main thread goes idle.

Parameters
callback Called when the thread's message queue is idle.