#[non_exhaustive]pub struct StateChange {
pub changed: HashMap<Id, HashMap<String, State>>,
pub extra: Map<String, Value>,
}Expand description
A state change push notification (RFC 8620 §7.1).
Sent over both SSE (as a push event) and WebSocket (as a frame type).
§extra equality is feature-flag-dependent (bd:JMAP-6r7c.43)
The derived PartialEq / Eq impl’s behaviour on the extra field
depends on the global serde_json/preserve_order feature flag — see
the crate-level note
for the canonical statement.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.changed: HashMap<Id, HashMap<String, State>>For each account that changed: maps data-type name to the new State token.
Outer key: account Id. Inner key: JMAP data-type name (e.g. "Email").
Inner value: new opaque state string; pass to Email/changes etc. as sinceState.
extra: Map<String, Value>Catch-all for vendor / site / private extension fields not covered by the typed fields above. Preserves unknown fields across deserialize/serialize round-trip per workspace extras-preservation policy (see workspace AGENTS.md).
Trait Implementations§
Source§impl Clone for StateChange
impl Clone for StateChange
Source§fn clone(&self) -> StateChange
fn clone(&self) -> StateChange
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 Debug for StateChange
impl Debug for StateChange
Source§impl<'de> Deserialize<'de> for StateChange
impl<'de> Deserialize<'de> for StateChange
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 Eq for StateChange
Source§impl PartialEq for StateChange
impl PartialEq for StateChange
Source§fn eq(&self, other: &StateChange) -> bool
fn eq(&self, other: &StateChange) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for StateChange
impl Serialize for StateChange
impl StructuralPartialEq for StateChange
Auto Trait Implementations§
impl Freeze for StateChange
impl RefUnwindSafe for StateChange
impl Send for StateChange
impl Sync for StateChange
impl Unpin for StateChange
impl UnsafeUnpin for StateChange
impl UnwindSafe for StateChange
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