Class WrapBinaryTwoOutputs<TRealTop, TRealBottom, TRealTopOut, TRealBottomOut>
Wrap a C# function that takes two arguments and returns two values as a Fluency function. Works just like WrapBinary<TRealTop, TRealBottom, TRealOut>, except it wraps something that returns exactly two values.
- If no arguments given, read something from the top and the bottom and do the operation on them, returning something on top and something on the bottom.
- If one top argument given, read something from the bottom and do the operation with that and the argument.
- If one bottom argument given, read something from the top and do the operation with that and the argument.
- This is how DivMod is implemented.
Inheritance
System.Object
WrapBinaryTwoOutputs<TRealTop, TRealBottom, TRealTopOut, TRealBottomOut>
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Fluency.Execution.Functions.BuiltIn
Assembly: Execution.dll
Syntax
public class WrapBinaryTwoOutputs<TRealTop, TRealBottom, TRealTopOut, TRealBottomOut> : ITopIn, IBottomIn, ITopOut, IBottomOut, IFunction
Type Parameters
| Name | Description |
|---|---|
| TRealTop | |
| TRealBottom | |
| TRealTopOut | |
| TRealBottomOut |
Constructors
| Improve this Doc View SourceWrapBinaryTwoOutputs(Func<TRealTop, TRealBottom, (TRealTopOut, TRealBottomOut)>, FluencyType, FluencyType, FluencyType, String, Value[], Value[])
Declaration
public WrapBinaryTwoOutputs(Func<TRealTop, TRealBottom, (TRealTopOut, TRealBottomOut)> function, FluencyType argType, FluencyType topReturnType, FluencyType bottomReturnType, string name, Value[] topArguments, Value[] bottomArguments = null)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Func<TRealTop, TRealBottom, System.ValueTuple<TRealTopOut, TRealBottomOut>> | function | |
| FluencyType | argType | |
| FluencyType | topReturnType | |
| FluencyType | bottomReturnType | |
| System.String | name | |
| Value[] | topArguments | |
| Value[] | bottomArguments |
Properties
| Improve this Doc View SourceBottomInput
Declaration
public GetNext BottomInput { set; }
Property Value
| Type | Description |
|---|---|
| GetNext |
Name
Declaration
public string Name { get; }
Property Value
| Type | Description |
|---|---|
| System.String |
TopInput
Declaration
public GetNext TopInput { set; }
Property Value
| Type | Description |
|---|---|
| GetNext |
Methods
| Improve this Doc View SourceBottom()
Declaration
public Value Bottom()
Returns
| Type | Description |
|---|---|
| Value |
Top()
Declaration
public Value Top()
Returns
| Type | Description |
|---|---|
| Value |
TryGetFromQueue(Queue<Value>)
Declaration
public Value TryGetFromQueue(Queue<Value> queue)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Collections.Generic.Queue<Value> | queue |
Returns
| Type | Description |
|---|---|
| Value |