Struct SuppressExceptionFlattenExecutorProvider<T1, T2>
- Namespace
- Executables.Executors
- Assembly
- executables.dll
Provides suppression executor for executors that already return Optional<T>.
public readonly ref struct SuppressExceptionFlattenExecutorProvider<T1, T2>
Type Parameters
T1T2
- Inherited Members
Constructors
SuppressExceptionFlattenExecutorProvider(IExecutor<T1, Optional<T2>>)
Provides suppression executor for executors that already return Optional<T>.
public SuppressExceptionFlattenExecutorProvider(IExecutor<T1, Optional<T2>> executor)
Parameters
Methods
OfType<TEx>()
Suppresses exceptions of the specified type and preserves optional result shape.
public IExecutor<T1, Optional<T2>> OfType<TEx>() where TEx : Exception
Returns
- IExecutor<T1, Optional<T2>>
Executor that returns an empty optional when suppressed exception occurs.
Type Parameters
TExException type to suppress.