Scala Library Documentation
|
|
class
CharArrayReader(source : Array[Char], index : Int, line : Int, column : Int)
extends
Reader[Char]source -
an array of charactersindex -
starting offset into the array; the first element returned will be `source(index)'line -
the line number of the first element (counting from index `0' of `source')column -
the column number of the first element (counting from index `0' of `source')Additional Constructor Summary | |
def
|
this
(source : Array[Char]) : CharArrayReader
Construct a
CharArrayReader with its first element at
source(0) and position (1,1) . |
Method Summary | |
def
|
atEnd
: Boolean
Whether there are any more elements in this reader besides the first.
(i.e., whether calling `rest' will yield a `Reader' with more elements)
|
def
|
first
: Char
Returns the first element of the stream
|
def
|
pos
: Position
The position of the first element in the stream
|
def
|
rest
: CharArrayReader
Returns an abstract reader consisting of all elements except the first
|
Methods inherited from AnyRef | |
getClass, hashCode, equals, clone, toString, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized |
Methods inherited from Any | |
==, !=, isInstanceOf, asInstanceOf |
Additional Constructor Details |
def
this(source : Array[Char]) : CharArrayReader
CharArrayReader
with its first element at
source(0)
and position (1,1)
.Method Details |
def
first : Char
def
rest : CharArrayReader
atEnd
is true
, the result will be this'; otherwise, it's a Reader
containing
more elements.
def
pos : Position
def
atEnd : Boolean
Scala Library Documentation
|
|