#[non_exhaustive]pub struct McpConfig {
pub servers: Vec<ServerEntry>,
}Expand description
A validated mcp.json: the servers that survived per-entry validation,
in declaration order.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.servers: Vec<ServerEntry>Valid server entries, in mcpServers declaration order.
Implementations§
Source§impl McpConfig
impl McpConfig
Sourcepub fn parse(
bytes: &[u8],
manifest_spec: SpecVersion,
) -> Result<(Self, Vec<Diagnostic>), McpDisabledReason>
pub fn parse( bytes: &[u8], manifest_spec: SpecVersion, ) -> Result<(Self, Vec<Diagnostic>), McpDisabledReason>
Parse and validate an mcp.json document against the version declared
by plugin.json (§7.2, §10.1).
A top-level problem disables MCP entirely (Err); per-entry problems
skip only that server and are returned as diagnostics alongside the
surviving configuration.
Trait Implementations§
impl StructuralPartialEq for McpConfig
Auto Trait Implementations§
impl Freeze for McpConfig
impl RefUnwindSafe for McpConfig
impl Send for McpConfig
impl Sync for McpConfig
impl Unpin for McpConfig
impl UnsafeUnpin for McpConfig
impl UnwindSafe for McpConfig
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