Method GetValueAs
- Namespace
- SodaFlow.Functional
- Assembly
- SodaFlow.Functional.dll
GetValueAs<T>()
Begins a call which collapses an either whose cases all derive from
T down to a single T.
public static Either.GetValueAsHelper<T> GetValueAs<T>()
Returns
- Either.GetValueAsHelper<T>
A helper whose
Fromoverloads have the either as a parameter and do this change.
Type Parameters
TThe type that the cases become.
Remarks
Written in two calls, Either.GetValueAs<TCommon>().From(e),
because C# cannot specify one type argument and infer the others in one
call. Type inference also gives the type arguments of the either better
than a writer does.