Crate atm_io_utils

Source
Expand description

Utilities for working with std::io and futures_io.

Modules§

limited_reader
A wrapper around a reader that limits how many bytes can be read from it.
partial
Helpers to test partial and Pending io operations.

Macros§

read_nz
A variant of try_ready! that checks whether the expression evaluates to 0, and emits a futures_io::Error of kind UnexpectedEof with the given message if so.
retry
Helper macro for working with io::Result in a context where ErrorKind::Interrupted means to retry an action. This macro corresponds to std::try, but it will reevaluate the expression until it does not evaluate to an Err of kind Interrupted.
write_nz
A variant of try_ready! that checks whether the expression evaluates to 0, and emits a futures_io::Error of kind WriteZero with the given message if so.

Structs§

Duplex
Implements both AsyncRead and AsyncWrite by delegating to an AsyncRead and an AsyncWrite, taking ownership of both.