Expand description
Codec and encoding helpers for bluetape-rs.
This crate is part of the 0.3.1 workspace release. It provides strict hexadecimal
encoding and decoding plus focused Base64, Base58, and Base62 helpers, then
grows into additional binary/text helpers in follow-up issues.
Planned APIs stay small and Rust-native:
- strict hex encoding and decoding
- Base64 standard and URL-safe variants
- Base58 and byte-oriented Base62 variants
- typed errors for caller-owned invalid encoded input
- UTF-8 text/byte boundary helpers for codec call sites
Compression belongs to 0.4.0, and serde-oriented serialization belongs to
0.5.0. This crate does not provide those APIs.
// Enable the root facade when a single dependency is more convenient:
// bluetape-rs = { version = "0.3.1", features = ["codec"] }Enums§
- Base58
Decode Error - Error returned when Base58 decoding rejects caller-owned input.
- Base62
Decode Error - Error returned when Base62 decoding rejects caller-owned input.
- Base64
Decode Error - Error returned when Base64 decoding rejects caller-owned input.
- HexDecode
Error - Error returned when strict hexadecimal decoding rejects caller-owned input.
- Text
Decode Error - Error returned when bytes cannot be decoded as UTF-8 text.
Functions§
- decode_
base58 - Decodes Bitcoin Base58 text into bytes.
- decode_
base62 - Decodes byte-oriented Base62 text into bytes.
- decode_
base64 - Decodes standard Base64 text that uses the standard alphabet and padding.
- decode_
base64_ unpadded - Decodes standard Base64 text that must not contain padding.
- decode_
base64_ url - Decodes URL-safe Base64 text that uses
=padding. - decode_
base64_ url_ unpadded - Decodes URL-safe Base64 text that must not contain padding.
- decode_
hex - Decodes strict hexadecimal text into bytes.
- decode_
utf8_ text - Decodes owned bytes into UTF-8 text without lossy replacement.
- decode_
utf8_ text_ lossy - Decodes bytes into UTF-8 text using replacement characters for invalid data.
- encode_
base58 - Encodes bytes with the Bitcoin Base58 alphabet.
- encode_
base62 - Encodes bytes with the bluetape Base62 alphabet.
- encode_
base64 - Encodes bytes with the standard Base64 alphabet and
=padding. - encode_
base64_ unpadded - Encodes bytes with the standard Base64 alphabet and no padding.
- encode_
base64_ url - Encodes bytes with the URL-safe Base64 alphabet and
=padding. - encode_
base64_ url_ unpadded - Encodes bytes with the URL-safe Base64 alphabet and no padding.
- encode_
hex_ lower - Encodes bytes as lowercase hexadecimal text.
- encode_
hex_ upper - Encodes bytes as uppercase hexadecimal text.
- encode_
utf8_ text - Encodes UTF-8 text into owned bytes.