Class MaybeMergeArray.MpscFillOnceSimpleQueue<T>

    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) int consumerIndex  
      (package private) java.util.concurrent.atomic.AtomicInteger producerIndex  
      private static long serialVersionUID  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clear()
      Removes all enqueued items from this queue.
      int consumerIndex()  
      void drop()  
      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 peek()  
      T poll()
      Tries to dequeue a value (non-null) or returns null if the queue is empty.
      int producerIndex()  
      • Methods inherited from class java.util.concurrent.atomic.AtomicReferenceArray

        accumulateAndGet, compareAndExchange, compareAndExchangeAcquire, compareAndExchangeRelease, compareAndSet, get, getAcquire, getAndAccumulate, getAndSet, getAndUpdate, getOpaque, getPlain, lazySet, length, set, setOpaque, setPlain, setRelease, toString, updateAndGet, weakCompareAndSet, weakCompareAndSetAcquire, weakCompareAndSetPlain, weakCompareAndSetRelease, weakCompareAndSetVolatile
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • producerIndex

        final java.util.concurrent.atomic.AtomicInteger producerIndex
      • consumerIndex

        int consumerIndex
    • Constructor Detail

      • MpscFillOnceSimpleQueue

        MpscFillOnceSimpleQueue​(int length)