abstract class Stream[F[_], A] extends AnyRef
Ordering
- Alphabetic
- By Inheritance
Inherited
- Stream
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- Protected
Concrete Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- def ++(rhs: Stream[F, A]): Stream[F, A]
- See also
concat
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def buffer(duration: FiniteDuration, maxSize: Int = 16)(implicit scheduler: Scheduler[F], ec: ExecutionContext): Stream[F, Seq[A]]
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
- def collect[B](f: PartialFunction[A, B]): Stream[F, B]
- def concat(rhs: Stream[F, A]): Stream[F, A]
Sequently concat two streams
Sequently concat two streams
Stream(1,2,3) ++ Stream(4,5,6) // 1,2,3,4,5,6
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- def flatMap[B](f: (A) => Stream[F, B]): Stream[F, B]
- See also
flatMapConcat
- def flatMapAsync[B](f: (A) => F[Stream[F, B]]): Stream[F, B]
- def flatMapConcat[B](f: (A) => Stream[F, B]): Stream[F, B]
Merges underlying streams to one line.
Merges underlying streams to one line.
Stream.eval(1, 2, 3) flatMapConcat { x => Stream.eval(x + "a", x + "b", x + "c") } // 1a,1b,1c,2a,2b,2c,3a,3b,3c
- def flatMapMerge[B](concurrency: Int)(f: (A) => Stream[F, B]): Stream[F, B]
Merges underlying streams concurrently.
Merges underlying streams concurrently.
- concurrency
number of concurrent underlying streams
Stream.eval(1, 2, 3) flatMapMerge(3) { x => Stream.eval(x + "a", x + "b", x + "c") } // 1a,2a,3a,1b,2b,3b,1c,2c,3c
- def flatMapMergeAsync[B](concurrency: Int)(f: (A) => F[Stream[F, B]]): Stream[F, B]
- def fold[B](default: B)(f: (B, A) => B): F[B]
- def foldAsync[B](default: B)(f: (B, A) => F[B]): F[B]
- def foreach(f: (A) => F[Unit]): F[Unit]
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- def handleConsumed: (F[Unit], Stream[F, A])
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def map[B](f: (A) => B): Stream[F, B]
- def mapAsync[B](f: (A) => F[B]): Stream[F, B]
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- def over[B](default: B)(f: (B, Option[A]) => F[B]): Stream[F, A]
React on values of the stream keeping it the same.
React on values of the stream keeping it the same. Useful when you want to track progress of downloading.
file .over(0L) { case (acc, chunk) => val loaded = chunk.fold(acc)(_.length.toLong + acc) showProgress(loaded, file.bytesLength) } .to(s3bucket("my-large-file"))
- def sort(numRacks: Int)(f: (A) => Int): List[Stream[F, A]]
Sort elements of the stream between "racks".
Sort elements of the stream between "racks".
val List(girls, boys, queers) = persons.sort(3) { case person if person.isFemale => 0 case person if person.isMale => 1 case person => 2 }
- numRacks
Number of racks.
- f
Takes element of the stream return number of rack.
- returns
List of streams appropriate to racks.
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def to[U](f: (Stream[F, A]) => F[U]): F[U]
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated