13#include <rpp/observables/specific_observable.hpp>
14#include <rpp/sources/fwd.hpp>
18IMPLEMENTATION_FILE(create_tag);
20namespace rpp::observable
42template<constra
int::decayed_type Type, constra
int::on_subscribe_fn<Type> OnSubscribeFn>
43auto create(OnSubscribeFn&& on_subscribe)
requires rpp::details::is_header_included<rpp::details::create_tag, Type, OnSubscribeFn>
45 using CreatedOnSubscribeFn = std::decay_t<OnSubscribeFn>;
46 return specific_observable<Type, CreatedOnSubscribeFn>{std::forward<OnSubscribeFn>(on_subscribe)};
70template<utils::is_callable OnSubscribeFn, constra
int::decayed_type Type>
71 requires constraint::on_subscribe_fn<OnSubscribeFn, Type>
72auto create(OnSubscribeFn&& on_subscribe)
requires rpp::details::is_header_included<rpp::details::create_tag, Type, OnSubscribeFn>
74 return create<Type>(std::forward<OnSubscribeFn>(on_subscribe));
auto create(OnSubscribeFn &&on_subscribe)
Creates rpp::specific_observable with passed action as OnSubscribe.
Definition: create.hpp:40