tuweni / org.apache.tuweni.ssz / SSZ / encodeBigInteger

encodeBigInteger

static fun encodeBigInteger(value: BigInteger!, bitLength: Int): Bytes! (source)

Encode a big integer to a Bytes value.

Parameters

value - BigInteger!: the big integer to encode

bitLength - Int: the bit length of the integer value (must be a multiple of 8)

Exceptions

IllegalArgumentException - if the value is too large for the specified bitLength

Return
Bytes!: the SSZ encoding in a Bytes value