pub enum Incoming<'a> {
Request {
id: &'a Value,
method: &'a str,
params: Option<&'a Value>,
},
Notification {
method: &'a str,
params: Option<&'a Value>,
},
Response {
id: &'a Value,
outcome: Result<&'a Value, McpError>,
},
}Expand description
A message as received, classified.
Variants§
Request
A request from the server.
Notification
A notification from the server.
Response
A response to one of the client’s requests.
Trait Implementations§
impl<'a> StructuralPartialEq for Incoming<'a>
Auto Trait Implementations§
impl<'a> Forget for Incoming<'a>
impl<'a> Freeze for Incoming<'a>
impl<'a> RefUnwindSafe for Incoming<'a>
impl<'a> Send for Incoming<'a>
impl<'a> Sync for Incoming<'a>
impl<'a> Unpin for Incoming<'a>
impl<'a> UnsafeUnpin for Incoming<'a>
impl<'a> UnwindSafe for Incoming<'a>
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