Class

fs2.Stream

ToPull

Related Doc: package Stream

Permalink

final class ToPull[F[_], O] extends AnyVal

Projection of a Stream providing various ways to get a Pull from the Stream.

Source
Stream.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. ToPull
  2. AnyVal
  3. Any
Implicitly
  1. by any2stringadd
  2. by StringFormat
  3. by Ensuring
  4. by ArrowAssoc
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    Any
  3. def +(other: String): String

    Permalink
    Implicit information
    This member is added by an implicit conversion from ToPull[F, O] to any2stringadd[ToPull[F, O]] performed by method any2stringadd in scala.Predef.
    Definition Classes
    any2stringadd
  4. def ->[B](y: B): (ToPull[F, O], B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from ToPull[F, O] to ArrowAssoc[ToPull[F, O]] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc
    Annotations
    @inline()
  5. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  6. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  7. def drop(n: Long): Pull[F, Nothing, Option[Stream[F, O]]]

    Permalink

    Drops the first n elements of this Stream, and returns the new Stream.

  8. def dropThrough(p: (O) ⇒ Boolean): Pull[F, Nothing, Option[Stream[F, O]]]

    Permalink

    Like dropWhile, but drops the first value which tests false.

  9. def dropWhile(p: (O) ⇒ Boolean): Pull[F, Nothing, Option[Stream[F, O]]]

    Permalink

    Drops elements of the this stream until the predicate p fails, and returns the new stream.

    Drops elements of the this stream until the predicate p fails, and returns the new stream. If defined, the first element of the returned stream will fail p.

  10. def echo: Pull[F, O, Unit]

    Permalink

    Writes all inputs to the output of the returned Pull.

  11. def echo1: Pull[F, O, Option[Stream[F, O]]]

    Permalink

    Reads a single element from the input and emits it to the output.

    Reads a single element from the input and emits it to the output. Returns the new Handle.

  12. def echoSegment: Pull[F, O, Option[Stream[F, O]]]

    Permalink

    Reads the next available segment from the input and emits it to the output.

    Reads the next available segment from the input and emits it to the output. Returns the new Handle.

  13. def ensuring(cond: (ToPull[F, O]) ⇒ Boolean, msg: ⇒ Any): ToPull[F, O]

    Permalink
    Implicit information
    This member is added by an implicit conversion from ToPull[F, O] to Ensuring[ToPull[F, O]] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  14. def ensuring(cond: (ToPull[F, O]) ⇒ Boolean): ToPull[F, O]

    Permalink
    Implicit information
    This member is added by an implicit conversion from ToPull[F, O] to Ensuring[ToPull[F, O]] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  15. def ensuring(cond: Boolean, msg: ⇒ Any): ToPull[F, O]

    Permalink
    Implicit information
    This member is added by an implicit conversion from ToPull[F, O] to Ensuring[ToPull[F, O]] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  16. def ensuring(cond: Boolean): ToPull[F, O]

    Permalink
    Implicit information
    This member is added by an implicit conversion from ToPull[F, O] to Ensuring[ToPull[F, O]] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  17. def fetchN(n: Int): Pull[F, Nothing, Option[Stream[F, O]]]

    Permalink

    Like unconsN, but leaves the buffered input unconsumed.

  18. def find(f: (O) ⇒ Boolean): Pull[F, Nothing, Option[(O, Stream[F, O])]]

    Permalink

    Awaits the next available element where the predicate returns true.

  19. def fold[O2](z: O2)(f: (O2, O) ⇒ O2): Pull[F, Nothing, O2]

    Permalink

    Folds all inputs using an initial value z and supplied binary operator, and writes the final result to the output of the supplied Pull when the stream has no more values.

  20. def fold1[O2 >: O](f: (O2, O2) ⇒ O2): Pull[F, Nothing, Option[O2]]

    Permalink

    Folds all inputs using the supplied binary operator, and writes the final result to the output of the supplied Pull when the stream has no more values.

  21. def forall(p: (O) ⇒ Boolean): Pull[F, Nothing, Boolean]

    Permalink

    Writes a single true value if all input matches the predicate, false otherwise.

  22. def formatted(fmtstr: String): String

    Permalink
    Implicit information
    This member is added by an implicit conversion from ToPull[F, O] to StringFormat[ToPull[F, O]] performed by method StringFormat in scala.Predef.
    Definition Classes
    StringFormat
    Annotations
    @inline()
  23. def getClass(): Class[_ <: AnyVal]

    Permalink
    Definition Classes
    AnyVal → Any
  24. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  25. def last: Pull[F, Nothing, Option[O]]

    Permalink

    Returns the last element of the input, if non-empty.

  26. def peek: Pull[F, Nothing, Option[(Segment[O, Unit], Stream[F, O])]]

    Permalink

    Like uncons but does not consume the segment (i.e., the segment is pushed back).

  27. def peek1: Pull[F, Nothing, Option[(O, Stream[F, O])]]

    Permalink

    Like uncons1 but does not consume the element (i.e., the element is pushed back).

  28. def scanSegments[S, O2](init: S)(f: (S, Segment[O, Unit]) ⇒ Segment[O2, S]): Pull[F, O2, S]

    Permalink

    Like scan but f is applied to each segment of the source stream.

    Like scan but f is applied to each segment of the source stream. The resulting segment is emitted and the result of the segment is used in the next invocation of f. The final state value is returned as the result of the pull.

  29. def scanSegmentsOpt[S, O2](init: S)(f: (S) ⇒ Option[(Segment[O, Unit]) ⇒ Segment[O2, S]]): Pull[F, O2, S]

    Permalink

    More general version of scanSegments where the current state (i.e., S) can be inspected to determine if another segment should be pulled or if the pull should terminate.

    More general version of scanSegments where the current state (i.e., S) can be inspected to determine if another segment should be pulled or if the pull should terminate. Termination is signaled by returning None from f. Otherwise, a function which consumes the next segment is returned wrapped in Some. The final state value is returned as the result of the pull.

  30. def take(n: Long): Pull[F, O, Option[Stream[F, O]]]

    Permalink

    Emits the first n elements of the input.

  31. def takeRight(n: Long): Pull[F, Nothing, Chunk[O]]

    Permalink

    Emits the last n elements of the input.

  32. def takeThrough(p: (O) ⇒ Boolean): Pull[F, O, Option[Stream[F, O]]]

    Permalink

    Like takeWhile, but emits the first value which tests false.

  33. def takeWhile(p: (O) ⇒ Boolean, takeFailure: Boolean = false): Pull[F, O, Option[Stream[F, O]]]

    Permalink

    Emits the elements of the stream until the predicate p fails, and returns the remaining Stream.

    Emits the elements of the stream until the predicate p fails, and returns the remaining Stream. If non-empty, the returned stream will have a first element i for which p(i) is false.

  34. def toString(): String

    Permalink
    Definition Classes
    Any
  35. def uncons: Pull[F, Nothing, Option[(Segment[O, Unit], Stream[F, O])]]

    Permalink

    Waits for a segment of elements to be available in the source stream.

    Waits for a segment of elements to be available in the source stream. The segment of elements along with a new stream are provided as the resource of the returned pull. The new stream can be used for subsequent operations, like awaiting again. A None is returned as the resource of the pull upon reaching the end of the stream.

  36. def uncons1: Pull[F, Nothing, Option[(O, Stream[F, O])]]

    Permalink

    Like uncons but waits for a single element instead of an entire segment.

  37. def unconsChunk: Pull[F, Nothing, Option[(Chunk[O], Stream[F, O])]]

    Permalink

    Like uncons but waits for a chunk instead of an entire segment.

  38. def unconsLimit(n: Long): Pull[F, Nothing, Option[(Segment[O, Unit], Stream[F, O])]]

    Permalink

    Like uncons, but returns a segment of no more than n elements.

    Like uncons, but returns a segment of no more than n elements.

    The returned segment has a result tuple consisting of the remaining limit (n minus the segment size, or 0, whichever is larger) and the remainder of the source stream.

    Pull.pure(None) is returned if the end of the source stream is reached.

  39. def unconsN(n: Long, allowFewer: Boolean = false): Pull[F, Nothing, Option[(Segment[O, Unit], Stream[F, O])]]

    Permalink

    Like uncons, but returns a segment of exactly n elements, splitting segments as necessary.

    Like uncons, but returns a segment of exactly n elements, splitting segments as necessary.

    Pull.pure(None) is returned if the end of the source stream is reached.

  40. def [B](y: B): (ToPull[F, O], B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from ToPull[F, O] to ArrowAssoc[ToPull[F, O]] performed by method ArrowAssoc in scala.Predef.
    Definition Classes
    ArrowAssoc

Inherited from AnyVal

Inherited from Any

Inherited by implicit conversion any2stringadd from ToPull[F, O] to any2stringadd[ToPull[F, O]]

Inherited by implicit conversion StringFormat from ToPull[F, O] to StringFormat[ToPull[F, O]]

Inherited by implicit conversion Ensuring from ToPull[F, O] to Ensuring[ToPull[F, O]]

Inherited by implicit conversion ArrowAssoc from ToPull[F, O] to ArrowAssoc[ToPull[F, O]]

Ungrouped