Expand description
§Qubit Text Codec
Low-level Unicode constants, character classification helpers, and text codec primitives for UTF-8, UTF-16, UTF-32, and ASCII-oriented code.
This crate deliberately stays below std::io::Read and std::io::Write.
Concrete text I/O adapters are expected to own buffering, EOF handling, line
endings, and std::io::Error mapping while using the codecs from this crate
for strict buffer-level encoding and decoding.
Modules§
- prelude
- Common imports for Qubit Text Codec callers.
Structs§
- Ascii
Codec - Single-byte ASCII codec for bytes.
- Charset
- Identifies the charset associated with a codec or error.
- Charset
Converter - Converts units encoded with one charset into units encoded with another charset.
- Charset
Decode Error - Error reported by a charset decoder.
- Charset
Decoder - Converts units of one charset into Unicode scalar values.
- Charset
Encode Error - Error reported by a charset encoder.
- Charset
Encoder - Converts Unicode scalar values into units of one charset.
- Coder
Progress - Counts how much work a
crate::Codercompleted before returning. - Latin1
Codec - Single-byte ISO-8859-1 codec for bytes.
- Utf8
Codec - UTF-8 byte-buffer charset codec.
- Utf16
Byte Codec - Combined byte-serialized UTF-16 codec.
- Utf16
U16Codec - Combined UTF-16
u16code-unit codec. - Utf32
Byte Codec - Combined byte-serialized UTF-32 codec.
- Utf32
U32Codec - Combined UTF-32
u32code-unit codec.
Enums§
- Ascii
- Namespace for ASCII character and code point helpers.
- Byte
Order - Runtime byte order selector.
- Charset
Convert Error - Error reported while converting between two charsets.
- Charset
Decode Error Kind - Classifies failures detected while decoding encoded units into Unicode text.
- Charset
Encode Error Kind - Classifies failures detected while encoding Unicode text into encoded units.
- Coder
Status - Reports why a
crate::Coderstopped converting input. - Decode
Status - Non-error status reported after inspecting a decoder input prefix.
- Malformed
Action - Policy used when input units do not form a valid character.
- Unicode
- Namespace for Unicode constants and encoding-independent code point helpers.
- Unicode
Bom - Unicode byte order marks supported by this crate.
- Unmappable
Action - Policy used when a character cannot be represented by the target charset.
- Utf8
- Namespace for UTF-8 constants and byte classification helpers.
- Utf16
- Namespace for UTF-16 constants and code-unit classification helpers.
- Utf32
- Namespace for UTF-32 constants and code-unit classification helpers.
Traits§
- Charset
Codec - Low-level charset algorithm for one storage-unit representation.
- Coder
- Converts one sequence of code units into another sequence of code units.
Type Aliases§
- Charset
Decode Result - Result type returned by charset decoders.
- Charset
Encode Result - Result type returned by charset encoders.