pub struct StateSnapshotEvent {
pub base: BaseEvent,
pub snapshot: Value,
pub subagent_run_id: Option<SubagentRunId>,
}Expand description
Replaces the shared state wholesale.
Fields§
§base: BaseEventTimestamp and raw provider event.
snapshot: ValueThe complete new state. Free-form JSON, opaque to the protocol.
subagent_run_id: Option<SubagentRunId>The subagent that produced this update; absent means the parent
agent. A JSON null is rejected — see crate::event::subagent.
Provenance, not ownership: state is run-scoped, and an attributed
snapshot still replaces the run’s one state document.
Implementations§
Trait Implementations§
Source§impl Clone for StateSnapshotEvent
impl Clone for StateSnapshotEvent
Source§fn clone(&self) -> StateSnapshotEvent
fn clone(&self) -> StateSnapshotEvent
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl ComposeSchema for StateSnapshotEvent
impl ComposeSchema for StateSnapshotEvent
Source§impl Debug for StateSnapshotEvent
impl Debug for StateSnapshotEvent
Source§impl Default for StateSnapshotEvent
impl Default for StateSnapshotEvent
Source§fn default() -> StateSnapshotEvent
fn default() -> StateSnapshotEvent
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for StateSnapshotEvent
impl<'de> Deserialize<'de> for StateSnapshotEvent
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
Source§impl From<StateSnapshotEvent> for Event
impl From<StateSnapshotEvent> for Event
Source§fn from(payload: StateSnapshotEvent) -> Self
fn from(payload: StateSnapshotEvent) -> Self
Converts to this type from the input type.
Source§impl JsonSchema for StateSnapshotEvent
impl JsonSchema for StateSnapshotEvent
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl PartialEq for StateSnapshotEvent
impl PartialEq for StateSnapshotEvent
Source§fn eq(&self, other: &StateSnapshotEvent) -> bool
fn eq(&self, other: &StateSnapshotEvent) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for StateSnapshotEvent
impl Serialize for StateSnapshotEvent
impl StructuralPartialEq for StateSnapshotEvent
Auto Trait Implementations§
impl Freeze for StateSnapshotEvent
impl RefUnwindSafe for StateSnapshotEvent
impl Send for StateSnapshotEvent
impl Sync for StateSnapshotEvent
impl Unpin for StateSnapshotEvent
impl UnsafeUnpin for StateSnapshotEvent
impl UnwindSafe for StateSnapshotEvent
Blanket Implementations§
impl<T> AgentState for T
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