trait WithDefault[F] extends Simple[F]
Provides companion object methods for result types that have a sane default error type.
This default error type is materialised by fromThrowable.
- Source
- ResultCompanion.scala
- Alphabetic
- By Inheritance
- WithDefault
- Simple
- Simple
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Concrete Value Members
- def apply[S](s: => S): Either[F, S]
Attempts to evaluate the specified expression.
Attempts to evaluate the specified expression.
- Annotations
- @inline()
- def failure(f: F): Either[F, Nothing]
Turns the specified value into a failure.
Turns the specified value into a failure.
- Definition Classes
- Simple
- Annotations
- @inline()
- def fromTry[S](t: Try[S]): Either[F, S]
Turns the specified
Try
into a result.Turns the specified
Try
into a result.- Annotations
- @inline()
- def sequence[S, M[X] <: IterableOnce[X]](rs: M[Either[F, S]])(implicit bf: BuildFrom[M[Either[F, S]], S, M[S]]): Either[F, M[S]]
Turns a collection of results into a result of a collection.
Turns a collection of results into a result of a collection.
- Definition Classes
- Simple
- Annotations
- @inline()
- def success[S](s: S): Either[F, S]
Turns the specified value into a success.
Turns the specified value into a success.
- Definition Classes
- Simple
- Annotations
- @inline()