public static Result <R> Map <T, R>(this Result <T> source, Func <T, R> map) { return(source.Match(x => Success.Of(map(x)), Error.Of <R>)); }
public static Result <T> Of <T>(T success, Exception error) { return(error == null?Success.Of(success) : Error.Of <T>(error)); }