Table of Contents

Method Lift

Namespace
SodaFlow
Assembly
SodaFlow.dll

Lift<T, T2, TResult>(Behavior<T>, Behavior<T2>, Func<T, T2, TResult>)

Lift a binary function into behaviors, so the returned behavior always reflects the specified function applied to the input behaviors' values.

public static Behavior<TResult> Lift<T, T2, TResult>(this Behavior<T> b, Behavior<T2> b2, Func<T, T2, TResult> f)

Parameters

b Behavior<T>

The behavior.

b2 Behavior<T2>

The second behavior.

f Func<T, T2, TResult>

The binary function to lift into the behaviors.

Returns

Behavior<TResult>

A behavior containing values resulting from the binary function applied to the input behaviors' values.

Type Parameters

T

The type of the behavior.

T2

The type of second behavior.

TResult

The type of the result.

Lift<T, T2, T3, TResult>(Behavior<T>, Behavior<T2>, Behavior<T3>, Func<T, T2, T3, TResult>)

Lift a ternary function into behaviors, so the returned behavior always reflects the specified function applied to the input behaviors' values.

public static Behavior<TResult> Lift<T, T2, T3, TResult>(this Behavior<T> b, Behavior<T2> b2, Behavior<T3> b3, Func<T, T2, T3, TResult> f)

Parameters

b Behavior<T>

The behavior.

b2 Behavior<T2>

The second behavior.

b3 Behavior<T3>

The third behavior.

f Func<T, T2, T3, TResult>

The binary function to lift into the behaviors.

Returns

Behavior<TResult>

A behavior containing values resulting from the ternary function applied to the input behaviors' values.

Type Parameters

T

The type of the behavior.

T2

The type of second behavior.

T3

The type of third behavior.

TResult

The type of the result.

Lift<T, T2, T3, T4, TResult>(Behavior<T>, Behavior<T2>, Behavior<T3>, Behavior<T4>, Func<T, T2, T3, T4, TResult>)

Lift a quaternary function into behaviors, so the returned behavior always reflects the specified function applied to the input behaviors' values.

public static Behavior<TResult> Lift<T, T2, T3, T4, TResult>(this Behavior<T> b, Behavior<T2> b2, Behavior<T3> b3, Behavior<T4> b4, Func<T, T2, T3, T4, TResult> f)

Parameters

b Behavior<T>

The behavior.

b2 Behavior<T2>

The second behavior.

b3 Behavior<T3>

The third behavior.

b4 Behavior<T4>

The fourth behavior.

f Func<T, T2, T3, T4, TResult>

The binary function to lift into the behaviors.

Returns

Behavior<TResult>

A behavior containing values resulting from the quaternary function applied to the input behaviors' values.

Type Parameters

T

The type of the behavior.

T2

The type of second behavior.

T3

The type of third behavior.

T4

The type of fourth behavior.

TResult

The type of the result.

Lift<T, T2, T3, T4, T5, TResult>(Behavior<T>, Behavior<T2>, Behavior<T3>, Behavior<T4>, Behavior<T5>, Func<T, T2, T3, T4, T5, TResult>)

Lift a 5-argument function into behaviors, so the returned behavior always reflects the specified function applied to the input behaviors' values.

public static Behavior<TResult> Lift<T, T2, T3, T4, T5, TResult>(this Behavior<T> b, Behavior<T2> b2, Behavior<T3> b3, Behavior<T4> b4, Behavior<T5> b5, Func<T, T2, T3, T4, T5, TResult> f)

Parameters

b Behavior<T>

The behavior.

b2 Behavior<T2>

The second behavior.

b3 Behavior<T3>

The third behavior.

b4 Behavior<T4>

The fourth behavior.

b5 Behavior<T5>

The fifth behavior.

f Func<T, T2, T3, T4, T5, TResult>

The binary function to lift into the behaviors.

Returns

Behavior<TResult>

