Core Library0.xAPI Reference

Choose documentation 3

latest

Current version

latest
English

Early release libtmux is released, and its APIs may still change between releases. This site's structure and URLs may change too.

method libtmux-rs latest

ControlEvents.next_event

Return the next notification or terminal error, then None.

Source and package
Qualified name
libtmux::control::ControlEvents::next_event
Module
control
Declared in
ControlEvents
Package
libtmux
Source
crates/libtmux/src/control.rs
pub async fn next_event(&mut self) -> Option< Result<Event, Error> >

Description#

Once None is returned, subsequent calls also return None. See ControlEvents for the EOF and cleanup contract.

Errors

Yields one terminal error for transport failure, unexpected EOF, a frame budget or command deadline being exceeded, executor shutdown, or failed connection cleanup. A panic in the connection task resumes here instead, since nothing else would report it.

Cancel safety

Nothing happened: a dropped call consumes neither an event nor the terminal error.

Guides#

Pages that discuss next_event.

Esc

Type to search.

Reference previewOpen reference