Expand description
base32_dns encoding and decoding.
This module provides base32_dns encoding/decoding using a 32-character alphabet. Both padded and unpadded variants are available.
Constants§
- PADDED
- Padded base32_dns encoding (alias of STD).
- RAW
- Raw base32_dns encoding without padding.
- STD
- Standard base32_dns encoding with padding.
Functions§
- decode
- Decodes base32_dns encoded bytes with padding.
- decode_
len - Returns the decoded output length for padded input.
- decode_
mut - Decodes base32_dns encoded bytes into a mutable buffer with padding.
- decode_
n - Decodes a fixed-size base32_dns array with padding.
- decode_
raw - Decodes base32_dns encoded bytes without padding.
- decode_
raw_ len - Returns the decoded output length for unpadded input.
- decode_
raw_ mut - Decodes base32_dns encoded bytes into a mutable buffer without padding.
- decode_
raw_ n - Decodes a fixed-size base32_dns array without padding.
- decode_
writer - Creates a decoding writer that wraps an
io::Write.\n\nThe writer buffers base32_dns encoded bytes with padding, decodes them, and writes the raw output to the inner writer.\n\n# Examples\n\n\nuse omp_core::base32_dns;\nuse std::io::Write;\n\nlet mut output = Vec::new();\nlet encoded = base32_dns::encode(b\"Hello\").into_vec();\nlet mut writer = base32_dns::decode_writer(&mut output);\nwriter.write_all(&encoded).unwrap();\nwriter.flush().unwrap();\nassert_eq!(output, b\"Hello\");\n\n - decode_
writer_ raw - Creates a decoding writer for unpadded base32_dns.\n\nThe writer buffers base32_dns encoded bytes without padding, decodes them, and writes the raw output to the inner writer.\n\n# Examples\n\n
\nuse omp_core::base32_dns;\nuse std::io::Write;\n\nlet mut output = Vec::new();\nlet encoded = base32_dns::encode_raw(b\"Hello\").into_vec();\nlet mut writer = base32_dns::decode_writer_raw(&mut output);\nwriter.write_all(&encoded).unwrap();\nwriter.flush().unwrap();\nassert_eq!(output, b\"Hello\");\n\n - encode
- Encodes a byte slice to base32_dns with padding.
- encode_
len - Returns the encoded length including padding.
- encode_
mut - Encodes bytes into a mutable buffer with padding.
- encode_
n - Encodes a fixed-size byte array to base32_dns with padding.
- encode_
raw - Encodes a byte slice to base32_dns without padding.
- encode_
raw_ len - Returns the encoded length without padding.
- encode_
raw_ mut - Encodes bytes into a mutable buffer without padding.
- encode_
raw_ n - Encodes a fixed-size byte array to base32_dns without padding.
- encode_
writer - Creates an encoding writer that wraps an
io::Write.\n\nThe writer buffers raw bytes, encodes them to base32_dns with padding, and writes the encoded output to the inner writer.\n\n# Examples\n\n\nuse omp_core::base32_dns;\nuse std::io::Write;\n\nlet mut output = Vec::new();\nlet mut writer = base32_dns::encode_writer(&mut output);\nwriter.write_all(b\"Hello\").unwrap();\nwriter.flush().unwrap();\n\n - encode_
writer_ raw - Creates an encoding writer for unpadded base32_dns.\n\nThe writer buffers raw bytes, encodes them to base32_dns without padding, and writes the encoded output to the inner writer.\n\n# Examples\n\n
\nuse omp_core::base32_dns;\nuse std::io::Write;\n\nlet mut output = Vec::new();\nlet mut writer = base32_dns::encode_writer_raw(&mut output);\nwriter.write_all(b\"Hello\").unwrap();\nwriter.flush().unwrap();\n\n