Scala Library
|
|
trait
QueueProxy[A]
extends
Queue[A] with
SeqProxy[A]Queue
objects implement data structures that allow to
insert and retrieve elements in a first-in-first-out (FIFO) manner.Values and Variables inherited from MutableList | |
first0, last0, len |
Method Summary | |
override def
|
++=
(iter : Iterable[A]) : Unit
Adds all elements provided by an
Iterable object
at the end of the queue. The elements are prepended in the order they
are given out by the iterator. |
override def
|
++=
(it : Iterator[A]) : Unit
Adds all elements provided by an iterator
at the end of the queue. The elements are prepended in the order they
are given out by the iterator.
|
override def
|
+=
(elem : A) : Unit
Inserts a single element at the end of the queue.
|
override def
|
apply
(n : Int) : A
Access element number
n . |
override def
|
clear
: Unit
Removes all elements from the queue. After this operation is completed,
the queue will be empty.
|
override def
|
clone
: Queue[A]
This method clones the queue.
|
override def
|
dequeue
: A
Returns the first element in the queue, and removes this element
from the queue.
|
override def
|
elements
: Iterator[A]
Returns an iterator over all elements on the queue.
|
override def
|
enqueue
(elems : A*) : Unit
Adds all elements to the queue.
|
override def
|
front
: A
Returns the first element in the queue, or throws an error if there
is no element contained in the queue.
|
override def
|
isEmpty
: Boolean
Checks if the queue is empty.
|
override def
|
length
: Int
Returns the length of this queue.
|
abstract def
|
self : Queue[A] |
Methods inherited from SeqProxy | |
lengthCompare, size, concat, last, lastOption, first, firstOption, headOption, ++, isDefinedAt, lastIndexOf, findIndexOf, indexOf, map, flatMap, filter, take, drop, slice, slice, takeWhile, dropWhile, reverse, contains, subseq, toArray, toSeq, projection, equalsWith, startsWith, endsWith, indexOf, containsSlice |
Methods inherited from IterableProxy | |
partition, foreach, forall, exists, find, foldLeft, foldRight, /:, :\, reduceLeft, reduceRight, copyToBuffer, sameElements, toList, toStream, mkString, mkString, mkString, addString, addString, addString, copyToArray, hasDefiniteSize |
Methods inherited from Proxy | |
hashCode, equals, toString |
Methods inherited from Queue | |
dequeueFirst, dequeueAll |
Methods inherited from MutableList | |
get, prependElem, appendElem, reset, stringPrefix |
Methods inherited from Seq | |
startsWith |
Methods inherited from PartialFunction | |
orElse, andThen |
Methods inherited from Function1 | |
compose |
Methods inherited from AnyRef | |
getClass, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized |
Methods inherited from Any | |
==, !=, isInstanceOf, asInstanceOf |
Method Details |
n
.n
.override
def
length : Int
override
def
isEmpty : Boolean
elem -
the element to insertIterable
object
at the end of the queue. The elements are prepended in the order they
are given out by the iterator.iter -
an iterable objectiter -
an iteratorelems -
the elements to add.override
def
dequeue : A
override
def
front : A
override
def
clear : Unit
Scala Library
|
|