toPrivateKeyObject method

AptosAccountObject toPrivateKeyObject()

Implementation

AptosAccountObject toPrivateKeyObject() {
  final privateKey = signingKey.privateKey.bytes.sublist(0, 32);
  return AptosAccountObject(
    address: address,
    publicKeyHex: pubKey().hex(),
    privateKeyHex: HexString.fromUint8Array(Uint8List.fromList(privateKey)).hex(),
  );
}