ICallbackOperations
Inherits: IExactOutputSlim
Functions
exactOutputSingle
Perform an exact output single swap.
Parameters
Name | Type | Description |
---|---|---|
|
| The address of the recipient. |
|
| The Maverick V2 pool to swap with. |
|
| A boolean indicating if token A is the input. |
|
| The amount of output tokens desired. |
|
| The maximum amount of input tokens allowed. |
Returns
Name | Type | Description |
---|---|---|
|
| The amount of input tokens used for the swap. |
|
| The actual amount of output tokens received. |
outputSingleWithTickLimit
Perform an output-specified single swap with tick limit check.
Parameters
Name | Type | Description |
---|---|---|
|
| The address of the recipient. |
|
| The Maverick V2 pool to swap with. |
|
| A boolean indicating if token A is the input. |
|
| The amount of output tokens desired. |
|
| The tick limit for the swap. |
|
| The maximum amount of input tokens allowed. |
|
| The minimum amount of output tokens expected. |
Returns
Name | Type | Description |
---|---|---|
|
| The actual amount of input tokens used for the swap. |
|
| The actual amount of output tokens received. This amount can vary from the requested amountOut due to the tick limit. If the pool swaps to the tick limit, it will stop filling the order and return the amount out swapped up to the ticklimit to the user. |
exactOutputMultiHop
Perform an exact output multihop swap.
Parameters
Name | Type | Description |
---|---|---|
|
| The recipient address. |
|
| The swap path as encoded bytes. |
|
| The exact output amount. |
|
| The maximum input amount allowed. |
Returns
Name | Type | Description |
---|---|---|
|
| The input amount for the swap. |
inputSingleWithTickLimit
Perform an input-specified single swap with tick limit check.
Parameters
Name | Type | Description |
---|---|---|
|
| The address of the recipient. |
|
| The Maverick V2 pool to swap with. |
|
| A boolean indicating if token A is the input. |
|
| The amount of input tokens. |
|
| The tick limit for the swap. |
|
| The minimum amount of output tokens expected. |
Returns
Name | Type | Description |
---|---|---|
|
| The actual input amount used for the swap. This may differ from the amount the caller specified if the pool reaches the tick limit. In that case, the pool will consume the input swap amount up to the tick limit and return the resulting output amount to the user. |
|
| The amount of output tokens received. |
Last updated