JavaScript is disabled on your browser.
Skip navigation links
  • Summary:
  • Nested |
  • Field |
  • Constr |
  • Method
  • Detail:
  • Field |
  • Constr |
  • Method
io.reactivex.rxjava3.operators

Interface SimpleQueue<T>

    • Method Summary

      All Methods
      Modifier and Type Method and Description
      void clear ()
      Removes all enqueued items from this queue.
      boolean isEmpty ()
      Returns true if the queue is empty.
      boolean offer (T value)
      Atomically enqueue a single value.
      boolean offer (T v1, T v2)
      Atomically enqueue two values.
      T poll ()
      Tries to dequeue a value (non-null) or returns null if the queue is empty.
    • Method Detail

      • offer

        boolean offer(@NonNull
         T value)
        Atomically enqueue a single value.
        Parameters:
        value - the value to enqueue, not null
        Returns:
        true if successful, false if the value was not enqueued likely due to reaching the queue capacity)
      • offer

        boolean offer(@NonNull
         T v1,
         @NonNull
         T v2)
        Atomically enqueue two values.
        Parameters:
        v1 - the first value to enqueue, not null
        v2 - the second value to enqueue, not null
        Returns:
        true if successful, false if the value was not enqueued likely due to reaching the queue capacity)
      • poll

        @Nullable
        T poll()
         throws Throwable 
        Tries to dequeue a value (non-null) or returns null if the queue is empty.

        If the producer uses offer(Object, Object) and when polling in pairs, if the first poll() returns a non-null item, the second poll() is guaranteed to return a non-null item as well.

        Returns:
        the item or null to indicate an empty queue
        Throws:
        Throwable - if some pre-processing of the dequeued item (usually through fused functions) throws.
      • isEmpty

        boolean isEmpty()
        Returns true if the queue is empty.

        Note however that due to potential fused functions in poll() it is possible this method returns false but then poll() returns null because the fused function swallowed the available item(s).

        Returns:
        true if the queue is empty
      • clear

        void clear()
        Removes all enqueued items from this queue.
Skip navigation links
  • Summary:
  • Nested |
  • Field |
  • Constr |
  • Method
  • Detail:
  • Field |
  • Constr |
  • Method

AltStyle によって変換されたページ (->オリジナル) /