LanguageExt.Core

LanguageExt.Core Effects IO Extensions

Contents

class IOExtensions Source #

Methods

method IO<A> As () Source #

Convert the kind version of the IO monad to an IO monad.

This is a simple cast operation which is just a bit more elegant than manually casting.

Parameters

returns

method A Run () Source #

method A Run (EnvIO envIO) Source #

method Fin<A> RunSafe () Source #

method Fin<A> RunSafe (EnvIO envIO) Source #

method ValueTask<A> RunAsync () Source #

method ValueTask<A> RunAsync (EnvIO envIO) Source #

method ValueTask<Fin<A>> RunSafeAsync () Source #

method ValueTask<Fin<A>> RunSafeAsync (EnvIO envIO) Source #

class IOExtensions Source #

Methods

method IO<B> Map <A, B> (this Func<A, B> f, K<IO, A> ma) Source #

Functor map operation

Unwraps the value within the functor, passes it to the map function f provided, and then takes the mapped value and wraps it back up into a new functor.

Parameters

param ma

Functor to map

param f

Mapping function

returns

Mapped functor

method IO<B> Map <A, B> (this Func<A, B> f, IO<A> ma) Source #

Functor map operation

Unwraps the value within the functor, passes it to the map function f provided, and then takes the mapped value and wraps it back up into a new functor.

Parameters

param ma

Functor to map

param f

Mapping function

returns

Mapped functor

method IO<B> Action <A, B> (this IO<A> ma, IO<B> mb) Source #

Applicative action: runs the first applicative, ignores the result, and returns the second applicative

method IO<B> Apply <A, B> (this IO<Func<A, B>> mf, K<IO, A> ma) Source #

Applicative functor apply operation

Unwraps the value within the ma applicative-functor, passes it to the unwrapped function(s) within mf, and then takes the resulting value and wraps it back up into a new applicative-functor.

Parameters

param ma

Value(s) applicative functor

param mf

Mapping function(s)

returns

Mapped applicative functor

method IO<B> Apply <A, B> (this K<IO, Func<A, B>> mf, K<IO, A> ma) Source #

Applicative functor apply operation

Unwraps the value within the ma applicative-functor, passes it to the unwrapped function(s) within mf, and then takes the resulting value and wraps it back up into a new applicative-functor.

Parameters

param ma

Value(s) applicative functor

param mf

Mapping function(s)

returns

Mapped applicative functor