Combining operators are operators that combines emissions of multiple observables into same observable by some rule. More...
Functions | |
template<constraint::observable ... TOtherObservable, std::invocable< Type, utils::extract_observable_type_t< TOtherObservable >... > TCombiner> requires is_header_included<combine_latest_tag, TOtherObservable...> | |
auto | observable::combine_latest (TCombiner &&combiner, TOtherObservable &&...observables) const & |
Combines latest emissions from original observable and other observables when any of them emits. | |
template<constraint::observable ... TOtherObservable> requires is_header_included<combine_latest_tag, TOtherObservable...> | |
auto | observable::combine_latest (TOtherObservable &&...observables) const & |
Combines latest emissions from current observable and other observables when any of them emits. The combining result is std::tuple<...>. | |
template<typename ... Args> requires (is_header_included<merge_tag, Args...> && rpp::constraint::observable<Type>) | |
auto | observable::merge () const & |
Converts observable of observables of items into observable of items via merging emissions. | |
template<constraint::observable_of_type< Type > ... TObservables> requires (is_header_included<merge_tag, TObservables...>&& sizeof...(TObservables) >= 1) | |
auto | observable::merge_with (TObservables &&... observables) const & |
Combines submissions from current observable with other observables into one. | |
template<rpp::memory_model memory_model = memory_model::use_stack, constraint::decayed_same_as< Type > ... TTypes> requires is_header_included<start_with_tag, TTypes...> | |
auto | observable::start_with (TTypes &&...vals_to_start_with) const & |
Combines submissions from current observable with values into one but without overlapping and starting from values provided as arguments. | |
template<constraint::observable_of_type< Type > ... TObservables> requires is_header_included<start_with_tag, TObservables...> | |
auto | observable::start_with (TObservables &&...observables_to_start_with) const & |
Combines submissions from current observable with other observables into one but without overlapping and starting from observables provided as arguments. | |
template<typename ... Args> requires (is_header_included<switch_on_next_tag, Args...>&& rpp::constraint::observable<Type>) | |
auto | observable::switch_on_next () const & |
Converts observable of observables into observable of values which emits values from most recent underlying observable till new observable obtained. | |
template<constraint::observable ... TObservables, std::invocable< Type, utils::extract_observable_type_t< TObservables >... > TSelector> requires is_header_included<with_latest_from_tag, TObservables...> | |
auto | observable::with_latest_from (TSelector &&selector, TObservables &&...observables) const & |
Combines latest emissions from observables with emission from current observable when it sends new value via applying selector. | |
template<constraint::observable ... TObservables> requires is_header_included<with_latest_from_tag, TObservables...> | |
auto | observable::with_latest_from (TObservables &&...observables) const & |
Combines latest emissions from observables with emission from current observable when it sends new value via making tuple. | |
Combining operators are operators that combines emissions of multiple observables into same observable by some rule.
|
inline |
Combines latest emissions from original observable and other observables when any of them emits.
std::mutex
to satisfy this requirementActually this operator subscribes on all of theses observables and emits new combined value when any of them emits new emission (and each observable emit values at least one to be able to provide combined value)
combiner | combines emissions from all the observables using custom composition. |
observables | are observables whose emissions would be combined with the current observable's emissions |
shared_ptr
to store last emissions.
|
inline |
Combines latest emissions from current observable and other observables when any of them emits. The combining result is std::tuple<...>.
Actually this operator subscribes on all of theses observables and emits std::tuple
of last emissions when any of them emits new emission (and each observable emit values at least one to be able to provide combined value)
observables | are observables whose emissions would be combined with the current observable's emissions |
shared_ptr
to store last emissions.std::tuple
of last emissions if there is last emissions for each observable
|
inline |
Converts observable of observables of items into observable of items via merging emissions.
Actually it subscribes on each observable from emissions. Resulting observables completes when ALL observables completes
shared_ptr
to store interal state
|
inline |
Combines submissions from current observable with other observables into one.
Actually it subscribes on each observable. Resulting observables completes when ALL observables completes
observables | are observables whose emissions would be merged with current observable |
shared_ptr
to store interal state
|
inline |
Combines submissions from current observable with other observables into one but without overlapping and starting from observables provided as arguments.
Actually it makes concat(observables_to_start_with..., current_observable) so observables from argument subscribed before current observable
observables | list of observables which should be used before current observable |
|
inline |
Combines submissions from current observable with values into one but without overlapping and starting from values provided as arguments.
Actually it makes concat(rpp::source::just(vals_to_start_with)..., current_observable) so observables from argument subscribed before current observable
memory_model | memory_model strategy used to store provided values |
vals | list of values which should be emitted before current observable |
|
inline |
Converts observable of observables into observable of values which emits values from most recent underlying observable till new observable obtained.
Actually this operator just unsubscribes from previous observable and subscribes on new observable when obtained in on_next
shared_ptr
to store internal state
|
inline |
Combines latest emissions from observables with emission from current observable when it sends new value via making tuple.
observables | are observables whose emissions would be combined when current observable sends new value |
|
inline |
Combines latest emissions from observables with emission from current observable when it sends new value via applying selector.
Actually this operator just keeps last values from all other observables and combines them together with each new emission from original observable
selector | is applied to current emission of current observable and latests emissions from observables |
observables | are observables whose emissions would be combined when current observable sends new value |
shared_ptr
to keep last values from all observables