Safe Haskell | Safe-Inferred |
---|
Documentation
encode :: Integer -> StringSource
Generate a mnemonic for an arbitrary Integer using the Electrum word list.
Note about Electrum compatability: When encoding, Electrum only operates on inputs in chunks of 8 hex digits. This encoder is more flexible, supporting input Integers of any size (although they must be positive).
It yields the same result as Electrum's encoder as long as length of the input, when encoded in hex, is an even multiple of 8 digits.
To precisely replicate Electrum, use 'encodeChunks poeticWords' and provide chunks of 8 hex digits at a time.
encodeChunks :: WordList -> [Int] -> StringSource
Generate a mnemonic using a list of 8 digit hex numbers.