Interface IExecutable<TIn, TOut>
- Namespace
- Executables
- Assembly
- executables.dll
Represents an executable operation.
public interface IExecutable<in TIn, out TOut>
Type Parameters
TInInput type.
TOutOutput type.
Examples
IExecutable<string, string> pipeline =
Executable.Create((string text) => int.Parse(text))
.Then(Executable.Create((int value) => (value * 2).ToString()));
Remarks
This interface is the composition layer of the library. It describes what should be executed, without attaching runtime concerns such as exception mapping, result wrapping, caching, or metrics.
Create executables with Create(...) and compose them with Then(...) and Compose(...). Convert to an executor by calling GetExecutor() when runtime behavior is needed.
Methods
GetExecutor()
Gets an executor that performs this executable operation.
[Pure]
IExecutor<in TIn, out TOut> GetExecutor()
Returns
- IExecutor<TIn, TOut>
Executor instance.