class ConcurrentLinkedDeque[E <: AnyRef] extends AbstractCollection[E] with Deque[E] with Serializable

Annotations
@SerialVersionUID()
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ConcurrentLinkedDeque
  2. Serializable
  3. Deque
  4. SequencedCollection
  5. Queue
  6. AbstractCollection
  7. Collection
  8. Iterable
  9. AnyRef
  10. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new ConcurrentLinkedDeque(c: Collection[_ <: E])

    Constructs a deque initially containing the elements of the given collection, added in traversal order of the collection's iterator.

    Constructs a deque initially containing the elements of the given collection, added in traversal order of the collection's iterator.

    c

    the collection of elements to initially contain throws NullPointerException if the specified collection or any of its elements are null

  2. new ConcurrentLinkedDeque()

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def add(e: E): Boolean

    Inserts the specified element at the tail of this deque.

    Inserts the specified element at the tail of this deque. As the deque is unbounded, this method will never throw IllegalStateException or return false.

    returns

    true (as specified by add) throws NullPointerException if the specified element is null

    Definition Classes
    ConcurrentLinkedDequeDequeQueueAbstractCollectionCollection
  5. def addAll(c: Collection[_ <: E]): Boolean

    Appends all of the elements in the specified collection to the end of this deque, in the order that they are returned by the specified collection's iterator.

    Appends all of the elements in the specified collection to the end of this deque, in the order that they are returned by the specified collection's iterator. Attempts to addAll of a deque to itself result in IllegalArgumentException.

    c

    the elements to be inserted into this deque

    returns

    true if this deque changed as a result of the call throws NullPointerException if the specified collection or any of its elements are null throws IllegalArgumentException if the collection is this deque

    Definition Classes
    ConcurrentLinkedDequeAbstractCollectionCollection
  6. def addFirst(e: E): Unit

    Inserts the specified element at the front of this deque.

    Inserts the specified element at the front of this deque. As the deque is unbounded, this method will never throw IllegalStateException.

    throws NullPointerException if the specified element is null

    Definition Classes
    ConcurrentLinkedDequeDeque
  7. def addLast(e: E): Unit

    Inserts the specified element at the end of this deque.

    Inserts the specified element at the end of this deque. As the deque is unbounded, this method will never throw IllegalStateException.

    This method is equivalent to add().

    throws NullPointerException if the specified element is null

    Definition Classes
    ConcurrentLinkedDequeDeque
  8. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  9. def clear(): Unit

    Removes all of the elements from this deque.

    Removes all of the elements from this deque.

    Definition Classes
    ConcurrentLinkedDequeAbstractCollectionCollection
  10. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  11. def contains(o: Any): Boolean

    Returns true if this deque contains the specified element.

    Returns true if this deque contains the specified element. More formally, returns true if and only if this deque contains at least one element e such that o.equals(e).

    o

    element whose presence in this deque is to be tested

    returns

    true if this deque contains the specified element

    Definition Classes
    ConcurrentLinkedDequeDequeAbstractCollectionCollection
  12. def containsAll(c: Collection[_]): Boolean
    Definition Classes
    AbstractCollectionCollection
  13. def descendingIterator(): Iterator[E]

    Returns an iterator over the elements in this deque in reverse sequential order.

    Returns an iterator over the elements in this deque in reverse sequential order. The elements will be returned in order from last (tail) to first (head).

    The returned iterator is <a href="package-summary.html#Weakly">weakly consistent.

    returns

    an iterator over the elements in this deque in reverse order

    Definition Classes
    ConcurrentLinkedDequeDeque
  14. def element(): E

    Definition Classes
    ConcurrentLinkedDequeDequeQueue
    Exceptions thrown
  15. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  16. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  17. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  18. def forEach(action: Consumer[_ >: E]): Unit
    Definition Classes
    Iterable
  19. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  20. def getFirst(): E

    throws NoSuchElementException

    throws NoSuchElementException

    Definition Classes
    ConcurrentLinkedDequeDeque
  21. def getLast(): E

    throws NoSuchElementException

    throws NoSuchElementException

    Definition Classes
    ConcurrentLinkedDequeDeque
  22. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  23. def isEmpty(): Boolean

    Returns true if this collection contains no elements.

    Returns true if this collection contains no elements.

    returns

    true if this collection contains no elements

    Definition Classes
    ConcurrentLinkedDequeAbstractCollectionCollection
  24. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  25. def iterator(): Iterator[E]

    Returns an iterator over the elements in this deque in proper sequence.

    Returns an iterator over the elements in this deque in proper sequence. The elements will be returned in order from first (head) to last (tail).

    The returned iterator is <a href="package-summary.html#Weakly">weakly consistent.

    returns

    an iterator over the elements in this deque in proper sequence

    Definition Classes
    ConcurrentLinkedDequeDequeAbstractCollectionCollectionIterable
  26. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  27. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  28. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  29. def offer(e: E): Boolean

    Inserts the specified element at the tail of this deque.

    Inserts the specified element at the tail of this deque. As the deque is unbounded, this method will never return false.

    returns

    true (as specified by offer) throws NullPointerException if the specified element is null

    Definition Classes
    ConcurrentLinkedDequeDequeQueue
  30. def offerFirst(e: E): Boolean

    Inserts the specified element at the front of this deque.

    Inserts the specified element at the front of this deque. As the deque is unbounded, this method will never return false.

    returns

    true (as specified by offerFirst) throws NullPointerException if the specified element is null

    Definition Classes
    ConcurrentLinkedDequeDeque
  31. def offerLast(e: E): Boolean

    Inserts the specified element at the end of this deque.

    Inserts the specified element at the end of this deque. As the deque is unbounded, this method will never return false.

    This method is equivalent to add().

    returns

    true (as specified by offerLast) throws NullPointerException if the specified element is null

    Definition Classes
    ConcurrentLinkedDequeDeque
  32. def parallelStream(): Stream[E]
    Definition Classes
    Collection
  33. def peek(): E
    Definition Classes
    ConcurrentLinkedDequeDequeQueue
  34. def peekFirst(): E
    Definition Classes
    ConcurrentLinkedDequeDeque
  35. def peekLast(): E
    Definition Classes
    ConcurrentLinkedDequeDeque
  36. def poll(): E
    Definition Classes
    ConcurrentLinkedDequeDequeQueue
  37. def pollFirst(): E
    Definition Classes
    ConcurrentLinkedDequeDeque
  38. def pollLast(): E
    Definition Classes
    ConcurrentLinkedDequeDeque
  39. def pop(): E

    Definition Classes
    ConcurrentLinkedDequeDeque
    Exceptions thrown
  40. def push(e: E): Unit

    throws NullPointerException

    throws NullPointerException

    Definition Classes
    ConcurrentLinkedDequeDeque
  41. def remove(o: Any): Boolean

    Removes the first occurrence of the specified element from this deque.

    Removes the first occurrence of the specified element from this deque. If the deque does not contain the element, it is unchanged. More formally, removes the first element e such that o.equals(e) (if such an element exists). Returns true if this deque contained the specified element (or equivalently, if this deque changed as a result of the call).

    This method is equivalent to removeFirstOccurrence(Object)}.

    o

    element to be removed from this deque, if present

    returns

    true if the deque contained the specified element throws NullPointerException if the specified element is null

    Definition Classes
    ConcurrentLinkedDequeDequeAbstractCollectionCollection
  42. def remove(): E

    Definition Classes
    ConcurrentLinkedDequeDequeQueue
    Exceptions thrown
  43. def removeAll(c: Collection[_]): Boolean
    Definition Classes
    AbstractCollectionCollection
  44. def removeFirst(): E

    throws NoSuchElementException

    throws NoSuchElementException

    Definition Classes
    ConcurrentLinkedDequeDeque
  45. def removeFirstOccurrence(o: Any): Boolean

    Removes the first occurrence of the specified element from this deque.

    Removes the first occurrence of the specified element from this deque. If the deque does not contain the element, it is unchanged. More formally, removes the first element e such that o.equals(e) (if such an element exists). Returns true if this deque contained the specified element (or equivalently, if this deque changed as a result of the call).

    o

    element to be removed from this deque, if present

    returns

    true if the deque contained the specified element throws NullPointerException if the specified element is null

    Definition Classes
    ConcurrentLinkedDequeDeque
  46. def removeIf(filter: Predicate[_ >: E]): Boolean
    Definition Classes
    Collection
  47. def removeLast(): E

    throws NoSuchElementException

    throws NoSuchElementException

    Definition Classes
    ConcurrentLinkedDequeDeque
  48. def removeLastOccurrence(o: Any): Boolean

    Removes the last occurrence of the specified element from this deque.

    Removes the last occurrence of the specified element from this deque. If the deque does not contain the element, it is unchanged. More formally, removes the last element e such that o.equals(e) (if such an element exists). Returns true if this deque contained the specified element (or equivalently, if this deque changed as a result of the call).

    o

    element to be removed from this deque, if present

    returns

    true if the deque contained the specified element throws NullPointerException if the specified element is null

    Definition Classes
    ConcurrentLinkedDequeDeque
  49. def retainAll(c: Collection[_]): Boolean
    Definition Classes
    AbstractCollectionCollection
  50. def size(): Int

    Returns the number of elements in this deque.

    Returns the number of elements in this deque. If this deque contains more than Integer.MAX_VALUE elements, it returns Integer.MAX_VALUE.

    Beware that, unlike in most collections, this method is NOT a constant-time operation. Because of the asynchronous nature of these deques, determining the current number of elements requires traversing them all to count them. Additionally, it is possible for the size to change during execution of this method, in which case the returned result will be inaccurate. Thus, this method is typically not very useful in concurrent applications.

    returns

    the number of elements in this deque

    Definition Classes
    ConcurrentLinkedDequeDequeAbstractCollectionCollection
  51. def spliterator(): CLDSpliterator[E]

    Returns a Spliterator over the elements in this deque.

    Returns a Spliterator over the elements in this deque.

    The returned spliterator is weakly consistent.

    The Spliterator reports Spliterator#CONCURRENT, Spliterator#ORDERED, and Spliterator#NONNULL .

    Implementation Note: The Spliterator implements trySplit to permit limited parallelism.

    returns

    a Spliterator over the elements in this deque

    Definition Classes
    ConcurrentLinkedDequeCollectionIterable
    Since

    1.8

  52. def stream(): Stream[E]
    Definition Classes
    Collection
  53. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  54. def toArray[T <: AnyRef](a: Array[T]): Array[T]

    Returns an array containing all of the elements in this deque, in proper sequence (from first to last element); the runtime type of the returned array is that of the specified array.

    Returns an array containing all of the elements in this deque, in proper sequence (from first to last element); the runtime type of the returned array is that of the specified array. If the deque fits in the specified array, it is returned therein. Otherwise, a new array is allocated with the runtime type of the specified array and the size of this deque.

    If this deque fits in the specified array with room to spare (i.e., the array has more elements than this deque), the element in the array immediately following the end of the deque is set to null.

    Like the toArray() method, this method acts as bridge between array-based and collection-based APIs. Further, this method allows precise control over the runtime type of the output array, and may, under certain circumstances, be used to save allocation costs.

    Suppose x is a deque known to contain only strings. The following code can be used to dump the deque into a newly allocated array of String:

     String[] y = x.toArray(new String[0]);
    

    Note that toArray(new Object[0]) is identical in function to toArray().

    a

    the array into which the elements of the deque are to be stored, if it is big enough; otherwise, a new array of the same runtime type is allocated for this purpose

    returns

    an array containing all of the elements in this deque throws ArrayStoreException if the runtime type of the specified array is not a supertype of the runtime type of every element in this deque throws NullPointerException if the specified array is null

    Definition Classes
    ConcurrentLinkedDequeAbstractCollectionCollection
  55. def toArray(): Array[AnyRef]

    Returns an array containing all of the elements in this deque, in proper sequence (from first to last element).

    Returns an array containing all of the elements in this deque, in proper sequence (from first to last element).

    The returned array will be "safe" in that no references to it are maintained by this deque. (In other words, this method must allocate a new array). The caller is thus free to modify the returned array.

    This method acts as bridge between array-based and collection-based APIs.

    returns

    an array containing all of the elements in this deque

    Definition Classes
    ConcurrentLinkedDequeAbstractCollectionCollection
  56. def toString(): String
    Definition Classes
    ConcurrentLinkedDequeAbstractCollection → AnyRef → Any
  57. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  58. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  59. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()

Inherited from Serializable

Inherited from Deque[E]

Inherited from SequencedCollection[E]

Inherited from Queue[E]

Inherited from AbstractCollection[E]

Inherited from Collection[E]

Inherited from Iterable[E]

Inherited from AnyRef

Inherited from Any

Ungrouped