estimateFees method

Future<Map<String, dynamic>> estimateFees()

Implementation

Future<Map<String, dynamic>> estimateFees() async {
  var opResults = await dryRunOperation(
      server,
      chainId,
      this.operations.map((e) {
        e.gasLimit = TezosConstants.OperationGasCap ~/ operations.length;
        e.storageLimit =
            TezosConstants.OperationStorageCap ~/ operations.length;
        return e;
      }).toList());

  var estimatedResources =
      await estimateOperation(server, chainId, opResults);

  return estimatedResources;
}