xo-websock: bugfix: track xo::ref::rp -> xo::rp
This commit is contained in:
parent
0ed8a1f435
commit
c42b6c70eb
6 changed files with 13 additions and 16 deletions
|
|
@ -67,7 +67,7 @@ namespace xo {
|
|||
* send output to ws_sink
|
||||
*/
|
||||
CallbackId subscribe(std::string const & incoming_uri,
|
||||
ref::rp<AbstractSink> const & ws_sink) const;
|
||||
rp<AbstractSink> const & ws_sink) const;
|
||||
|
||||
/* unsubscribe stream from this endpoint;
|
||||
* reverses the effect of a previous call to .subscribe()
|
||||
|
|
|
|||
|
|
@ -83,8 +83,8 @@ namespace xo {
|
|||
* the underlying libwebsocket library is not advertised to be
|
||||
* threadsafe
|
||||
*/
|
||||
static ref::rp<Webserver> make(WebserverConfig const & ws_config,
|
||||
ref::rp<PrintJson> const & pjson);
|
||||
static rp<Webserver> make(WebserverConfig const & ws_config,
|
||||
rp<PrintJson> const & pjson);
|
||||
|
||||
/* current state */
|
||||
virtual Runstate state() const = 0;
|
||||
|
|
|
|||
|
|
@ -17,10 +17,10 @@ namespace xo {
|
|||
using PrintJson = xo::json::PrintJson;
|
||||
|
||||
public:
|
||||
static ref::rp<WebsocketSink> make(ref::rp<Webserver> const & websrv,
|
||||
ref::rp<PrintJson> const & pjson,
|
||||
uint32_t session_id,
|
||||
std::string const & stream_name);
|
||||
static rp<WebsocketSink> make(rp<Webserver> const & websrv,
|
||||
rp<PrintJson> const & pjson,
|
||||
uint32_t session_id,
|
||||
std::string const & stream_name);
|
||||
}; /*WebsocketSink*/
|
||||
} /*namespace web*/
|
||||
} /*namespace xo*/
|
||||
|
|
|
|||
|
|
@ -8,7 +8,6 @@
|
|||
namespace xo {
|
||||
using xo::web::Alist;
|
||||
using xo::fn::CallbackId;
|
||||
using xo::ref::rp;
|
||||
|
||||
namespace web {
|
||||
DynamicEndpoint::DynamicEndpoint(std::string uri_pattern,
|
||||
|
|
|
|||
|
|
@ -34,7 +34,6 @@ namespace xo {
|
|||
using xo::reactor::AbstractSink;
|
||||
using xo::json::PrintJson;
|
||||
using xo::fn::CallbackId;
|
||||
using xo::ref::rp;
|
||||
using xo::scope;
|
||||
using xo::xtag;
|
||||
|
||||
|
|
|
|||
|
|
@ -16,9 +16,8 @@ namespace xo {
|
|||
using xo::reflect::Reflect;
|
||||
using xo::reflect::TaggedPtr;
|
||||
using xo::reflect::TypeDescr;
|
||||
using xo::ref::rp;
|
||||
using xo::ref::brw;
|
||||
using xo::print::quoted;
|
||||
using xo::print::quot;
|
||||
using xo::print::qcstr;
|
||||
using xo::scope;
|
||||
using xo::xtag;
|
||||
|
|
@ -36,8 +35,8 @@ namespace xo {
|
|||
using AbstractSource = reactor::AbstractSource;
|
||||
|
||||
public:
|
||||
WebsocketSinkImpl(ref::rp<Webserver> const & websrv,
|
||||
ref::rp<PrintJson> const & pjson,
|
||||
WebsocketSinkImpl(rp<Webserver> const & websrv,
|
||||
rp<PrintJson> const & pjson,
|
||||
uint32_t session_id,
|
||||
std::string stream_name)
|
||||
: websrv_{std::move(websrv)},
|
||||
|
|
@ -56,7 +55,7 @@ namespace xo {
|
|||
virtual TypeDescr sink_ev_type() const override;
|
||||
virtual bool allow_volatile_source() const override { return true; }
|
||||
virtual uint32_t n_in_ev() const override { return n_in_ev_; }
|
||||
virtual void attach_source(ref::rp<AbstractSource> const & src) override;
|
||||
virtual void attach_source(rp<AbstractSource> const & src) override;
|
||||
virtual void notify_ev_tp(TaggedPtr const & ev_tp) override;
|
||||
|
||||
private:
|
||||
|
|
@ -66,9 +65,9 @@ namespace xo {
|
|||
*/
|
||||
std::string name_;
|
||||
/* webserver implementation */
|
||||
ref::rp<Webserver> websrv_;
|
||||
rp<Webserver> websrv_;
|
||||
/* print arbitrary reflected stuff as json */
|
||||
ref::rp<PrintJson> pjson_;
|
||||
rp<PrintJson> pjson_;
|
||||
/* websocket session id# - events arriving at this sink
|
||||
* will be sent only to the session identified by .session_id
|
||||
*/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue