I am trying to implement search box with auto complete backed by network source. First, i want limit that request will start only when user pauses writing, this is done with help of Throttle. Second, i also want limit, that previous request must finish before sending new and value must not be lost, something like ThrottleUntil. (which must throttle till observable will produce any value)
but, i can't find solution myself.
IObservable<bool> isLoading;
IObservable<string> inputObservable;
inputObservable.Throttle(TimeSpan.FromMilliseconds(250)).ThrottleUntil(isLoading.Where(v=>!v)).Subscribe(/*run loading*/);
Here i miss ThrottleUntil extension, or analog.
It's possible to implement it?