Skip to main content

WriteLandedSink

Type Alias WriteLandedSink 

Source
pub type WriteLandedSink = Arc<dyn Fn(LandedStamp) + Send + Sync + 'static>;
Expand description

Invoked on the shared worker thread the instant a DebouncedWriter’s queued patches land successfully, with the fresh on-disk (mtime, len) stamp (one extra fs::metadata, computed once, right after the write — negligible cost). The write-side analogue of WriteFailureSink. Send + Sync because it runs off the caller’s thread — a consumer that needs to update !Send state (an Rc<Cell<_>>) must copy the value out on its own thread the next time it looks (see WindowStateService::reload_from_disk).

Aliased Type§

pub struct WriteLandedSink { /* private fields */ }