encodeBip32Fvk static method

BuBytes encodeBip32Fvk(
  1. Bip32PublicKey bip32
)

Implementation

static BuBytes encodeBip32Fvk(Bip32PublicKey bip32) {
  if (bip32.type != CryptoKeyType.secp256k1) {
    throw CoreErrors.zcashInvalidKeyData(
      "Transparent full view.",
      reason: "Invalid key type.",
    );
  }
  return BuBytes([...bip32.chainCode.toBytes(), ...bip32.toPublicKeyBytes()]);
}