pub enum PartData {
Show 13 variants
Text(TextPart),
Reasoning(ReasoningPart),
Tool(ToolPart),
File(FilePart),
Agent(AgentPart),
Subtask(SubtaskPart),
Retry(RetryPart),
Compaction(CompactionPart),
StepStart(StepStartPart),
StepFinish(StepFinishPart),
Snapshot(SnapshotPart),
Patch(PatchPart),
Unknown,
}Expand description
part.data — discriminated on type.
Unknown variants land in PartData::Unknown so a future
opencode release that adds a new part type still round-trips.
Variants§
Text(TextPart)
Reasoning(ReasoningPart)
Tool(ToolPart)
File(FilePart)
Agent(AgentPart)
Subtask(SubtaskPart)
Retry(RetryPart)
Compaction(CompactionPart)
StepStart(StepStartPart)
StepFinish(StepFinishPart)
Snapshot(SnapshotPart)
Patch(PatchPart)
Unknown
Catch-all for future variants. The type tag and payload are
preserved in the typed layer only when the round-trip deserializer
records them; serde(other) discards the tag string itself.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for PartData
impl<'de> Deserialize<'de> for PartData
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
Auto Trait Implementations§
impl Freeze for PartData
impl RefUnwindSafe for PartData
impl Send for PartData
impl Sync for PartData
impl Unpin for PartData
impl UnsafeUnpin for PartData
impl UnwindSafe for PartData
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