decode

Function decode 

Source
pub fn decode(
    encoded: &str,
    dictionary: &WordDictionary,
) -> Result<Vec<u8>, DecodeError>
Expand description

Decodes a word sequence back to binary data.

Splits the input on the dictionary’s delimiter, then performs reverse radix conversion.

§Errors

Returns DecodeError if:

  • Input is empty
  • A word is not found in the dictionary