Class/Object

fs2

Pull

Related Docs: object Pull | package fs2

Permalink

final class Pull[+F[_], +O, +R] extends AnyVal

A p: Pull[F,O,R] reads values from one or more streams, returns a result of type R, and produces a Stream[F,O] when calling p.stream.

Any resources acquired by p are freed following the call to stream.

Laws:

Pull forms a monad in R with pure and flatMap:

raiseError is caught by handleErrorWith:

Source
Pull.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Pull
  2. AnyVal
  3. Any
Implicitly
  1. by covaryPure
  2. by any2stringadd
  3. by StringFormat
  4. by Ensuring
  5. 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 Pull[F, O, R] to any2stringadd[Pull[F, O, R]] performed by method any2stringadd in scala.Predef.
    Definition Classes
    any2stringadd
  4. def ->[B](y: B): (Pull[F, O, R], B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to ArrowAssoc[Pull[F, O, R]] performed by method ArrowAssoc in scala.Predef. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Definition Classes
    ArrowAssoc
    Annotations
    @inline()
  5. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    Any
  6. def >>[F2[x] >: F[x], O2 >: O, R2](p2: ⇒ Pull[F2, O2, R2]): Pull[F2, O2, R2]

    Permalink

    Alias for flatMap(_ => p2).

    Alias for flatMap(_ => p2).

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
  7. def >>[F2[x] >: F[x], O2 >: O, R2](p2: ⇒ Pull[F2, O2, R2]): Pull[F2, O2, R2]

    Permalink

    Alias for flatMap(_ => p2).

  8. def as[R2](r2: R2): Pull[F, O, R2]

    Permalink

    Alias for _.map(_ => o2).

  9. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  10. def attempt: Pull[F, O, Either[Throwable, R]]

    Permalink

    Returns a pull with the result wrapped in Right, or an error wrapped in Left if the pull has failed.

  11. def covary[F2[x] >: F[x]]: Pull[F2, O, R]

    Permalink

    Lifts this pull to the specified effect type.

  12. def covaryAll[F2[x] >: F[x], O2 >: O, R2 >: R]: Pull[F2, O2, R2]

    Permalink

    Lifts this pull to the specified effect type, output type, and resource type.

  13. def covaryOutput[O2 >: O]: Pull[F, O2, R]

    Permalink

    Lifts this pull to the specified output type.

  14. def covaryResource[R2 >: R]: Pull[F, O, R2]

    Permalink

    Lifts this pull to the specified resource type.

  15. def ensuring(cond: (Pull[F, O, R]) ⇒ Boolean, msg: ⇒ Any): Pull[F, O, R]

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

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

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

    Permalink
    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Ensuring[Pull[F, O, R]] performed by method Ensuring in scala.Predef.
    Definition Classes
    Ensuring
  19. def flatMap[F2[x] >: F[x], O2 >: O, R2](f: (R) ⇒ Pull[F2, O2, R2]): Pull[F2, O2, R2]

    Permalink

    Applies the resource of this pull to f and returns the result.

    Applies the resource of this pull to f and returns the result.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
  20. def flatMap[F2[x] >: F[x], O2 >: O, R2](f: (R) ⇒ Pull[F2, O2, R2]): Pull[F2, O2, R2]

    Permalink

    Applies the resource of this pull to f and returns the result.

  21. def formatted(fmtstr: String): String

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

    Permalink
    Definition Classes
    AnyVal → Any
  23. def handleErrorWith[F2[x] >: F[x], O2 >: O, R2 >: R](h: (Throwable) ⇒ Pull[F2, O2, R2]): Pull[F2, O2, R2]

    Permalink

    If this terminates with Pull.raiseError(e), invoke h(e).

    If this terminates with Pull.raiseError(e), invoke h(e).

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
  24. def handleErrorWith[F2[x] >: F[x], O2 >: O, R2 >: R](h: (Throwable) ⇒ Pull[F2, O2, R2]): Pull[F2, O2, R2]

    Permalink

    If this terminates with Pull.raiseError(e), invoke h(e).

  25. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  26. def map[R2](f: (R) ⇒ R2): Pull[F, O, R2]

    Permalink

    Applies the resource of this pull to f and returns the result in a new Pull.

  27. def onComplete[F2[x] >: F[x], O2 >: O, R2 >: R](p2: ⇒ Pull[F2, O2, R2]): Pull[F2, O2, R2]

    Permalink

    Run p2 after this, regardless of errors during this, then reraise any errors encountered during this.

    Run p2 after this, regardless of errors during this, then reraise any errors encountered during this.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
  28. def onComplete[F2[x] >: F[x], O2 >: O, R2 >: R](p2: ⇒ Pull[F2, O2, R2]): Pull[F2, O2, R2]

    Permalink

    Run p2 after this, regardless of errors during this, then reraise any errors encountered during this.

  29. def scope: Pull[F, O, Unit]

    Permalink

    Tracks any resources acquired during this pull and releases them when the pull completes.

  30. def stream: Stream[F, O]

    Permalink

    Interpret this Pull to produce a Stream.

    Interpret this Pull to produce a Stream. The result type R is discarded.

  31. def toString(): String

    Permalink
    Definition Classes
    Any
  32. def [B](y: B): (Pull[F, O, R], B)

    Permalink
    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to ArrowAssoc[Pull[F, O, R]] performed by method ArrowAssoc in scala.Predef. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Definition Classes
    ArrowAssoc

Shadowed Implicit Value Members

  1. def as[R2](r2: R2): Pull[Nothing, O, R2]

    Permalink

    Alias for _.map(_ => o2).

    Alias for _.map(_ => o2).

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Shadowing
    This implicitly inherited member is shadowed by one or more members in this class.
    To access this member you can use a type ascription:
    (pull: Pull[Nothing, O, R]).as(r2)
  2. def attempt: Pull[Nothing, O, Either[Throwable, R]]

    Permalink

    Returns a pull with the result wrapped in Right, or an error wrapped in Left if the pull has failed.

    Returns a pull with the result wrapped in Right, or an error wrapped in Left if the pull has failed.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Shadowing
    This implicitly inherited member is shadowed by one or more members in this class.
    To access this member you can use a type ascription:
    (pull: Pull[Nothing, O, R]).attempt
  3. def covary[F2[x] >: F[x]]: Pull[F2, O, R]

    Permalink

    Lifts this pull to the specified effect type.

    Lifts this pull to the specified effect type.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Shadowing
    This implicitly inherited member is shadowed by one or more members in this class.
    To access this member you can use a type ascription:
    (pull: Pull[Nothing, O, R]).covary
  4. def covaryAll[F2[x] >: F[x], O2 >: O, R2 >: R]: Pull[F2, O2, R2]

    Permalink

    Lifts this pull to the specified effect type, output type, and resource type.

    Lifts this pull to the specified effect type, output type, and resource type.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Shadowing
    This implicitly inherited member is shadowed by one or more members in this class.
    To access this member you can use a type ascription:
    (pull: Pull[Nothing, O, R]).covaryAll
  5. def covaryOutput[O2 >: O]: Pull[Nothing, O2, R]

    Permalink

    Lifts this pull to the specified output type.

    Lifts this pull to the specified output type.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Shadowing
    This implicitly inherited member is shadowed by one or more members in this class.
    To access this member you can use a type ascription:
    (pull: Pull[Nothing, O, R]).covaryOutput
  6. def covaryResource[R2 >: R]: Pull[Nothing, O, R2]

    Permalink

    Lifts this pull to the specified resource type.

    Lifts this pull to the specified resource type.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Shadowing
    This implicitly inherited member is shadowed by one or more members in this class.
    To access this member you can use a type ascription:
    (pull: Pull[Nothing, O, R]).covaryResource
  7. def map[R2](f: (R) ⇒ R2): Pull[Nothing, O, R2]

    Permalink

    Applies the resource of this pull to f and returns the result in a new Pull.

    Applies the resource of this pull to f and returns the result in a new Pull.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Shadowing
    This implicitly inherited member is shadowed by one or more members in this class.
    To access this member you can use a type ascription:
    (pull: Pull[Nothing, O, R]).map(f)
  8. def scope: Pull[Nothing, O, Unit]

    Permalink

    Tracks any resources acquired during this pull and releases them when the pull completes.

    Tracks any resources acquired during this pull and releases them when the pull completes.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Shadowing
    This implicitly inherited member is shadowed by one or more members in this class.
    To access this member you can use a type ascription:
    (pull: Pull[Nothing, O, R]).scope
  9. def stream: Stream[Nothing, O]

    Permalink

    Interpret this Pull to produce a Stream.

    Interpret this Pull to produce a Stream. The result type R is discarded.

    Implicit information
    This member is added by an implicit conversion from Pull[F, O, R] to Pull[Nothing, O, R] performed by method covaryPure in fs2.Pull. This conversion will take place only if F is a subclass of Pure (F <: Pure).
    Shadowing
    This implicitly inherited member is shadowed by one or more members in this class.
    To access this member you can use a type ascription:
    (pull: Pull[Nothing, O, R]).stream

Inherited from AnyVal

Inherited from Any

Inherited by implicit conversion covaryPure from Pull[F, O, R] to Pull[Nothing, O, R]

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

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

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

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

Ungrouped