pub struct DeclaredCommandDispatcher { /* private fields */ }Expand description
The dispatcher decorator that executes declared bodies at the server.
Wraps the production dispatcher. Consults the declared-body source before every dispatch; delegates untouched whenever the action carries no body.
Implementations§
Source§impl DeclaredCommandDispatcher
impl DeclaredCommandDispatcher
Sourcepub fn new(
inner: Arc<dyn ActivityDispatcher>,
bodies: DeclaredBodySource,
tokio: Handle,
workspace_root: WorkspaceRoot,
) -> Self
pub fn new( inner: Arc<dyn ActivityDispatcher>, bodies: DeclaredBodySource, tokio: Handle, workspace_root: WorkspaceRoot, ) -> Self
Wrap inner, consulting bodies before every dispatch and expanding
{workspace_root} in declared commands with the server-resolved
workspace_root.
Trait Implementations§
Source§impl ActivityDispatcher for DeclaredCommandDispatcher
impl ActivityDispatcher for DeclaredCommandDispatcher
Auto Trait Implementations§
impl !RefUnwindSafe for DeclaredCommandDispatcher
impl !UnwindSafe for DeclaredCommandDispatcher
impl Freeze for DeclaredCommandDispatcher
impl Send for DeclaredCommandDispatcher
impl Sync for DeclaredCommandDispatcher
impl Unpin for DeclaredCommandDispatcher
impl UnsafeUnpin for DeclaredCommandDispatcher
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
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