pub struct Stage { /* private fields */ }Expand description
A running stage: the slots, and the one lock every terminal write inside the stage goes through.
Implementations§
Source§impl Stage
impl Stage
Sourcepub fn begin(settings: &Settings, names: &[&str]) -> Arc<Stage> ⓘ
pub fn begin(settings: &Settings, names: &[&str]) -> Arc<Stage> ⓘ
A stage over names, in dispatch order. Does nothing visible until
checks start entering (the region) or finishing (the blocks).
Sourcepub fn enter(self: &Arc<Stage>, idx: usize) -> SinkGuard
pub fn enter(self: &Arc<Stage>, idx: usize) -> SinkGuard
Route this thread’s say calls into slot idx until the guard
drops. Installed by the dispatcher around each check.run. Also
starts the slot’s clock and puts it in the region.
Sourcepub fn queue(&self, idx: usize, since: Option<(Instant, u64)>)
pub fn queue(&self, idx: usize, since: Option<(Instant, u64)>)
Slot idx is waiting for a host slot (Some), or no longer is.
Sourcepub fn attach(
self: &Arc<Stage>,
idx: usize,
activity: Arc<Activity>,
) -> AttachGuard
pub fn attach( self: &Arc<Stage>, idx: usize, activity: Arc<Activity>, ) -> AttachGuard
Show slot idx’s spawned command in the displays while the returned
guard lives. A check that runs several commands in turn attaches each
one; between them the slot falls back to its own output clock.
Sourcepub fn append_raw(&self, idx: usize, bytes: &[u8])
pub fn append_raw(&self, idx: usize, bytes: &[u8])
Append raw bytes (a captured child’s output) to slot idx.
Sourcepub fn finish(&self, settings: &Settings, idx: usize)
pub fn finish(&self, settings: &Settings, idx: usize)
The check is over: emit everything it said as ONE contiguous write, with the region lifted out of the way first and repainted after — blocks pile up above, spinners stay below.
Called by the dispatcher after check.run returns (still on the
check’s thread, so a torn-down thread cannot strand a buffer — the
same catch_unwind that feeds the dead-check outcome runs first).