A behavior containing values resulting from the 5-argument function applied to the input behaviors' values.

Type Parameters

T

The type of the behavior.

T2

The type of second behavior.

T3

The type of third behavior.

T4

The type of fourth behavior.

T5

The type of fifth behavior.

TResult

The type of the result.

Lift<T, T2, T3, T4, T5, T6, TResult>(Behavior<T>, Behavior<T2>, Behavior<T3>, Behavior<T4>, Behavior<T5>, Behavior<T6>, Func<T, T2, T3, T4, T5, T6, TResult>)

Lift a 6-argument function into behaviors, so the returned behavior always reflects the specified function applied to the input behaviors' values.

public static Behavior<TResult> Lift<T, T2, T3, T4, T5, T6, TResult>(this Behavior<T> b, Behavior<T2> b2, Behavior<T3> b3, Behavior<T4> b4, Behavior<T5> b5, Behavior<T6> b6, Func<T, T2, T3, T4, T5, T6, TResult> f)

Parameters

b Behavior<T>

The behavior.

b2 Behavior<T2>

The second behavior.

b3 Behavior<T3>

The third behavior.

b4 Behavior<T4>

The fourth behavior.

b5 Behavior<T5>

The fifth behavior.

b6 Behavior<T6>

The sixth behavior.

f Func<T, T2, T3, T4, T5, T6, TResult>

The binary function to lift into the behaviors.

Returns

Behavior<TResult>

A behavior containing values resulting from the 6-argument function applied to the input behaviors' values.

Type Parameters

T

The type of the behavior.

T2

The type of second behavior.

T3

The type of third behavior.

T4

The type of fourth behavior.

T5

The type of fifth behavior.

T6

The type of sixth behavior.

TResult

The type of the result.

Lift<T, T2, T3, T4, T5, T6, T7, TResult>(Behavior<T>, Behavior<T2>, Behavior<T3>, Behavior<T4>, Behavior<T5>, Behavior<T6>, Behavior<T7>, Func<T, T2, T3, T4, T5, T6, T7, TResult>)

Lifts a function of seven arguments into behaviors. The behavior from this call always has the value of that function on the values of the input behaviors.

public static Behavior<TResult> Lift<T, T2, T3, T4, T5, T6, T7, TResult>(this Behavior<T> b, Behavior<T2> b2, Behavior<T3> b3, Behavior<T4> b4, Behavior<T5> b5, Behavior<T6> b6, Behavior<T7> b7, Func<T, T2, T3, T4, T5, T6, T7, TResult> f)

Parameters

b Behavior<T>

The first behavior.

b2 Behavior<T2>

The second behavior.

b3 Behavior<T3>

The third behavior.

b4 Behavior<T4>

The fourth behavior.

b5 Behavior<T5>

The fifth behavior.

b6 Behavior<T6>

The sixth behavior.

b7 Behavior<T7>

The seventh behavior.

f Func<T, T2, T3, T4, T5, T6, T7, TResult>

The function to lift into the behaviors. It must be a pure function.

Returns

Behavior<TResult>

A behavior with the value of f on the values of the input behaviors.

Type Parameters

T

The type of the first behavior.

T2

The type of the second behavior.

T3

The type of the third behavior.

T4

The type of the fourth behavior.

T5

The type of the fifth behavior.

T6

The type of the sixth behavior.

T7

The type of the seventh behavior.

TResult

The type of the result.

Lift<T, T2, T3, T4, T5, T6, T7, T8, TResult>(Behavior<T>, Behavior<T2>, Behavior<T3>, Behavior<T4>, Behavior<T5>, Behavior<T6>, Behavior<T7>, Behavior<T8>, Func<T, T2, T3, T4, T5, T6, T7, T8, TResult>)

Lifts a function of eight arguments into behaviors. The behavior from this call always has the value of that function on the values of the input behaviors.

