Skip to content
LogoLogo

TokenClaims

Git Source

Redeems the caller's PoolManager currency claims to a chosen recipient.

Approve this contract for the currency claim ID on PoolManager before redeeming. Claim ownership and allowances are enforced by PoolManager.burn. No hook escrow is accessible.

Constants

poolManager

IPoolManager public immutable poolManager;

State Variables

_redeeming

bool private _redeeming;

Functions

nonReentrant

modifier nonReentrant();

constructor

constructor(IPoolManager manager);

Parameters

NameTypeDescription
managerIPoolManager

redeem

function redeem(Currency currency, address recipient, uint256 amount) external nonReentrant;

Parameters

NameTypeDescription
currencyCurrency
recipientaddress
amountuint256

unlockCallback

function unlockCallback(bytes calldata data) external returns (bytes memory);

Parameters

NameTypeDescription
databytes

Returns

NameTypeDescription
<none>bytes

Events

ClaimsRedeemed

event ClaimsRedeemed(address indexed owner, address indexed recipient, Currency indexed currency, uint256 amount);

Parameters

NameTypeDescription
owneraddress
recipientaddress
currencyCurrency
amountuint256

Errors

OnlyPoolManager

error OnlyPoolManager();

InvalidRedemption

error InvalidRedemption();

ReentrantRedemption

error ReentrantRedemption();