GnoOsTokenRedeemer
Inherits: IGnoOsTokenRedeemer, OsTokenRedeemer →
This contract is used to redeem OsTokens for the underlying asset.
Functions
permitGnoToken
Permit GNO tokens to be used for swap.
function permitGnoToken(uint256 amount, uint256 deadline, uint8 v, bytes32 r, bytes32 s) external override;
Parameters
| Name | Type | Description |
|---|---|---|
amount | uint256 | The number of tokens to permit |
deadline | uint256 | The deadline for the permit |
v | uint8 | The recovery byte of the signature |
r | bytes32 | The output of the ECDSA signature |
s | bytes32 | The output of the ECDSA signature |
swapAssetsToOsTokenShares
Swap assets to OsToken shares
function swapAssetsToOsTokenShares(address receiver, uint256 assets)
external
override
returns (uint256 osTokenShares);
Parameters
| Name | Type | Description |
|---|---|---|
receiver | address | The address to receive the OsToken shares |
assets | uint256 | The amount of assets to swap |
Returns
| Name | Type | Description |
|---|---|---|
osTokenShares | uint256 | The amount of OsToken shares received |