pub struct MCPHints {
pub name: String,
pub description: String,
pub title: String,
pub meta: Map<String, Value>,
pub annotations: Vec<String>,
pub skip: bool,
pub fields: HashMap<String, MCPFieldHint>,
}Expand description
MCPHints 是 MCP 前端的命令级配置。
Fields§
§name: StringMCP 工具名覆写(spec §12.4a):空=沿用点分注册名;非空则该名字是 tools/list 通告与 tools/call 接受的唯一名字(CLI/HTTP 命名不动, 两通道前缀可各自独立)。须满足 §3.1 名字文法。
description: String工具描述覆写(spec §12.4):空=summary+description 的 §3.3 合并。
title: String人类友好显示名(spec §12.4):写入 MCP 的 annotations.title;
空=沿用 title:… 注解字符串(若有)。
meta: Map<String, Value>任意工具级 _meta 键值(spec §12.4):并入工具的保留 _meta。
annotations: Vec<String>形如 “read”、“write”、“destructive”、“title:创建用户”。
skip: bool从 MCP 通道整体移除该命令:不成为工具。
fields: HashMap<String, MCPFieldHint>Trait Implementations§
Auto Trait Implementations§
impl Freeze for MCPHints
impl RefUnwindSafe for MCPHints
impl Send for MCPHints
impl Sync for MCPHints
impl Unpin for MCPHints
impl UnsafeUnpin for MCPHints
impl UnwindSafe for MCPHints
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more