pub enum McpNotification {
Initialized,
Cancelled(CancelledParams),
Progress(ProgressParams),
RootsListChanged,
Unknown {
method: String,
params: Option<Value>,
},
}Expand description
High-level MCP notification (parsed from JSON-RPC)
Variants§
Initialized
Client has completed initialization
Cancelled(CancelledParams)
Request cancellation
Progress(ProgressParams)
Progress update
RootsListChanged
Roots list has changed (client to server)
Unknown
Unknown notification
Implementations§
Source§impl McpNotification
impl McpNotification
Sourcepub fn from_jsonrpc(notif: &JsonRpcNotification) -> Result<Self, Error>
pub fn from_jsonrpc(notif: &JsonRpcNotification) -> Result<Self, Error>
Parse from JSON-RPC notification
Trait Implementations§
Source§impl Clone for McpNotification
impl Clone for McpNotification
Source§fn clone(&self) -> McpNotification
fn clone(&self) -> McpNotification
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for McpNotification
impl RefUnwindSafe for McpNotification
impl Send for McpNotification
impl Sync for McpNotification
impl Unpin for McpNotification
impl UnwindSafe for McpNotification
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