ReactivePlusPlus
ReactiveX implementation for C++20
Loading...
Searching...
No Matches
rpp::subjects::publish_subject< Type > Class Template Referencefinal

Subject which just multicasts values to observers subscribed on it. It contains two parts: observer and observable at the same time. More...

#include <publish_subject.hpp>

Additional Inherited Members

- Public Types inherited from rpp::subjects::details::publish_subject_base< Type, false >
using optimal_disposables_strategy
 
- Public Member Functions inherited from rpp::subjects::details::publish_subject_base< Type, false >
auto get_observer () const
 
auto get_observable () const
 
rpp::disposable_wrapper get_disposable () const
 

Detailed Description

template<rpp::constraint::decayed_type Type>
class rpp::subjects::publish_subject< Type >

Subject which just multicasts values to observers subscribed on it. It contains two parts: observer and observable at the same time.

Each observer obtains only values which emitted after corresponding subscribe. on_error/on_completer/unsubscribe cached and provided to new observers if any

Warning
this subject is not synchronized/serialized! It means, that expected to call callbacks of observer in the serialized way to follow observable contract: "Observables must issue notifications to observers serially (not in parallel).". If you are not sure or need extra serialization, please, use serialized_publish_subject.
Template Parameters
Typevalue provided by this subject
See also
https://reactivex.io/documentation/subject.html
Examples
multicast.cpp.

The documentation for this class was generated from the following files: