in scala/collection/mutable
class MutableList

abstract class MutableList[A]()
extends Seq[A]
with ScalaObject
with PartialFunction[Int,A]
Implementing classes or objects:
class ListBuffer[A]()
class Stack[A]()
class Queue[A]()

This class is used internally to represent mutable lists. It is the basis for the implementation of the classes Buffer, Stack, and Queue.
Author:
Matthias Zenger
Version:
1.0, 08/07/2003

Method Summary
protected def appendElem(elem: A): Unit
  def apply(n: Int): A
     Returns the nth element of this list.
  def elements: Iterator[A]
     Returns an iterator over all elements of this list.
protected var first: LinkedList[A]
  def get(n: Int): Option[A]
     Returns the nth element of this list or None if this element does not exist.
protected var last: LinkedList[A]
protected var len: Int
  def length: Int
     Returns the length of this list.
protected def prependElem(elem: A): Unit
protected def reset: Unit
protected override def stringPrefix: String
     Defines the prefix of the string representation.
override def toList: List[A]
     Returns an instance of scala.List containing the same sequence of elements.

Methods inherited from java/lang/Object-class
clone, eq, equals, finalize, getClass, hashCode, notify, notifyAll, synchronized, wait, wait, wait

Methods inherited from scala/Any-class
!=, ==, asInstanceOf, isInstanceOf, match

Methods inherited from scala/Iterable-class
/:, :\, exists, find, foldLeft, foldRight, forall, foreach, sameElements

Methods inherited from scala/Seq-class
copyToArray, drop, indexOf, isDefinedAt, lastIndexOf, subseq, take, toString

Method Detail

first

  protected var first: LinkedList[A]

last

  protected var last: LinkedList[A]

len

  protected var len: Int

length

  def length: Int
Returns the length of this list.

apply

  def apply(n: Int): A
Returns the nth element of this list. This method yields an error if the element does not exist.

get

  def get(n: Int): Option[A]
Returns the nth element of this list or None if this element does not exist.

prependElem

  protected def prependElem(elem: A): Unit

appendElem

  protected def appendElem(elem: A): Unit

reset

  protected def reset: Unit

elements

  def elements: Iterator[A]
Returns an iterator over all elements of this list.

toList

  override def toList: List[A]
Returns an instance of scala.List containing the same sequence of elements.

stringPrefix

  protected override def stringPrefix: String
Defines the prefix of the string representation.