3#include <rpp/sources/fwd.hpp>
5#include <rpp/operators/take.hpp>
6#include <rpp/sources/interval.hpp>
24 template<schedulers::constra
int::scheduler TScheduler>
25 auto timer(rpp::schedulers::duration when, TScheduler&& scheduler)
27 return interval(when, rpp::schedulers::duration::zero(), std::forward<TScheduler>(scheduler)) |
operators::take(1);
39 template<schedulers::constra
int::scheduler TScheduler>
40 auto timer(rpp::schedulers::time_point when, TScheduler&& scheduler)
42 return interval(when, rpp::schedulers::duration::zero(), std::forward<TScheduler>(scheduler)) |
operators::take(1);
auto interval(rpp::schedulers::duration initial, rpp::schedulers::duration period, TScheduler &&scheduler)
Creates rpp::observable that emits a sequential integer every specified time interval,...
Definition interval.hpp:72
auto timer(rpp::schedulers::duration when, TScheduler &&scheduler)
Creates rpp::observable that emits an integer after a given delay, on the specified scheduler.
Definition timer.hpp:22
auto take(size_t count)
Emit only first count items provided by observable, then send on_completed
Definition take.hpp:92