Skip to main content

SourceCallback

Type Alias SourceCallback 

Source
pub type SourceCallback = Box<dyn FnMut() + Send>;
Expand description

Called when a foreign source descriptor becomes readable.

The dispatcher never reads from the descriptor itself: the callback must drain it (eventfd_read, signalfd_siginfo, recvmsg, …) before returning, or the next dispatch fires the same callback again.

Aliased Type§

pub struct SourceCallback(/* private fields */);