#peek #async-io #io #async #udp #tcp-udp #tcp

async-peek

Read data asynchronously without removing it from the queue

Show the crate…

5 unstable releases

0.3.2 Aug 27, 2020
0.3.1 Aug 27, 2020
0.2.1 Aug 16, 2020
0.1.4 Aug 16, 2020
0.0.0 Aug 14, 2020

#33 in #peek


Used in async-tcp

MPL-2.0 license

10KB
116 lines

Read data asynchronously without removing it from the queue

img img img

This crate provides a trait to read data asynchronously without removing it from the queue (like when using the blocking methods std::net::TcpStream::peek() and std::net::UdpSocket::peek()).

License

This Source Code Form is subject to the terms of the Mozilla Public License, v. 2.0. If a copy of the MPL was not distributed with this file, You can obtain one at http://mozilla.org/MPL/2.0/.


lib.rs:

This crate provides AsyncPeek, a trait to read data asynchronously without removing it from the queue (like when using the blocking methods [std::net::TcpStream::peek()] and [std::net::UdpSocket::peek()]).

Dependencies

~0–9MB
~92K SLoC