logo
pub trait MediatorRegistry<Body> where
    Body: 'static + Debug
{ fn register_mediator<M>(&self, mediator: Rc<M>)
    where
        M: Mediator<Body>
; fn retrieve_mediator<M>(&self) -> Option<Rc<M>>
    where
        M: Mediator<Body>
; fn remove_mediator<M>(&self) -> Option<Rc<M>>
    where
        M: Mediator<Body>
; fn has_mediator<M>(&self) -> bool
    where
        M: Mediator<Body>
; }
Expand description

Defines Mediator Registry functionality

Required Methods

Register an Mediator instance with the View.

Registers the Mediator so that it can be retrieved by name, and further interrogates the Mediator for its Notification interests.

If the Mediator returns any Notification names to be notified about, an Observer is created encapsulating the Mediator instance’s handle_notification method and registering it as an Observer for all Notification’s the Mediator is interested in.

Retrieve an Mediator from the View.

Remove an Mediator from the View.

Check if a Mediator is registered or not

Implementations on Foreign Types

Register an Mediator instance with the View.

Retrieve an Mediator instance from the View.

Remove a Mediator instance from the View.

Check if a Mediator is registered or not

Implementors