pub struct FieldMeta {Show 17 fields
pub name: String,
pub json_name: String,
pub kind: FieldKind,
pub description: String,
pub required: bool,
pub secret: bool,
pub validate: String,
pub rules: Vec<VRule>,
pub enum_values: Vec<Value>,
pub default: Option<Value>,
pub skip: bool,
pub cli: CliField,
pub http: HTTPField,
pub mcp: MCPField,
pub elem: Option<Box<FieldMeta>>,
pub children: Vec<FieldMeta>,
pub union: Option<UnionMeta>,
}Expand description
运行时字段元数据(FieldSpec 解析 + Define-time hints 合并的产物)。
Fields§
§name: String§json_name: String§kind: FieldKind§description: String§required: bool§secret: bool§validate: String§rules: Vec<VRule>§enum_values: Vec<Value>已解析的 typed 枚举值(仅标量)。
default: Option<Value>已解析的 typed 全局默认;None 表示无默认。
skip: bool§cli: CliField§http: HTTPField§mcp: MCPField§elem: Option<Box<FieldMeta>>Ptr/Slice 的元素元数据。
children: Vec<FieldMeta>struct 的子字段。
union: Option<UnionMeta>联合的运行时树(kind == Union 时填充;变体字段表)。
Trait Implementations§
Auto Trait Implementations§
impl Freeze for FieldMeta
impl RefUnwindSafe for FieldMeta
impl Send for FieldMeta
impl Sync for FieldMeta
impl Unpin for FieldMeta
impl UnsafeUnpin for FieldMeta
impl UnwindSafe for FieldMeta
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