ISeawaterAMM
Inherits: ISeawaterEvents, ISeawaterExecutorSwap, ISeawaterExecutorSwapPermit2, ISeawaterExecutorQuote, ISeawaterExecutorPosition, ISeawaterExecutorUpdatePosition, ISeawaterExecutorAdminExposed
Functions
swapIn32502CA71
swaps _token for USDC
function swapIn32502CA71(address _token, uint256 _amount, uint256 _minOut) external returns (int256, int256);
Parameters
Name | Type | Description |
---|---|---|
_token | address | the token to swap |
_amount | uint256 | input amount (token) |
_minOut | uint256 | the minimum output amount (usdc), reverting if the actual output is lower |
Returns
Name | Type | Description |
---|---|---|
<none> | int256 | amount of usdc out |
<none> | int256 |
swapInPermit2CEAAB576
swaps _token for USDC
function swapInPermit2CEAAB576(
address _token,
uint256 _amount,
uint256 _minOut,
uint256 _nonce,
uint256 _deadline,
uint256 _maxAmount,
bytes memory _sig
) external returns (int256, int256);
Parameters
Name | Type | Description |
---|---|---|
_token | address | the token to swap |
_amount | uint256 | input amount (token) |
_minOut | uint256 | the minimum output amount (usdc), reverting if the actual output is lower |
_nonce | uint256 | the nonce for the token |
_deadline | uint256 | the deadline for the token |
_maxAmount | uint256 | the max amount of the token |
_sig | bytes | the signature for the token |
Returns
Name | Type | Description |
---|---|---|
<none> | int256 | amount of usdc out |
<none> | int256 |
swapOut5E08A399
swaps USDC for _token
function swapOut5E08A399(address _token, uint256 _amount, uint256 _minOut) external returns (int256, int256);
Parameters
Name | Type | Description |
---|---|---|
_token | address | the token to swap |
_amount | uint256 | input amount (usdc) |
_minOut | uint256 | the minimum output amount (token), reverting if the actual output is lower |
Returns
Name | Type | Description |
---|---|---|
<none> | int256 | amount of token out |
<none> | int256 |
swapOutPermit23273373B
swaps USDC for _token
function swapOutPermit23273373B(
address _token,
uint256 _amount,
uint256 _minOut,
uint256 _nonce,
uint256 _deadline,
uint256 _maxAmount,
bytes memory _sig
) external returns (int256, int256);
Parameters
Name | Type | Description |
---|---|---|
_token | address | the token to swap |
_amount | uint256 | input amount (usdc) |
_minOut | uint256 | the minimum output amount (token), reverting if the actual output is lower |
_nonce | uint256 | the nonce for the token |
_deadline | uint256 | the deadline for the token |
_maxAmount | uint256 | the max amount of the token |
_sig | bytes | the signature for the token |
Returns
Name | Type | Description |
---|---|---|
<none> | int256 | amount of token out |
<none> | int256 |
swap2ExactIn41203F1D
swaps tokenA for tokenB
function swap2ExactIn41203F1D(address _tokenA, address _tokenB, uint256 _amount, uint256 _minOut)
external
returns (uint256, uint256);
Parameters
Name | Type | Description |
---|---|---|
_tokenA | address | the input token |
_tokenB | address | the output token |
_amount | uint256 | input amount (tokenA) |
_minOut | uint256 | the minimum output amount (tokenB), reverting if the actual output is lower |
Returns
Name | Type | Description |
---|---|---|
<none> | uint256 | amount of token A in, amount of token B out |
<none> | uint256 |