Expand description
§Qubit IO
Small I/O trait utilities for Rust.
This crate provides named, object-safe composition traits for common
std::io capability combinations and small extension traits for recurring
standard-library I/O patterns. The concrete trait definitions live in
dedicated modules and are re-exported from the crate root for ergonomic use.
Modules§
- prelude
- Common extension and composition traits for Qubit IO users.
Structs§
- BigEndian
- Type-level marker for big-endian byte order.
- Binary
Codec - Type-level unchecked binary codec for one scalar type and one byte order.
- Binary
Reader - Reader wrapper for fixed-width binary values.
- Binary
Writer - Writer wrapper for fixed-width binary values.
- Buffered
Binary Reader - Buffered reader for fixed-width binary values.
- Buffered
Binary Writer - Buffered writer for fixed-width binary values.
- Buffered
Leb128 Reader - Buffered reader for LEB128 integers.
- Buffered
Leb128 Writer - Buffered writer for canonical LEB128 integers.
- Buffered
ZigZag Reader - Buffered reader for ZigZag + unsigned LEB128 integers.
- Buffered
ZigZag Writer - Buffered writer for canonical ZigZag + unsigned LEB128 integers.
- Checksum
Reader - Reader wrapper that updates a checksum hasher with bytes read.
- Checksum
Writer - Writer wrapper that updates a checksum hasher with bytes written.
- Coder
Progress - Counts how much work a
crate::Codercompleted before returning. - Counting
Reader - Reader wrapper that counts successfully read bytes.
- Counting
Writer - Writer wrapper that counts successfully written bytes.
- Leb128
Codec - Type-level unchecked LEB128 codec.
- Leb128
Decode Error - Error reported while decoding a LEB128 integer from a byte buffer.
- Leb128
Reader - Reader wrapper for LEB128 integers.
- Leb128
Writer - Writer wrapper for canonical LEB128 integers.
- Limit
Reader - Reader wrapper that exposes at most a fixed number of bytes.
- Limit
Writer - Writer wrapper that accepts at most a fixed number of bytes.
- Little
Endian - Type-level marker for little-endian byte order.
- NonStrict
- Marker type selecting non-strict decoding.
- Position
Guard - Guard that restores a seekable stream to its original position.
- Strict
- Marker type selecting strict decoding.
- TeeReader
- Reader wrapper that mirrors read bytes into a branch writer.
- TeeWriter
- Writer wrapper that mirrors accepted bytes into a branch writer.
- ZigZag
Codec - Type-level unchecked ZigZag + unsigned LEB128 codec.
- ZigZag
Reader - Reader wrapper for ZigZag + unsigned LEB128 integers.
- ZigZag
Writer - Writer wrapper for canonical ZigZag + unsigned LEB128 integers.
Enums§
- Byte
Order - Runtime byte order selector.
- Coder
Status - Reports why a
crate::Coderstopped converting input. - Leb128
Decode Error Kind - Classifies failures detected while decoding LEB128 integers.
- Streams
- Stream utility namespace.
Traits§
- Binary
Read Ext - Extension methods for reading fixed-width binary values from byte streams.
- Binary
Write Ext - Extension methods for writing fixed-width binary values to byte streams.
- BufRead
Ext - Extension methods for
BufReadvalues. - BufRead
Seek - Object-safe capability trait for values that can be buffered-read and repositioned.
- Byte
Order Spec - Describes a type-level byte order.
- Coder
- Converts one sequence of code units into another sequence of code units.
- Decode
Policy - Describes a type-level decoding policy.
- Leb128
Read Ext - Extension methods for reading LEB128 integers from byte streams.
- Leb128
Write Ext - Extension methods for writing canonical LEB128 integers to byte streams.
- ReadExt
- Extension methods for
Readvalues. - Read
Seek - Object-safe capability trait for values that can be read and repositioned.
- Read
Seek Ext - Extension methods for values that implement both
ReadandSeek. - Read
Write - Object-safe capability trait for values that can be both read and written.
- Read
Write Seek - Object-safe capability trait for values that can be read, written, and repositioned.
- SeekExt
- Extension methods for
Seekvalues. - String
Read Ext - Extension methods for reading length-prefixed UTF-8 strings.
- String
Write Ext - Extension methods for writing length-prefixed UTF-8 strings.
- Write
Ext - Extension methods for
Writevalues. - Write
Seek - Object-safe capability trait for values that can be written and repositioned.
- Write
Seek Ext - Extension methods for values that implement both
WriteandSeek. - ZigZag
Read Ext - Extension methods for reading ZigZag + unsigned LEB128 integers.
- ZigZag
Write Ext - Extension methods for writing ZigZag + unsigned LEB128 integers.