morph 0.1.0
Asynchronous bridge between GUI thread and business models
Loading...
Searching...
No Matches
morph::ui::Dispatcher Class Referenceabstract

The interpreter's view of the bridge: binds a model by its type id, privately or to a shared instance. More...

#include <interpreter.hpp>

Inheritance diagram for morph::ui::Dispatcher:
morph::ui::BridgeDispatcher morph::ui::QueueingDispatcher

Public Member Functions

 Dispatcher (Dispatcher const &)=delete
Dispatcher & operator= (Dispatcher const &)=delete
 Dispatcher (Dispatcher &&)=delete
Dispatcher & operator= (Dispatcher &&)=delete
virtual std::shared_ptr< ModelChannel > bind (std::string const &typeId, bridge::BindSharing sharing, std::string const &instanceKey)=0
 Binds a model.

Detailed Description

The interpreter's view of the bridge: binds a model by its type id, privately or to a shared instance.

Definition at line 94 of file interpreter.hpp.

Member Function Documentation

◆ bind()

virtual std::shared_ptr< ModelChannel > morph::ui::Dispatcher::bind ( std::string const & typeId,
bridge::BindSharing sharing,
std::string const & instanceKey )
nodiscardpure virtual

Binds a model.

Parameters
typeIdThe model's registered type id.
sharingPrivate, or shared.
instanceKeyFor a shared binding, the instance key; empty for the model's shared singleton.
Returns
The bound channel. The caller holds it as long as it makes calls through it.

Implemented in morph::ui::BridgeDispatcher, and morph::ui::QueueingDispatcher.


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