5 releases

0.2.1 Sep 19, 2022
0.2.0 Jan 20, 2019
0.1.2 Feb 18, 2018
0.1.1 Nov 15, 2017
0.1.0 Nov 15, 2017

#788 in Data structures

Download history 1114/week @ 2024-01-06 2082/week @ 2024-01-13 1940/week @ 2024-01-20 1831/week @ 2024-01-27 1488/week @ 2024-02-03 1893/week @ 2024-02-10 2112/week @ 2024-02-17 2352/week @ 2024-02-24 2039/week @ 2024-03-02 1849/week @ 2024-03-09 3042/week @ 2024-03-16 1607/week @ 2024-03-23 2187/week @ 2024-03-30 2549/week @ 2024-04-06 2983/week @ 2024-04-13 1458/week @ 2024-04-20

9,288 downloads per month
Used in 30 crates (5 directly)

MIT/Apache

26KB
586 lines

iowrap

CI

A couple of utilities that I have ended up wanting in various projects, around std::io::Read streams.

  • Eof has an eof()? -> bool to check if the stream is at the end.
  • Pos has an position() -> u64 to find out where you are in a stream.
  • ReadMany adds a read_many to Read, like read_exact but with defined EoF behaviour
  • Ignore implements Read and Write and Seek and.. and does nothing.
  • ShortRead is an intentionally, controllably naughty Read for testing.

Documentation

Please read the iowrap documentation on docs.rs.

License

MIT or Apache 2.0.


lib.rs:

Some utility methods for wrapping std::io::Read and std::io::Write.

Dependencies

~170–315KB