scala.io.Source

LineIterator

class LineIterator extends Iterator[String]

source: Source.scala
Inherited
  1. Hide All
  2. Show all
  1. Iterator
  2. TraversableOnce
  3. AnyRef
  4. Any
Visibility
  1. Public
  2. All

Instance constructors

  1. new LineIterator()

Type Members

  1. class GroupedIterator[B >: A] extends Iterator[Seq[B]]

    A flexible iterator for transforming an Iterator[A] into an Iterator[Seq[A]], with configurable sequence size, step, and strategy for dealing with elements which don't fit evenly.

Value Members

  1. def !=(arg0: AnyRef): Boolean

  2. def !=(arg0: Any): Boolean

    o != arg0 is the same as !(o == (arg0)).

  3. def ##(): Int

  4. def $asInstanceOf[T0](): T0

  5. def $isInstanceOf[T0](): Boolean

  6. def ++(that: ⇒ Iterator[String]): Iterator[String]

    [use case] Concatenates this iterator with another.

  7. def ++[B >: String](that: ⇒ Iterator[B]): Iterator[B]

    Concatenates this iterator with another.

  8. def /:[B](z: B)(op: (B, String) ⇒ B): B

    Applies a binary operator to a start value and all elements of this traversable or iterator, going left to right.

  9. def :\[B](z: B)(op: (String, B) ⇒ B): B

    Applies a binary operator to all elements of this traversable or iterator and a start value, going right to left.

  10. def ==(arg0: AnyRef): Boolean

    o == arg0 is the same as if (o eq null) arg0 eq null else o.equals(arg0).

  11. def ==(arg0: Any): Boolean

    o == arg0 is the same as o.equals(arg0).

  12. def addString(b: StringBuilder): StringBuilder

    Appends all elements of this traversable or iterator to a string builder.

  13. def addString(b: StringBuilder, sep: String): StringBuilder

    Appends all elements of this traversable or iterator to a string builder using a separator string.

  14. def addString(b: StringBuilder, start: String, sep: String, end: String): StringBuilder

    Appends all elements of this traversable or iterator to a string builder using start, end, and separator strings.

  15. def append[B >: String](that: Iterator[B]): Iterator[B]

    Returns a new iterator that first yields the elements of this iterator followed by the elements provided by iterator that.

  16. def asInstanceOf[T0]: T0

    This method is used to cast the receiver object to be of type T0.

  17. def buffered: BufferedIterator[String]

    Creates a buffered iterator from this iterator.

  18. def clone(): AnyRef

    This method creates and returns a copy of the receiver object.

  19. def collect[B](pf: PartialFunction[String, B]): Iterator[B]

    Creates an iterator by transforming values produced by this iterator with a partial function, dropping those values for which the partial function is not defined.

  20. def contains(elem: Any): Boolean

    Tests whether this iterator contains a given value as an element.

  21. def copyToArray(xs: Array[String], start: Int, len: Int): Unit

    [use case] Copies selected values produced by this iterator to an array.

  22. def copyToArray[B >: String](xs: Array[B], start: Int, len: Int): Unit

    Copies selected values produced by this iterator to an array.

  23. def copyToArray(xs: Array[String]): Unit

    [use case] Copies values of this traversable or iterator to an array.

  24. def copyToArray[B >: String](xs: Array[B]): Unit

    Copies values of this traversable or iterator to an array.

  25. def copyToArray(xs: Array[String], start: Int): Unit

    [use case] Copies values of this traversable or iterator to an array.

  26. def copyToArray[B >: String](xs: Array[B], start: Int): Unit

    Copies values of this traversable or iterator to an array.

  27. def copyToBuffer[B >: String](dest: Buffer[B]): Unit

    Copies all elements of this traversable or iterator to a buffer.

  28. def count(p: (String) ⇒ Boolean): Int

    Counts the number of elements in the traversable or iterator which satisfy a predicate.

  29. def counted: CountedIterator[String]

    Returns a counted iterator from this iterator.

  30. def drop(n: Int): Iterator[String]

    Advances this iterator past the first n elements, or the length of the iterator, whichever is smaller.

  31. def dropWhile(p: (String) ⇒ Boolean): Iterator[String]

    Skips longest sequence of elements of this iterator which satisfy given predicate p, and returns an iterator of the remaining elements.

  32. def duplicate: (Iterator[String], Iterator[String])

    Creates two new iterators that both iterate over the same elements as this iterator (in the same order).

  33. def eq(arg0: AnyRef): Boolean

    This method is used to test whether the argument (arg0) is a reference to the receiver object (this).

  34. def equals(arg0: Any): Boolean

    This method is used to compare the receiver object (this) with the argument object (arg0) for equivalence.

  35. def exists(p: (String) ⇒ Boolean): Boolean

    Tests whether a predicate holds for some of the values produced by this iterator.

  36. def filter(p: (String) ⇒ Boolean): Iterator[String]

    Returns an iterator over all the elements of this iterator that satisfy the predicate p.

  37. def filterNot(p: (String) ⇒ Boolean): Iterator[String]

    Creates an iterator over all the elements of this iterator which do not satisfy a predicate p.

  38. def finalize(): Unit

    This method is called by the garbage collector on the receiver object when garbage collection determines that there are no more references to the object.

  39. def find(p: (String) ⇒ Boolean): Option[String]

    Finds the first value produced by the iterator satisfying a predicate, if any.

  40. def findIndexOf(p: (String) ⇒ Boolean): Int

    Returns index of the first element satisfying a predicate, or -1.

  41. def flatMap[B](f: (String) ⇒ Iterator[B]): Iterator[B]

    Creates a new iterator by applying a function to all values produced by this iterator and concatenating the results.

  42. def foldLeft[B](z: B)(op: (B, String) ⇒ B): B

    Applies a binary operator to a start value and all elements of this traversable or iterator, going left to right.

  43. def foldRight[B](z: B)(op: (String, B) ⇒ B): B

    Applies a binary operator to all elements of this traversable or iterator and a start value, going right to left.

  44. def forall(p: (String) ⇒ Boolean): Boolean

    Tests whether a predicate holds for all values produced by this iterator.

  45. def foreach(f: (String) ⇒ Unit): Unit

    [use case] Applies a function f to all values produced by this iterator.

  46. def foreach[U](f: (String) ⇒ U): Unit

    Applies a function f to all values produced by this iterator.

  47. def getClass(): java.lang.Class[_ <: java.lang.Object]

    Returns a representation that corresponds to the dynamic class of the receiver object.

  48. def getc(): Boolean

  49. def grouped[B >: String](size: Int): GroupedIterator[B]

    Returns an iterator which groups this iterator into fixed size blocks.

  50. def hasDefiniteSize: Boolean

    Tests whether this Iterator has a known size.

  51. def hasNext: Boolean

    Tests whether this iterator can provide another element.

  52. def hashCode(): Int

    Returns a hash code value for the object.

  53. def indexOf[B >: String](elem: B): Int

    Returns the index of the first occurrence of the specified object in this iterable object.

  54. def indexWhere(p: (String) ⇒ Boolean): Int

    Returns the index of the first produced value satisfying a predicate, or -1.

  55. def isEmpty: Boolean

    Tests whether this iterator is empty.

  56. def isInstanceOf[T0]: Boolean

    This method is used to test whether the dynamic type of the receiver object is T0.

  57. def isNewline(ch: Char): Boolean

  58. def isTraversableAgain: Boolean

    Tests whether this Iterator can be repeatedly traversed.

  59. lazy val iter: BufferedIterator[Char]

  60. def length: Int

    Returns the number of elements in this iterator.

  61. def map[B](f: (String) ⇒ B): Iterator[B]

    Creates a new iterator that maps all produced values of this iterator to new values using a transformation function.

  62. def max: String

    [use case] Finds the largest element.

  63. def max[B >: String](implicit cmp: Ordering[B]): String

    Finds the largest element.

  64. def min: String

    [use case] Finds the smallest element.

  65. def min[B >: String](implicit cmp: Ordering[B]): String

    Finds the smallest element.

  66. def mkString: String

    Displays all elements of this traversable or iterator in a string.

  67. def mkString(sep: String): String

    Displays all elements of this traversable or iterator in a string using a separator string.

  68. def mkString(start: String, sep: String, end: String): String

    Displays all elements of this traversable or iterator in a string using start, end, and separator strings.

  69. def ne(arg0: AnyRef): Boolean

    o.ne(arg0) is the same as !(o.eq(arg0)).

  70. def next(): String

    Produces the next element of this iterator.

  71. def nonEmpty: Boolean

    Tests whether the traversable or iterator is not empty.

  72. def notify(): Unit

    Wakes up a single thread that is waiting on the receiver object's monitor.

  73. def notifyAll(): Unit

    Wakes up all threads that are waiting on the receiver object's monitor.

  74. def padTo(len: Int, elem: String): Iterator[String]

    [use case] Appends an element value to this iterator until a given target length is reached.

  75. def padTo[A1 >: String](len: Int, elem: A1): Iterator[A1]

    Appends an element value to this iterator until a given target length is reached.

  76. def partition(p: (String) ⇒ Boolean): (Iterator[String], Iterator[String])

    Partitions this iterator in two iterators according to a predicate.

  77. def patch[B >: String](from: Int, patchElems: Iterator[B], replaced: Int): Iterator[B]

    Returns this iterator with patched values.

  78. def product: Int

    [use case] Multiplies up the elements of this collection.

  79. def product[B >: String](implicit num: Numeric[B]): B

    Multiplies up the elements of this collection.

  80. def readInto[B >: String](xs: Array[B]): Unit

  81. def readInto[B >: String](xs: Array[B], start: Int): Unit

  82. def readInto[B >: String](xs: Array[B], start: Int, sz: Int): Unit

    Fills the given array xs with the elements of this sequence starting at position start.

  83. def reduceLeft[B >: String](op: (B, String) ⇒ B): B

    Applies a binary operator to all elements of this traversable or iterator, going left to right.

  84. def reduceLeftOption[B >: String](op: (B, String) ⇒ B): Option[B]

    Optionally applies a binary operator to all elements of this traversable or iterator, going left to right.

  85. def reduceRight[B >: String](op: (String, B) ⇒ B): B

    Applies a binary operator to all elements of this traversable or iterator, going right to left.

  86. def reduceRightOption[B >: String](op: (String, B) ⇒ B): Option[B]

    Optionally applies a binary operator to all elements of this traversable or iterator, going right to left.

  87. def reversed: List[String]

  88. def sameElements(that: Iterator[_]): Boolean

    Tests if another iterator produces the same values as this one.

  89. def size: Int

    The size of this traversable or iterator.

  90. def slice(from: Int, until: Int): Iterator[String]

    Creates an iterator returning an interval of the values produced by this iterator.

  91. def sliding[B >: String](size: Int, step: Int = 1): GroupedIterator[B]

    Returns an iterator which presents a "sliding window" view of another iterator.

  92. def sum: Int

    [use case] Sums up the elements of this collection.

  93. def sum[B >: String](implicit num: Numeric[B]): B

    Sums up the elements of this collection.

  94. def synchronized[T0](arg0: T0): T0

  95. def take(n: Int): Iterator[String]

    Selects first n values of this iterator.

  96. def takeWhile(p: (String) ⇒ Boolean): Iterator[String]

    Takes longest prefix of values produced by this iterator that satisfy a predicate.

  97. def toArray: Array[String]

    [use case] Converts this traversable or iterator to an array.

  98. def toArray[B >: String](implicit arg0: ClassManifest[B]): Array[B]

    Converts this traversable or iterator to an array.

  99. def toBuffer[B >: String]: Buffer[B]

    Converts this traversable or iterator to a mutable buffer.

  100. def toIndexedSeq[B >: String]: IndexedSeq[B]

    Converts this traversable or iterator to an indexed sequence.

  101. def toIterable: Iterable[String]

    Converts this traversable or iterator to an iterable collection.

  102. def toIterator: Iterator[String]

    Returns an Iterator over the elements in this traversable or iterator.

  103. def toList: List[String]

    Converts this traversable or iterator to a list.

  104. def toMap[T, U](implicit ev: <:<[String, (T, U)]): Map[T, U]

    Converts this traversable or iterator to a map.

  105. def toSeq: Seq[String]

    Converts this traversable or iterator to a sequence.

  106. def toSet[B >: String]: Set[B]

    Converts this traversable or iterator to a set.

  107. def toStream: Stream[String]

    Converts this traversable or iterator to a stream.

  108. def toString(): String

    Converts this iterator to a string.

  109. def toTraversable: Traversable[String]

    Converts this traversable or iterator to an unspecified Traversable.

  110. def wait(): Unit

  111. def wait(arg0: Long, arg1: Int): Unit

  112. def wait(arg0: Long): Unit

  113. def withFilter(p: (String) ⇒ Boolean): Iterator[String]

    Creates an iterator over all the elements of this iterator that satisfy the predicate p.

  114. def zip[B](that: Iterator[B]): Iterator[(String, B)]

    Creates an iterator formed from this iterator and another iterator by combining corresponding values in pairs.

  115. def zipAll[B](that: Iterator[B], thisElem: String, thatElem: B): Iterator[(String, B)]

    [use case] Creates an iterator formed from this iterator and another iterator by combining corresponding elements in pairs.

  116. def zipAll[B, A1 >: String, B1 >: B](that: Iterator[B], thisElem: A1, thatElem: B1): Iterator[(A1, B1)]

    Creates an iterator formed from this iterator and another iterator by combining corresponding elements in pairs.

  117. def zipWithIndex: Iterator[(String, Int)] {...}

    Creates an iterator that pairs each element produced by this iterator with its index, counting from 0.