Exit

zio.Exit
See theExit companion trait
object Exit extends Serializable

Attributes

Companion
trait
Graph
Supertypes
trait Sum
trait Mirror
trait Serializable
class Object
trait Matchable
class Any
Show all
Self type
Exit.type

Members list

Type members

Classlikes

final case class Failure[+E](cause: Cause[E]) extends Exit[E, Nothing]

Attributes

Supertypes
trait Exit[E, Nothing]
trait ZIO[Any, E, Nothing]
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
final case class Success[+A](value: A) extends Exit[Nothing, A]

Attributes

Supertypes
trait Exit[Nothing, A]
trait ZIO[Any, Nothing, A]
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Inherited and Abstract types

The names of the product elements

The names of the product elements

Attributes

Inherited from:
Mirror

The name of the type

The name of the type

Attributes

Inherited from:
Mirror

Value members

Concrete methods

def collectAll[E, A](exits: Iterable[Exit[E, A]]): Option[Exit[E, List[A]]]

Collects all Exits, and returns a List of the values if all Exits succeeded, or combines the causes sequentially in case of failures. Returns None in case the input iterable is empty

Collects all Exits, and returns a List of the values if all Exits succeeded, or combines the causes sequentially in case of failures. Returns None in case the input iterable is empty

Attributes

See also

collectAllParDiscard For a more performant variant that discard the successful values

def collectAllDiscard[E, A](exits: Iterable[Exit[E, A]]): Exit[E, Unit]

Collects all Exits, and succeeds with Unit if all Exits succeeded, or combines the causes sequentially in case of failures.

Collects all Exits, and succeeds with Unit if all Exits succeeded, or combines the causes sequentially in case of failures.

Attributes

def collectAllPar[E, A](exits: Iterable[Exit[E, A]]): Option[Exit[E, List[A]]]

Collects all Exits, and returns a List of the values if all Exits succeeded, or combines the causes in parallel in case of failures. Returns None in case the input iterable is empty

Collects all Exits, and returns a List of the values if all Exits succeeded, or combines the causes in parallel in case of failures. Returns None in case the input iterable is empty

Attributes

See also

collectAllParDiscard For a more performant variant that discard the successful values

def collectAllParDiscard[E, A](exits: Iterable[Exit[E, A]]): Exit[E, Unit]

Collects all Exits, and succeeds with Unit if all Exits succeeded, or combines the causes in parallel in case of failures.

Collects all Exits, and succeeds with Unit if all Exits succeeded, or combines the causes in parallel in case of failures.

Attributes

def die(t: Throwable): Exit[Nothing, Nothing]
def fail[E](error: E): Exit[E, Nothing]
def failCause[E](cause: Cause[E]): Exit[E, Nothing]
def flatten[E, A](exit: Exit[E, Exit[E, A]]): Exit[E, A]
def fromEither[E, A](e: Either[E, A]): Exit[E, A]
def fromOption[A](o: Option[A]): Exit[Unit, A]
def fromTry[A](t: Try[A]): Exit[Throwable, A]
def interrupt(id: FiberId): Exit[Nothing, Nothing]
def succeed[A](a: A): Exit[Nothing, A]

Concrete fields

val unit: Exit[Nothing, Unit]