Skip to main content

run_loop

Function run_loop 

Source
pub fn run_loop<T>(transport: &mut T, app: &mut App) -> Result<()>
where T: Transport, <T::Backend as Backend>::Error: Error + Send + Sync + 'static,
Expand description

Run the TUI until the app requests shutdown or the transport disconnects. Does not call Transport::finish; the caller owns the transport’s lifecycle.

§Errors

Propagates io::Errors from:

  • Terminal::draw, which fails if the backend’s writer is broken (stdout closed, SSH channel closed while writing).
  • Transport::poll, which fails on disconnect.