Package 

Class UiThreadUtil


  • 
    public class UiThreadUtil
    
                        

    Utility for interacting with the UI thread.

    • Method Summary

      Modifier and Type Method Description
      static boolean isOnUiThread()
      static void assertOnUiThread() Throws an AssertionException if the current thread is not the UI thread.
      static void assertNotOnUiThread() Throws an AssertionException if the current thread is the UI thread.
      static void runOnUiThread(Runnable runnable) Runs the given {@code Runnable} on the UI thread.
      static void runOnUiThread(Runnable runnable, long delayInMs) Runs the given {@code Runnable} on the UI thread with the specified delay.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait