Interface NamedBlockingDeque<E>

Type Parameters:
E - the type of values in the queue
All Superinterfaces:
AutoCloseable, BlockingDeque<E>, BlockingQueue<E>, Collection<E>, Deque<E>, Iterable<E>, NamedBlockingQueue<E>, NamedCollection, NamedDeque<E>, NamedQueue<E>, ObservableCollection<E>, Queue<E>, Releasable, SequencedCollection<E>

public interface NamedBlockingDeque<E> extends NamedBlockingQueue<E>, NamedDeque<E>, BlockingDeque<E>
A BlockingDeque based data-structure that manages values across one or more processes. Values are typically managed in memory.
  • Method Details

    • prepend

      long prepend(E e, long timeout, TimeUnit unit) throws InterruptedException
      Inserts the specified element at the front of this NamedBlockingDeque, waiting up to the specified wait time if necessary for space to become available.
      Parameters:
      e - the element to insert
      timeout - how long to wait before giving up, in units of unit
      unit - a TimeUnit determining how to interpret the timeout parameter
      Returns:
      the identifier for the inserted element, or -1L if the element could not be inserted
      Throws:
      InterruptedException - if interrupted while waiting
    • prependFirst

      long prependFirst(E e) throws InterruptedException
      Inserts the specified element at the front of this NamedBlockingDeque, waiting if necessary for space to become available.
      Parameters:
      e - the element to insert
      Returns:
      the identifier for the inserted element, or -1L if the element could not be inserted
      Throws:
      InterruptedException - if interrupted while waiting