BaseN

object BaseN(source)

Use this to manually encode/decode BaseN, but only if you know what you're doing! Originally created by CJS on 2018/7/14 without documentation and since -- even though it is extremely versatile -- it performs poorly, we better keep it like that. After all, we don't want to tempt folk to produce code that performs poorly.

Functions

Link copied to clipboard
fun decode(alphabet: String, base: BigInteger, input: String): ByteArray
Link copied to clipboard
fun decodeToBigInteger(alphabet: String, base: BigInteger, input: String): BigInteger
Link copied to clipboard
fun encode(alphabet: String, base: BigInteger, input: ByteArray): String