pub fn encode_to_fmt<T: AsRef<[u5]>>(
    fmt: &mut dyn Write,
    hrp: &str,
    data: T,
    variant: Variant
) -> Result<Result, Error>
Expand description

Encode a bech32 payload to an fmt::Write. This method is intended for implementing traits from std::fmt.

Errors

  • If [check_hrp] returns an error for the given HRP.

Deviations from standard

  • No length limits are enforced for the data part