LanguageExt.Core

LanguageExt.Core Effects Eff

Contents

Sub modules

Catch
Extensions
Prelude

struct Eff <RT, A> Source #

where RT : struct

Synchronous IO monad

Methods

method Fin<A> Run (RT env) Source #

Invoke the effect

method Unit RunUnit (RT env) Source #

Invoke the effect

Throws on error

method Eff<RT, A> Memo () Source #

Memoise the result, so subsequent calls don't invoke the side-effect

method Eff<RT, A> EffectMaybe (Func<RT, Fin<A>> f) Source #

Lift a synchronous effect into the IO monad

method Eff<RT, A> Effect (Func<RT, A> f) Source #

Lift a synchronous effect into the IO monad

method Eff<RT, A> Success (A value) Source #

Lift a value into the IO monad

method Eff<RT, A> Fail (Error error) Source #

Lift a failure into the IO monad

Operators

operator | (Eff<RT, A> ma, Eff<RT, A> mb) Source #

operator | (Eff<RT, A> ma, Eff<A> mb) Source #

operator | (Eff<A> ma, Eff<RT, A> mb) Source #

operator | (Eff<RT, A> ma, EffCatch<RT, A> mb) Source #

operator | (Eff<RT, A> ma, EffCatch<A> mb) Source #

operator | (Eff<RT, A> ma, CatchValue<A> value) Source #

operator | (Eff<RT, A> ma, CatchError value) Source #

class EffGuards Source #

Methods

method Eff<B> SelectMany <B> (this Guard<Error> ma, Func<Unit, Eff<B>> f) Source #

method Eff<RT, B> SelectMany <RT, B> (this Guard<Error> ma, Func<Unit, Eff<RT, B>> f) Source #

where RT : struct

method Eff<C> SelectMany <B, C> (this Guard<Error> ma, Func<Unit, Eff<B>> bind, Func<Unit, B, C> project) Source #

method Eff<RT, C> SelectMany <RT, B, C> (this Guard<Error> ma, Func<Unit, Eff<RT, B>> bind, Func<Unit, B, C> project) Source #

where RT : struct

method Eff<Unit> ToEff (this Guard<Error> ma) Source #

method Eff<RT, Unit> ToEff <RT> (this Guard<Error> ma) Source #

where RT : struct

method Eff<Unit> SelectMany <A> (this Eff<A> ma, Func<A, Guard<Error>> f) Source #

method Eff<RT, Unit> SelectMany <RT, A> (this Eff<RT, A> ma, Func<A, Guard<Error>> f) Source #

where RT : struct

method Eff<C> SelectMany <A, C> (this Eff<A> ma, Func<A, Guard<Error>> bind, Func<A, Unit, C> project) Source #

method Eff<RT, C> SelectMany <RT, A, C> (this Eff<RT, A> ma, Func<A, Guard<Error>> bind, Func<A, Unit, C> project) Source #

where RT : struct

struct Eff <A> Source #

Synchronous IO monad

Methods

method Fin<A> Run () Source #

Invoke the effect

method Unit RunUnit () Source #

Invoke the effect

Throws on error

method Eff<A> Memo () Source #

Memoise the result, so subsequent calls don't invoke the side-effect

method Eff<A> EffectMaybe (Func<Fin<A>> f) Source #

Lift a synchronous effect into the IO monad

method Eff<A> Effect (Func<A> f) Source #

Lift a synchronous effect into the IO monad

method Eff<A> Success (A value) Source #

Lift a value into the IO monad

method Eff<A> Fail (Error error) Source #

Lift a failure into the IO monad

method Eff<RT, A> WithRuntime <RT> () Source #

where RT : struct

method Aff<A> ToAff () Source #

method Aff<RT, A> ToAffWithRuntime <RT> () Source #

where RT : struct, HasCancel<RT>

method S Fold <S> (S state, Func<S, A, S> f) Source #

method bool Exists (Func<A, bool> f) Source #

method bool ForAll (Func<A, bool> f) Source #

Operators

operator | (Eff<A> ma, Eff<A> mb) Source #

operator | (Eff<A> ma, EffCatch<A> mb) Source #

operator | (Eff<A> ma, AffCatch<A> mb) Source #

operator | (Eff<A> ma, CatchValue<A> value) Source #

operator | (Eff<A> ma, CatchError value) Source #