pub trait AioSource {
// Required methods
fn register(&mut self, kq: RawFd, token: usize);
fn deregister(&mut self);
}
Available on FreeBSD and crate feature
net
only.Expand description
Like mio::event::Source
, but for POSIX AIO only.
Tokio’s consumer must pass an implementor of this trait to create a
Aio
object.
Required Methods§
Sourcefn register(&mut self, kq: RawFd, token: usize)
fn register(&mut self, kq: RawFd, token: usize)
Registers this AIO event source with Tokio’s reactor.
Sourcefn deregister(&mut self)
fn deregister(&mut self)
Deregisters this AIO event source with Tokio’s reactor.