using System; using System.Reactive; using System.Reactive.Linq; using System.Threading.Tasks; namespace Sharp7.Rx.Extensions { internal static class ObservableExtensions { public static IObservable Select(this IObservable source, Func selector) { return source .Select(x => Observable.FromAsync(async () => await selector(x))) .Concat(); } public static IObservable Select(this IObservable source, Func> selector) { return source .Select(x => Observable.FromAsync(async () => await selector(x))) .Concat(); } } }