DotNext by .NET Foundation and Contributors

<PackageReference Include="DotNext" Version="4.6.1" />

.NET API 538,048 bytes

 Optional

public static class Optional
public static Optional Coalesce<T>(this ref Optional first, ref Optional second)

public static Task<Optional<TOutput>> Convert<TInput, TOutput>(this Task<Optional<TInput>> task, Converter<TInput, TOutput> converter)

public static Optional<T> Create<T, TMonad>(TMonad value) where TMonad : struct, IOptionMonad<T>

public static Optional<T> Flatten<T>(this ref Optional optional)

public static T& modreq(System.Runtime.InteropServices.InAttribute) GetReference<T, TException>(ref Optional optional) where T : struct where TException : Exception

public static T& modreq(System.Runtime.InteropServices.InAttribute) GetReference<T>(ref Optional optional, Func<Exception> exceptionFactory) where T : struct

public static T& modreq(System.Runtime.InteropServices.InAttribute) GetReference<T>(ref Optional optional, method exceptionFactory) where T : struct

public static T& modreq(System.Runtime.InteropServices.InAttribute) GetReference<T>(ref Optional optional) where T : struct

public static Type GetUnderlyingType(Type optionalType)

public static Task<Optional<T>> If<T>(this Task<Optional<T>> task, Predicate<T> condition)

public static bool IsOptional(this Type optionalType)

public static Optional<T> None<T>()

public static Optional<T> Null<T>()

public static Task<T> Or<T>(this Task<Optional<T>> task, T defaultValue)

public static Task<T> OrDefault<T>(this Task<Optional<T>> task)

public static Task<T> OrInvoke<T>(this Task<Optional<T>> task, Func<T> defaultFunc)

public static Task<T?> OrNull<T>(this Task<Optional<T>> task) where T : struct

public static T? OrNull<T>(this ref Optional value) where T : struct

public static Task<T> OrThrow<T, TException>(this Task<Optional<T>> task) where TException : Exception

public static Task<T> OrThrow<T, TException>(this Task<Optional<T>> task, Func<TException> exceptionFactory) where TException : Exception

public static Optional<T> Some<T>(T value)

public static Optional<T> ToOptional<T>(this ref Nullable value) where T : struct