pub enum Part {
Text {
text: String,
metadata: Option<Value>,
},
File {
file: FileContent,
metadata: Option<Value>,
},
Data {
data: Value,
metadata: Option<Value>,
},
}Expand description
Part content — internally tagged enum using kind as the discriminator.
Matches the A2A reference SDK wire format:
{"kind": "text", "text": "..."}{"kind": "file", "file": {"uri": "...", "mimeType": "..."}}{"kind": "data", "data": {...}}
Variants§
Text
Text content part
File
File content part (inline bytes or URI reference)
Data
Structured data part
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Part
impl<'de> Deserialize<'de> for Part
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Part
Auto Trait Implementations§
impl Freeze for Part
impl RefUnwindSafe for Part
impl Send for Part
impl Sync for Part
impl Unpin for Part
impl UnsafeUnpin for Part
impl UnwindSafe for Part
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