|
Scala Library
|
|
trait
SynchronizedBuffer[A]
extends Buffer[A]Buffer
methods of the class into which it is mixed in.| Method Summary | |
override def
|
+
(elem : A) : Buffer[A]
Append a single element to this buffer and return
the identity of the buffer.
|
override def
|
++
(iter : Iterable[A]) : Buffer[A]
Appends a number of elements provided by an iterable object
via its
elements method. The identity of the
buffer is returned. |
override def
|
++:
(iter : Iterable[A]) : Buffer[A]
Prepends a number of elements provided by an iterable object
via its
elements method. The identity of the
buffer is returned. |
override def
|
++=
(iter : Iterable[A]) : Unit
Appends a number of elements provided by an iterable object
via its
elements method. |
def
|
+:
(elem : A) : Buffer[A]
Prepend a single element to this buffer and return
the identity of the buffer.
|
def
|
+=
(elem : A) : Unit
Append a single element to this buffer.
|
override def
|
<<
(cmd : Message[(Location, A)]) : Unit
Send a message to this scriptable object.
|
override def
|
append
(elems : A*) : Unit
Appends a sequence of elements to this buffer.
|
override def
|
appendAll
(iter : Iterable[A]) : Unit
Appends a number of elements provided by an iterable object
via its
elements method. |
def
|
apply (n : Int) : A |
def
|
clear
: Unit
Clears the buffer contents.
|
override def
|
clone
: Buffer[A]
Return a clone of this buffer.
|
def
|
elements
: Iterator[A]
Creates a new iterator over all elements contained in this
object.
|
override def
|
hashCode
: Int
The hashCode method always yields an error, since it is not
safe to use buffers as keys in hash tables.
|
override def
|
insert
(n : Int, elems : A*) : Unit
Inserts new elements at the index
n. Opposed to method
update, this method will not replace an element with a
one. Instead, it will insert the new elements at index n. |
def
|
insertAll
(n : Int, iter : Iterable[A]) : Unit
Inserts new elements at the index
n. Opposed to method
update, this method will not replace an element with a
one. Instead, it will insert a new element at index n. |
def
|
length
: Int
Returns the length of the sequence.
|
override def
|
prepend
(elems : A*) : Unit
Prepend an element to this list.
|
override def
|
prependAll
(elems : Iterable[A]) : Unit
Prepends a number of elements provided by an iterable object
via its
elements method. The identity of the
buffer is returned. |
def
|
remove
(n : Int) : A
Removes the element on a given index position.
|
def
|
update
(n : Int, newelem : A) : Unit
Replace element at index
n with the new element
newelem. |
| Methods inherited from Buffer | |
| readOnly (abstract), ++=, ++=, ++, ++, -=, trimStart, trimEnd, stringPrefix |
| Methods inherited from Seq | |
| lengthCompare, size, isEmpty, 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, startsWith, endsWith, indexOf, containsSlice |
| Methods inherited from Collection | |
| toString |
| Methods inherited from Iterable | |
| partition, foreach, forall, exists, find, foldLeft, foldRight, /:, :\, reduceLeft, reduceRight, copyToBuffer, sameElements, toList, toStream, mkString, mkString, mkString, addString, addString, addString, copyToArray, hasDefiniteSize |
| Methods inherited from PartialFunction | |
| orElse, andThen |
| Methods inherited from Function1 | |
| compose |
| Methods inherited from AnyRef | |
| getClass, equals, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized |
| Methods inherited from Any | |
| ==, !=, isInstanceOf, asInstanceOf |
| Method Details |
def
length : Int
elem - the element to append.elem - the element to append.elements method. The identity of the
buffer is returned.iter - the iterable object.elements method.iter - the iterable object.elems - the elements to append.elements method.iter - the iterable object.elem - the element to append.elements method. The identity of the
buffer is returned.iter - the iterable object.elem - the element to prepend.elements method. The identity of the
buffer is returned.iter - the iterable object.n. Opposed to method
update, this method will not replace an element with a
one. Instead, it will insert the new elements at index n.n - the index where a new element will be inserted.elems - the new elements to insert.n. Opposed to method
update, this method will not replace an element with a
one. Instead, it will insert a new element at index n.n - the index where a new element will be inserted.iter - the iterable object providing all elements to insert.n with the new element
newelem.n - the index of the element to replace.newelem - the new element.n - the index which refers to the element to delete.
def
clear : Unit
cmd - the message to send.ArrayBuffer with the same elements.override
def
hashCode : Int
|
Scala Library
|
|