MonadCatchIO

Companion
class
class Object
trait Matchable
class Any

Value members

Concrete methods

@inline
def apply[F[_]](implicit F: MonadCatchIO[F]): MonadCatchIO[F]
def bracket[M[_] : MonadCatchIO, A, B, C](before: M[A])(after: A => M[B])(during: A => M[C]): M[C]
def bracketOnError[M[_] : MonadCatchIO, A, B, C](before: M[A])(after: A => M[B])(during: A => M[C]): M[C]

A variant of "bracket" that performs the final action only if there was an error.

A variant of "bracket" that performs the final action only if there was an error.

def bracket_[M[_] : MonadCatchIO, A, B, C](before: M[A])(after: M[B])(during: M[C]): M[C]

A variant of "bracket" where the return value of this computation is not needed.

A variant of "bracket" where the return value of this computation is not needed.

def catchLeft[M[_] : MonadCatchIO, A](ma: M[A]): M[Throwable \/ A]

Returns a disjunction result which is right if no exception was raised, or left if an exception was raised.

Returns a disjunction result which is right if no exception was raised, or left if an exception was raised.

def catchSome[M[_] : MonadCatchIO, A, B](ma: M[A])(p: Throwable => Option[B], handler: B => M[A]): M[A]

Executes the handler for exceptions that are raised and match the given predicate. Other exceptions are rethrown.

Executes the handler for exceptions that are raised and match the given predicate. Other exceptions are rethrown.

def catchSomeLeft[M[_] : MonadCatchIO, A, B](ma: M[A])(p: Throwable => Option[B]): M[B \/ A]

Like "catchLeft" but takes a predicate to select which exceptions are caught.

Like "catchLeft" but takes a predicate to select which exceptions are caught.

def ensuring[M[_] : MonadCatchIO, A, B](ma: M[A], sequel: M[B]): M[A]

Like "bracket", but takes only a computation to run afterward. Generalizes "finally".

Like "bracket", but takes only a computation to run afterward. Generalizes "finally".

def except[M[_], A](ma: M[A])(handler: Throwable => M[A])(implicit M: MonadCatchIO[M]): M[A]
def fromIso[F[_], G[_]](D: IsoFunctor[F, G])(implicit E: MonadCatchIO[G]): MonadCatchIO[F]
def onException[M[_] : MonadCatchIO, A, B](ma: M[A], action: M[B]): M[A]

Like "finally", but only performs the final action if there was an exception.

Like "finally", but only performs the final action if there was an exception.

def using[M[_], A, B](ma: M[A])(f: A => M[B])(implicit M: MonadCatchIO[M], resource: Resource[A]): M[B]

An automatic resource management.

An automatic resource management.

Implicits

Implicits

implicit
def KleisliMonadCatchIO[F[_], R](implicit F: MonadCatchIO[F]): MonadCatchIO[[_] =>> Kleisli[F, R, _$25]]
implicit
def theseTMonadCatchIO[M[_] : MonadCatchIO, E : Semigroup]: MonadCatchIO[[_] =>> TheseT[M, E, _$6]]