public static Behavior<TResult> Lift<T, T2, T3, T4, T5, T6, T7, T8, TResult>(this Behavior<T> b, Behavior<T2> b2, Behavior<T3> b3, Behavior<T4> b4, Behavior<T5> b5, Behavior<T6> b6, Behavior<T7> b7, Behavior<T8> b8, Func<T, T2, T3, T4, T5, T6, T7, T8, TResult> f)

Parameters

b Behavior<T>

The first behavior.

b2 Behavior<T2>

The second behavior.

b3 Behavior<T3>

The third behavior.

b4 Behavior<T4>

The fourth behavior.

b5 Behavior<T5>

The fifth behavior.

b6 Behavior<T6>

The sixth behavior.

b7 Behavior<T7>

The seventh behavior.

b8 Behavior<T8>

The eighth behavior.

f Func<T, T2, T3, T4, T5, T6, T7, T8, TResult>

The function to lift into the behaviors. It must be a pure function.

Returns

Behavior<TResult>

A behavior with the value of f on the values of the input behaviors.

Type Parameters

T

The type of the first behavior.

T2

The type of the second behavior.

T3

The type of the third behavior.

T4

The type of the fourth behavior.

T5

The type of the fifth behavior.

T6

The type of the sixth behavior.

T7

The type of the seventh behavior.

T8

The type of the eighth behavior.

TResult

The type of the result.

Lift<T, TResult>(IEnumerable<Behavior<T>>, Func<IReadOnlyList<T>, TResult>)

Lift a function into a collection of behaviors, so the returned behavior always reflects the specified function applied to the input behaviors' values.

public static Behavior<TResult> Lift<T, TResult>(this IEnumerable<Behavior<T>> b, Func<IReadOnlyList<T>, TResult> f)

Parameters

b IEnumerable<Behavior<T>>

The collection of behaviors.

f Func<IReadOnlyList<T>, TResult>

The binary function to lift into the behaviors.

Returns

Behavior<TResult>

A behavior containing values resulting from the function applied to the input behaviors' values.

Type Parameters

T

The type of the behaviors.

TResult

The type of the result.

Lift<T, TResult>(IReadOnlyCollection<Behavior<T>>, Func<IReadOnlyList<T>, TResult>)

Lift a function into a collection of behaviors, so the returned behavior always reflects the specified function applied to the input behaviors' values.

public static Behavior<TResult> Lift<T, TResult>(this IReadOnlyCollection<Behavior<T>> b, Func<IReadOnlyList<T>, TResult> f)

Parameters

b IReadOnlyCollection<Behavior<T>>

The collection of behaviors.

f Func<IReadOnlyList<T>, TResult>

The binary function to lift into the behaviors.

Returns

Behavior<TResult>

A behavior containing values resulting from the function applied to the input behaviors' values.

Type Parameters

T

The type of the behaviors.

TResult

The type of the result.

Lift<T>(IEnumerable<Behavior<T>>)

Lift into a collection of behaviors, so the returned behavior always reflects a list of the input behaviors' values.

public static Behavior<IReadOnlyList<T>> Lift<T>(this IEnumerable<Behavior<T>> b)

Parameters

b IEnumerable<Behavior<T>>

The collection of behaviors.

Returns

Behavior<IReadOnlyList<T>>

A behavior containing a list of the input behaviors' values.

Type Parameters

T

The type of the behaviors.

Lift<T>(IReadOnlyCollection<Behavior<T>>)

Lift into a collection of behaviors, so the returned behavior always reflects a list of the input behaviors' values.

public static Behavior<IReadOnlyList<T>> Lift<T>(this IReadOnlyCollection<Behavior<T>> b)

Parameters

b IReadOnlyCollection<Behavior<T>>

The collection of behaviors.

Returns

Behavior<IReadOnlyList<T>>

A behavior containing a list of the input behaviors' values.

Type Parameters

T

The type of the behaviors.