Skip to content
LogoLogo

CurrencySettler

Git Source

Title: CurrencySettler

Production copy of v4-core's test-only CurrencySettler, using safe transfers so tokens that return no data from transfer / transferFrom (e.g. USDT) settle correctly.

Functions

settle

Settle (pay) a currency to the PoolManager.

function settle(Currency currency, IPoolManager manager, address payer, uint256 amount, bool burn) internal;

Parameters

NameTypeDescription
currencyCurrency
managerIPoolManager
payeraddress
amountuint256
burnboolIf true, burn the payer's ERC-6909 claims instead of transferring tokens.

take

Take (receive) a currency from the PoolManager.

function take(Currency currency, IPoolManager manager, address recipient, uint256 amount, bool claims) internal;

Parameters

NameTypeDescription
currencyCurrency
managerIPoolManager
recipientaddress
amountuint256
claimsboolIf true, mint ERC-6909 claims instead of transferring tokens.