settle function
MoveCallBuilder
settle({})
Permissionlessly folds accumulator-delivered T at the wrapper address into
stored account balance. The per-coin timestamp is latched before reading the
accumulator, preventing duplicate withdrawal and same-timestamp double counting
even when no funds are available. Only the wrapper UID can authenticate the
address-balance withdrawal; value leaving the account still requires a mutable
borrow through Auth.
Implementation
MoveCallBuilder settle(
{required dynamic arguments,
String? package,
List<String> typeArguments = const [],
Map<String, dynamic>? config}) {
final packageAddress = package ??
(config?['accountPackageId'] as String?) ??
'@local-pkg/account';
return (tx) => tx.moveCall(
'$packageAddress::account::settle',
typeArguments: typeArguments,
arguments: normalizeMoveArguments(
tx,
arguments,
[null, '0x2::accumulator::AccumulatorRoot', '0x2::clock::Clock'],
['wrapper']),
);
}