|
Scala
1.4.0.3 |
|||
Seq[A]
represents finite sequences of elements
of type A
.
Method Summary | |
def apply(n: Int): A
Access element number n .
|
|
override
|
def copyToArray[B >: A](xs: Array[B], start: Int): Array[B]
Fills the given array xs with the elements of
this sequence starting at position start .
|
override
|
def drop(n: Int): Seq[A]
Returns a new sub-sequence that drops the first n
elements of this sequence.
|
override
|
def indexOf[B >: A](elem: B): Int
Returns the index of the first occurence of the specified object in this sequence. |
override
|
def isDefinedAt(y: Int): Boolean
Is this partial function defined for the index x ?
|
override
|
def lastIndexOf[B >: A](elem: B): Int
Returns the index of the last occurence of the specified element in this sequence, or -1 if the sequence does not contain this element. |
def length: Int
Returns the length of the sequence. |
|
abstract
|
def self: Seq[A]
|
override
|
def subseq(from: Int, len: Int): Seq[A]
Returns a subsequence starting from index from
consisting of len elements.
|
override
|
def take(n: Int): Seq[A]
Returns the sub-sequence starting from index n .
|
override
|
def toList: List[A]
Transform this sequence into a list of all elements. |
Methods inherited from java/lang/Object-class |
clone, eq, finalize, getClass, ne, notify, notifyAll, synchronized, wait, wait, wait |
Methods inherited from scala/Any-class |
!=, ==, asInstanceOf, isInstanceOf, match |
Methods inherited from scala/Iterable-class |
concat |
Methods inherited from scala/IterableProxy-class |
/:, :\, elements, exists, find, foldLeft, foldRight, forall, foreach, sameElements |
Methods inherited from scala/Proxy-class |
equals, hashCode, toString |
Methods inherited from scala/ScalaObject-class |
getScalaType |
Methods inherited from scala/Seq-class |
concat, stringPrefix |
Method Detail |
abstract def self: Seq[A]
def length: Int
def apply(n: Int): A
n
.
n
.
override def isDefinedAt(y: Int): Boolean
x
?
x
is a legal sequence index.
override def indexOf[B >: A](elem: B): Int
elem
-
element to search for.
override def lastIndexOf[B >: A](elem: B): Int
elem
-
element to search for.
override def take(n: Int): Seq[A]
n
.
override def drop(n: Int): Seq[A]
n
elements of this sequence.
override def subseq(from: Int, len: Int): Seq[A]
from
consisting of len
elements.
override def copyToArray[B >: A](xs: Array[B], start: Int): Array[B]
xs
with the elements of
this sequence starting at position start
.
xs
-
the array to fill.
start
-
starting index.
xs
filled with the elements
of this sequence.
override def toList: List[A]
|
Scala
1.4.0.3 |
|||