Class ShadowPausedMessageQueue

java.lang.Object
org.robolectric.shadows.ShadowMessageQueue
org.robolectric.shadows.ShadowPausedMessageQueue

@Implements(value=android.os.MessageQueue.class, isInAndroidSdk=false) public class ShadowPausedMessageQueue extends ShadowMessageQueue
The shadow MessageQueue} for LooperMode.Mode.PAUSED

This class should not be referenced directly. Use ShadowMessageQueue instead.

  • Constructor Details

    • ShadowPausedMessageQueue

      public ShadowPausedMessageQueue()
  • Method Details

    • __constructor__

      @Implementation protected void __constructor__(boolean quitAllowed)
    • nativeDestroy

      @Implementation protected static void nativeDestroy(long ptr)
    • nativePollOncePreM

      @Implementation(maxSdk=22, methodName="nativePollOnce") protected static void nativePollOncePreM(long ptr, int timeoutMillis)
    • nativePollOnce

      @Implementation(minSdk=23) protected void nativePollOnce(long ptr, int timeoutMillis)
    • nativeWake

      @Implementation protected static void nativeWake(long ptr)
    • nativeIsPolling

      @Implementation(minSdk=23) protected static boolean nativeIsPolling(long ptr)
    • isIdle

      @Implementation(minSdk=23) public boolean isIdle()
      Exposes the API23+_isIdle method to older platforms
    • enqueueMessage

      @Implementation protected boolean enqueueMessage(Message msg, long when)
    • isPolling

      @Implementation(minSdk=23) protected boolean isPolling()
    • quit

      @Implementation protected void quit(boolean allowed)
    • internalGetSize

      public int internalGetSize()
      Internal method to get the number of entries in the MessageQueue.

      Do not use, will likely be removed in a future release.

    • reset

      public void reset()
      Description copied from class: ShadowMessageQueue
      Reset the messageQueue state. Should not be called by tests - it intended for use by the Robolectric framework.
      Specified by:
      reset in class ShadowMessageQueue
    • getScheduler

      public Scheduler getScheduler()
      Description copied from class: ShadowMessageQueue
      Return this queue's Scheduler.

      Only supported in LooperMode.Mode.LEGACY.

      Specified by:
      getScheduler in class ShadowMessageQueue
    • setScheduler

      public void setScheduler(Scheduler scheduler)
      Description copied from class: ShadowMessageQueue
      Set this queue's Scheduler.

      Only supported in LooperMode.Mode.LEGACY.

      Specified by:
      setScheduler in class ShadowMessageQueue
    • getHead

      public Message getHead()
      Description copied from class: ShadowMessageQueue
      Retrieves the current Message at the top of the queue.

      Only supported in LooperMode.Mode.LEGACY.

      Specified by:
      getHead in class ShadowMessageQueue
    • setHead

      public void setHead(Message msg)
      Description copied from class: ShadowMessageQueue
      Sets the current Message at the top of the queue.

      Only supported in LooperMode.Mode.LEGACY.

      Specified by:
      setHead in class ShadowMessageQueue