pub struct MsgField {
pub name: String,
pub type_ref: MsgTypeRef,
pub is_array: bool,
pub array_size: Option<usize>,
pub string_max_len: Option<usize>,
pub description: String,
}Fields§
§name: String§type_ref: MsgTypeRef§is_array: bool§array_size: Option<usize>Fixed array size (e.g. 9 for float32[9]). None means unbounded (T[]).
string_max_len: Option<usize>Upper bound for string<=N / wstring<=N fields. None when not
declared. Preserved so MCP JSON Schema can emit maxLength.
description: StringTrailing-comment annotation from the .msg line, e.g.
# in metres or # range [0, 1]. Empty when there was no
comment. Standard ROS messages use these for units / value
ranges; we propagate them to MCP description because they
give an LLM real semantic hints about the field.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for MsgField
impl RefUnwindSafe for MsgField
impl Send for MsgField
impl Sync for MsgField
impl Unpin for MsgField
impl UnsafeUnpin for MsgField
impl UnwindSafe for MsgField
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