estimateAddDelegate method
Implementation
Future<BigInt> estimateAddDelegate(
String identityDid, String delegateType, String delegateDid,
[int validity = 86400]) {
var addDelegateFunction = _erc1056contract.function('addDelegate');
Transaction tx = Transaction.callContract(
contract: _erc1056contract,
function: addDelegateFunction,
parameters: [
_didToAddress(identityDid),
_to32ByteUtf8(delegateType),
_didToAddress(delegateDid),
BigInt.from(validity)
]);
return web3Client.estimateGas(
sender: _didToAddress(identityDid), data: tx.data, to: contractAddress);
}