revokeSha256HashSigner method
Implementation
RevokeSponsorshipOperationBuilder revokeSha256HashSigner(
String signerAccountId, String sha256Hash) {
if (_ledgerKey != null || _signerKey != null) {
throw new Exception("can not revoke multiple entries per builder");
}
checkNotNull(signerAccountId, "accountId cannot be null");
checkNotNull(sha256Hash, "sha256Hash cannot be null");
XdrAccountID accId = XdrAccountID();
accId.accountID = KeyPair.fromAccountId(signerAccountId).xdrPublicKey;
_signerKey = XdrSignerKey();
_signerKey.discriminant = XdrSignerKeyType.SIGNER_KEY_TYPE_HASH_X;
_signerKey.ed25519 = XdrUint256();
_signerKey.ed25519.uint256 = StrKey.decodePreAuthTx(sha256Hash);
_signerAccountId = signerAccountId;
return this;
}