in scala
object Stream

`object` Stream
  `extends` java.lang.Object
  `with` scala.ScalaObject

  The object `Stream` provides helper functions to manipulate streams.

Author:
  Martin Odersky, Matthias Zenger
Version:
  1.1 08/08/03

Constructor Summary
| `def` this

Val Summary
| `val` empty : scala.Stream[scala.Nothing] The empty stream

Def Summary
| `def` concat [a] (s1: scala.Stream[a], s2: scala.Stream[a], ss: scala.Stream[a]*) : scala.Stream[a] The concatenation of all given streams
| `def` concat [a] (xs: scala.Iterable[scala.Stream[a]]) : scala.Stream[a] The concatenation of a sequence of streams
| `def` concat [a] (xs: scala.Iterator[scala.Stream[a]]) : scala.Stream[a] The concatenation of all streams returned by an iterator
| `def` cons [a] (hd: a, tl: => scala.Stream[a]) : java.lang.Object with scala.Stream[a] A stream consisting of a given first element and remaining elements
| `def` from (start: scala.Int) : scala.Stream[scala.Int] Create an infinite stream starting at `start` and incrementing by 1.
| `def` from (start: scala.Int, step: scala.Int) : scala.Stream[scala.Int] Create an infinite stream starting at `start` and incrementing by step `step`
| `def` fromIterator [a] (it: scala.Iterator[a]) : scala.Stream[a] A stream containing all elements of a given iterator, in the order they are produced.
| `def` range (start: scala.Int, end: scala.Int) : scala.Stream[scala.Int] Create a stream with element values `vn+1 = vn + 1` where `v0 = start` and `vi < end`.
| `def` range (start: scala.Int, end: scala.Int, step: (scala.Int) => scala.Int) : scala.Stream[scala.Int] Create a stream with element values `vn+1 = step(vn)` where `v0 = start` and `vi < end`.
| `def` range (start: scala.Int, end: scala.Int, step: scala.Int) : scala.Stream[scala.Int] Create a stream with element values `vn+1 = vn + step` where `v0 = start` and `vi < end`.

Constructor Detail

`def` this

Val Detail

`val` empty : scala.Stream[scala.Nothing]

  The empty stream

Def Detail

`def` concat [a](s1: scala.Stream[a], s2: scala.Stream[a], ss: scala.Stream[a]*): scala.Stream[a]

  The concatenation of all given streams

`def` concat [a](xs: scala.Iterable[scala.Stream[a]]): scala.Stream[a]

  The concatenation of a sequence of streams

`def` concat [a](xs: scala.Iterator[scala.Stream[a]]): scala.Stream[a]

  The concatenation of all streams returned by an iterator

`def` cons [a](hd: a, tl: => scala.Stream[a]): java.lang.Object with scala.Stream[a]

  A stream consisting of a given first element and remaining elements

Parameters:
  `hd -` The first element of the result stream
Parameters:
  `tl -` The remaining elements of the result stream

`def` from (start: scala.Int): scala.Stream[scala.Int]

  Create an infinite stream starting at `start` and incrementing by 1.

Parameters:
  `start -` the start value of the stream
Returns:
  the stream starting at value `start`.

`def` from (start: scala.Int, step: scala.Int): scala.Stream[scala.Int]

  Create an infinite stream starting at `start` and incrementing by step `step`

Parameters:
  `start -` the start value of the stream
Parameters:
  `step -` the increment value of the stream
Returns:
  the stream starting at value `start`.

`def` fromIterator [a](it: scala.Iterator[a]): scala.Stream[a]

  A stream containing all elements of a given iterator, in the order they are produced.

Parameters:
  `it -` The iterator producing the stream's elements

`def` range (start: scala.Int, end: scala.Int): scala.Stream[scala.Int]

  Create a stream with element values `vn+1 = vn + 1` where `v0 = start` and `vi < end`.

Parameters:
  `start -` the start value of the stream
Parameters:
  `end -` the end value of the stream
Returns:
  the stream starting at value `start`.

`def` range (start: scala.Int, end: scala.Int, step: (scala.Int) => scala.Int): scala.Stream[scala.Int]

  Create a stream with element values `vn+1 = step(vn)` where `v0 = start` and `vi < end`.

Parameters:
  `start -` the start value of the stream
Parameters:
  `end -` the end value of the stream
Parameters:
  `step -` the increment function of the stream
Returns:
  the stream starting at value `start`.

`def` range (start: scala.Int, end: scala.Int, step: scala.Int): scala.Stream[scala.Int]

  Create a stream with element values `vn+1 = vn + step` where `v0 = start` and `vi < end`.

Parameters:
  `start -` the start value of the stream
Parameters:
  `end -` the end value of the stream
Parameters:
  `step -` the increment value of the stream
Returns:
  the stream starting at value `start`.