LanguageExt.Core

LanguageExt.Core Effects Pipes Resource

Contents

class Use <RT, UOut, UIn, DIn, DOut, A> Source #

where RT : struct, HasCancel<RT>

One of the algebraic cases of the Proxy type. This type represents a resource using computation. It is useful for tidying up resources explicitly (if required).

The Proxy system will tidy up resources automatically, however you must wait until the end of the computation. This case allows earlier clean up.

Parameters

type RT

Aff system runtime

type UOut

Upstream out type

type UIn

Upstream in type

type DIn

Downstream in type

type DOut

Downstream uut type

type A

The monadic bound variable - it doesn't flow up or down stream, it works just like any bound monadic variable. If the effect represented by the Proxy ends, then this will be the result value.

When composing Proxy sub-types (like Producer, Pipe, Consumer, etc.)

class Use <RT, UOut, UIn, DIn, DOut, X, A> Source #

where RT : struct, HasCancel<RT>

One of the algebraic cases of the Proxy type. This type represents a resource using computation. It is useful for tidying up resources explicitly (if required).

The Proxy system will tidy up resources automatically, however you must wait until the end of the computation. This case allows earlier clean up.

Parameters

type RT

Aff system runtime

type UOut

Upstream out type

type UIn

Upstream in type

type DIn

Downstream in type

type DOut

Downstream uut type

type A

The monadic bound variable - it doesn't flow up or down stream, it works just like any bound monadic variable. If the effect represented by the Proxy ends, then this will be the result value.

When composing Proxy sub-types (like Producer, Pipe, Consumer, etc.)

Fields

field Func<Aff<RT, X>> Acquire Source #

field Func<X, Unit> Release Source #

field Func<X, Proxy<RT, UOut, UIn, DIn, DOut, A>> Next Source #

Constructors

constructor Use (Func<Aff<RT, X>> acquire, Func<X, Unit> release, Func<X, Proxy<RT, UOut, UIn, DIn, DOut, A>> next) Source #

Methods

method Proxy<RT, UOut, UIn, DIn, DOut, A> ToProxy () Source #

method Proxy<RT, UOut, UIn, DIn, DOut, B> Bind <B> (Func<A, Proxy<RT, UOut, UIn, DIn, DOut, B>> f) Source #

method Proxy<RT, UOut, UIn, DIn, DOut, B> Map <B> (Func<A, B> f) Source #

method Proxy<RT, UOut, UIn, C1, C, A> For <C1, C> (Func<DOut, Proxy<RT, UOut, UIn, C1, C, DIn>> body) Source #

method Proxy<RT, UOut, UIn, DIn, DOut, B> Action <B> (Proxy<RT, UOut, UIn, DIn, DOut, B> rhs) Source #

method Proxy<RT, UOutA, AUInA, DIn, DOut, A> PairEachRequestWithRespond <UOutA, AUInA> (Func<UOut, Proxy<RT, UOutA, AUInA, UOut, UIn, A>> lhs) Source #

(f +>> p) pairs each 'request' in this with a 'respond' in lhs.

method Proxy<RT, UOutA, AUInA, DIn, DOut, A> ReplaceRequest <UOutA, AUInA> (Func<UOut, Proxy<RT, UOutA, AUInA, DIn, DOut, UIn>> lhs) Source #

method Proxy<RT, UOut, UIn, DInC, DOutC, A> PairEachRespondWithRequest <DInC, DOutC> (Func<DOut, Proxy<RT, DIn, DOut, DInC, DOutC, A>> rhs) Source #

method Proxy<RT, UOut, UIn, DInC, DOutC, A> ReplaceRespond <DInC, DOutC> (Func<DOut, Proxy<RT, UOut, UIn, DInC, DOutC, DIn>> rhs) Source #

method Proxy<RT, DOut, DIn, UIn, UOut, A> Reflect () Source #

method Proxy<RT, UOut, UIn, DIn, DOut, A> Observe () Source #

