legacyEip712Encode method
EncoderResult
legacyEip712Encode(
- AbiParameter params,
- SolidityAddress input,
- bool keepSize
override
Legacy EIP-712 encoding for BaseHexAddress.
Optionally keeps the size unchanged based on the keepSize
parameter.
Implementation
@override
EncoderResult legacyEip712Encode(
AbiParameter params, SolidityAddress input, bool keepSize) {
if (keepSize) return abiEncode(params, input);
List<int> addrBytes = input.toBytes();
addrBytes = addrBytes.sublist(addrBytes.length - addrLength);
return EncoderResult(
isDynamic: false, encoded: input.toBytes(), name: params.name);
}