pub struct ProjectorRouter { /* private fields */ }Expand description
Router for projector components (events → external output, multi-domain).
Domains are registered via fluent .domain() calls.
Implementations§
Source§impl ProjectorRouter
impl ProjectorRouter
Sourcepub fn new(name: impl Into<String>) -> Self
pub fn new(name: impl Into<String>) -> Self
Create a new projector router.
Projectors consume events from multiple domains and produce external output.
Sourcepub fn domain<H>(self, name: impl Into<String>, handler: H) -> Selfwhere
H: ProjectorDomainHandler + 'static,
pub fn domain<H>(self, name: impl Into<String>, handler: H) -> Selfwhere
H: ProjectorDomainHandler + 'static,
Register a domain handler.
Projectors can have multiple input domains.
Auto Trait Implementations§
impl Freeze for ProjectorRouter
impl !RefUnwindSafe for ProjectorRouter
impl Send for ProjectorRouter
impl Sync for ProjectorRouter
impl Unpin for ProjectorRouter
impl UnsafeUnpin for ProjectorRouter
impl !UnwindSafe for ProjectorRouter
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request