method void Deconstruct (out Func<Aff<RT, X>> acquire, out Func<X, Unit> release, out Func<X, Proxy<RT, UOut, UIn, DIn, DOut, A>> next) Source #

class Release <RT, UOut, UIn, DIn, DOut, A> Source #

where RT : struct, HasCancel<RT>

One of the algebraic cases of the Proxy type. This type represents a resource releasing computation. It is useful for tidying up resources that have been used (explicitly).

The Proxy system will tidy up resources automatically, however you must wait until the end of the computation. This case allows earlier clean up.

Parameters

type RT

Aff system runtime

type UOut

Upstream out type

type UIn

Upstream in type

type DIn

Downstream in type

type DOut

Downstream uut type

type A

The monadic bound variable - it doesn't flow up or down stream, it works just like any bound monadic variable. If the effect represented by the Proxy ends, then this will be the result value.

When composing Proxy sub-types (like Producer, Pipe, Consumer, etc.)

class Release <RT, UOut, UIn, DIn, DOut, X, A> Source #

where RT : struct, HasCancel<RT>

One of the algebraic cases of the Proxy type. This type represents a resource releasing computation. It is useful for tidying up resources that have been used (explicitly).

The Proxy system will tidy up resources automatically, however you must wait until the end of the computation. This case allows earlier clean up.

Parameters

type RT

Aff system runtime

type UOut

Upstream out type

type UIn

Upstream in type

type DIn

Downstream in type

type DOut

Downstream uut type

type A

The monadic bound variable - it doesn't flow up or down stream, it works just like any bound monadic variable. If the effect represented by the Proxy ends, then this will be the result value.

When composing Proxy sub-types (like Producer, Pipe, Consumer, etc.)

Fields

field X Value Source #

field Func<Unit, Proxy<RT, UOut, UIn, DIn, DOut, A>> Next Source #

Constructors

constructor Release (X value, Func<Unit, Proxy<RT, UOut, UIn, DIn, DOut, A>> next) Source #

Methods

method Proxy<RT, UOut, UIn, DIn, DOut, A> ToProxy () Source #

method Proxy<RT, UOut, UIn, DIn, DOut, B> Bind <B> (Func<A, Proxy<RT, UOut, UIn, DIn, DOut, B>> f) Source #

method Proxy<RT, UOut, UIn, DIn, DOut, B> Map <B> (Func<A, B> f) Source #

method Proxy<RT, UOut, UIn, C1, C, A> For <C1, C> (Func<DOut, Proxy<RT, UOut, UIn, C1, C, DIn>> body) Source #

method Proxy<RT, UOut, UIn, DIn, DOut, B> Action <B> (Proxy<RT, UOut, UIn, DIn, DOut, B> rhs) Source #

method Proxy<RT, UOutA, AUInA, DIn, DOut, A> PairEachRequestWithRespond <UOutA, AUInA> ( Func<UOut, Proxy<RT, UOutA, AUInA, UOut, UIn, A>> lhs) Source #

(f +>> p) pairs each 'request' in this with a 'respond' in lhs.

method Proxy<RT, UOutA, AUInA, DIn, DOut, A> ReplaceRequest <UOutA, AUInA> ( Func<UOut, Proxy<RT, UOutA, AUInA, DIn, DOut, UIn>> lhs) Source #

method Proxy<RT, UOut, UIn, DInC, DOutC, A> PairEachRespondWithRequest <DInC, DOutC> ( Func<DOut, Proxy<RT, DIn, DOut, DInC, DOutC, A>> rhs) Source #

method Proxy<RT, UOut, UIn, DInC, DOutC, A> ReplaceRespond <DInC, DOutC> ( Func<DOut, Proxy<RT, UOut, UIn, DInC, DOutC, DIn>> rhs) Source #

method Proxy<RT, DOut, DIn, UIn, UOut, A> Reflect () Source #

method Proxy<RT, UOut, UIn, DIn, DOut, A> Observe () Source #

method void Deconstruct (out X value, out Func<Unit, Proxy<RT, UOut, UIn, DIn, DOut, A>> next) Source #