Skip to main content

encode

Function encode 

Source
pub fn encode<S: AsRef<[u8]> + ?Sized>(src: &S) -> Encoder<'_>
Expand description

Encodes a byte slice to base32 with padding.

§Arguments

  • src - The byte slice to encode

§Returns

An iterator that yields encoded bytes.

§Example

use omp_core::base32;
let encoded = base32::encode(b"hello").into_string();