pub struct StateSnapshot {
pub snapshot_id: u64,
pub created_at_secs: u64,
pub node_id: String,
pub fields: Vec<FieldData>,
pub format_version: u32,
}Expand description
A complete, point-in-time snapshot of TensorLogic runtime state.
Fields§
§snapshot_id: u64Unique, monotonically increasing identifier.
created_at_secs: u64Unix epoch seconds when the snapshot was taken.
node_id: StringIdentifier of the node that created the snapshot.
fields: Vec<FieldData>Fields captured in this snapshot.
format_version: u32Schema / format version (default 1).
Implementations§
Source§impl StateSnapshot
impl StateSnapshot
Sourcepub fn total_size(&self) -> u64
pub fn total_size(&self) -> u64
Sum of all field payload sizes in bytes.
Sourcepub fn has_field(&self, field: &SnapshotField) -> bool
pub fn has_field(&self, field: &SnapshotField) -> bool
Returns true when the snapshot contains field.
Sourcepub fn field_count(&self) -> usize
pub fn field_count(&self) -> usize
Number of distinct fields present in the snapshot.
Trait Implementations§
Source§impl Clone for StateSnapshot
impl Clone for StateSnapshot
Source§fn clone(&self) -> StateSnapshot
fn clone(&self) -> StateSnapshot
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 moreAuto Trait Implementations§
impl Freeze for StateSnapshot
impl RefUnwindSafe for StateSnapshot
impl Send for StateSnapshot
impl Sync for StateSnapshot
impl Unpin for StateSnapshot
impl UnsafeUnpin for StateSnapshot
impl UnwindSafe for StateSnapshot
Blanket Implementations§
impl<T> Allocation 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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more