Package

scala.util.parsing

input

Permalink

package input

Visibility
  1. Public
  2. All

Type Members

  1. class CharArrayReader extends CharSequenceReader

    Permalink

    A character array reader reads a stream of characters (keeping track of their positions) from an array.

  2. class CharSequenceReader extends Reader[Char]

    Permalink

    A character array reader reads a stream of characters (keeping track of their positions) from an array.

  3. case class OffsetPosition(source: CharSequence, offset: Int) extends Position with Product with Serializable

    Permalink

    OffsetPosition is a standard class for positions represented as offsets into a source document.

    OffsetPosition is a standard class for positions represented as offsets into a source document.

    source

    The source document

    offset

    The offset indicating the position

  4. class PagedSeq[T] extends AbstractSeq[T] with collection.IndexedSeq[T] with ScalaVersionSpecificPagedSeq[T]

    Permalink

    An implementation of lazily computed sequences, where elements are stored in "pages", i.e.

    An implementation of lazily computed sequences, where elements are stored in "pages", i.e. arrays of fixed size.

    A paged sequence is constructed from a function that produces more elements when asked. The producer function - more, is similar to the read method in java.io.Reader. The more function takes three parameters: an array of elements, a start index, and an end index. It should try to fill the array between start and end indices (excluding end index). It returns the number of elements produced, or -1 if end of logical input stream was reached before reading any element.

    T

    the type of the elements contained in this paged sequence, with an ClassTag context bound.

  5. class PagedSeqReader extends Reader[Char]

    Permalink

    A character array reader reads a stream of characters (keeping track of their positions) from an array.

  6. trait Position extends AnyRef

    Permalink

    Position is the base trait for objects describing a position in a document.

    Position is the base trait for objects describing a position in a document.

    It provides functionality for:

    • generating a visual representation of this position (longString);
    • comparing two positions (<).

    To use this class for a concrete kind of document, implement the lineContents method.

  7. trait Positional extends AnyRef

    Permalink

    A trait for objects that have a source position.

  8. abstract class Reader[+T] extends AnyRef

    Permalink

    An interface for streams of values that have positions.

  9. sealed class StreamReader extends PagedSeqReader

    Permalink

    A StreamReader reads from a character sequence, typically created as a PagedSeq from a java.io.Reader

    A StreamReader reads from a character sequence, typically created as a PagedSeq from a java.io.Reader

    NOTE: StreamReaders do not really fulfill the new contract for readers, which requires a source CharSequence representing the full input. Instead source is treated line by line. As a consequence, regex matching cannot extend beyond a single line when a StreamReader are used for input.

    If you need to match regexes spanning several lines you should consider class PagedSeqReader instead.

Value Members

  1. object CharArrayReader

    Permalink

    An object encapsulating basic character constants.

  2. object CharSequenceReader

    Permalink

    An object encapsulating basic character constants.

  3. object NoPosition extends Position

    Permalink

    Undefined position.

  4. object OffsetPosition extends AbstractFunction2[CharSequence, Int, OffsetPosition] with PositionCache with Serializable

    Permalink

    An object holding the index cache.

  5. object PagedSeq

    Permalink

    The PagedSeq object defines a lazy implementations of a random access sequence.

    The PagedSeq object defines a lazy implementations of a random access sequence.

    Provides utility methods that return instances of PagedSeq[Char]. fromIterator and fromIterable provide generalised instances of PagedSeq

  6. object PagedSeqReader

    Permalink

    An object encapsulating basic character constants.

  7. object StreamReader

    Permalink

    An object to create a StreamReader from a java.io.Reader.

Ungrouped