pub(crate) enum Dispatched {
Response(Box<JsonRpcResponse>),
Notification,
UnknownServer,
}Expand description
Outcome of routing an mcp_message. Kept three-way so an unroutable
message cannot share a representation with a notification: the caller
answers a notification with an id-less empty result, which for an unknown
server would report success for something that never ran.
Variants§
Response(Box<JsonRpcResponse>)
The server produced a response to send back.
Notification
A JSON-RPC notification - no response is owed.
UnknownServer
No server is registered under that name.
Auto Trait Implementations§
impl Freeze for Dispatched
impl RefUnwindSafe for Dispatched
impl Send for Dispatched
impl Sync for Dispatched
impl Unpin for Dispatched
impl UnsafeUnpin for Dispatched
impl UnwindSafe for Dispatched
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