pub struct ReloadState {
pub document: u32,
pub status: ReloadStatus,
pub generation: u32,
pub revision: u32,
pub last_good_revision: u32,
pub has_pending_edit: bool,
pub failure: Option<ReloadFailure>,
}Expand description
An owned diagnostic snapshot of the calling thread’s selected document. Source text is not copied. Inspection allocates only to clone retained error context when a failure is present; it never reads a file or consumes an edit.
Fields§
§document: u32Document selection counter, matching the existing Wasm export. Wraps.
status: ReloadStatusLatest operation; pending work is reported separately below.
generation: u32Last-good content generation; starts at zero for embedded content and advances once per successfully built, different source. Never wraps.
revision: u32Status change counter, matching the existing Wasm revision export. Wraps; compare for inequality within a document, not for numeric ordering.
last_good_revision: u32Status revision at the last accepted replacement, or zero for embedded
content. Queues, failures and unchanged edits leave this value intact.
It has the same wrapping semantics as revision.
has_pending_edit: boolAn edit still awaits polling. This may be true even after rejection of a newer invalid submission, or if a builder queues another edit.
failure: Option<ReloadFailure>Failure for the latest rejected operation; cleared by the next successful queue, unchanged edit, or accepted replacement. Idle polls preserve it.
Trait Implementations§
Source§impl Clone for ReloadState
impl Clone for ReloadState
Source§fn clone(&self) -> ReloadState
fn clone(&self) -> ReloadState
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more