Skip to main content

Module base32_dns

Module base32_dns 

Source
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

Type Aliases§

Decoder
Streaming decoder for base32_dns-encoded data.
Encoder
Streaming encoder for base32_dns encoding.
Encoding
Encoding dictionary for base32_dns.