Expand description
Module containing a contract’s types and functions.
interface IMaverickPool {
event Swap(address sender, address recipient, bool tokenAIn, bool exactOutput, uint256 amountIn, uint256 amountOut, int32 activeTick);
event AddLiquidity(address indexed sender, uint256 indexed tokenId, BinDelta[] binDeltas);
event MigrateBinsUpStack(address indexed sender, uint128 binId, uint32 maxRecursion);
event TransferLiquidity(uint256 fromTokenId, uint256 toTokenId, RemoveLiquidityParams[] params);
event RemoveLiquidity(address indexed sender, address indexed recipient, uint256 indexed tokenId, BinDelta[] binDeltas);
event BinMerged(uint128 indexed binId, uint128 reserveA, uint128 reserveB, uint128 mergeId);
event BinMoved(uint128 indexed binId, int128 previousTick, int128 newTick);
event ProtocolFeeCollected(uint256 protocolFee, bool isTokenA);
event SetProtocolFeeRatio(uint256 protocolFee);
function fee() external view returns (uint256);
function lookback() external view returns (int256);
function tickSpacing() external view returns (uint256);
function tokenA() external view returns (address);
function tokenB() external view returns (address);
function factory() external view returns (address);
function binMap(int32 tick) external view returns (uint256);
function binPositions(int32 tick, uint256 kind) external view returns (uint128);
function binBalanceA() external view returns (uint128);
function binBalanceB() external view returns (uint128);
function getTwa() external view returns (TwaState memory);
function getCurrentTwa() external view returns (int256);
function getState() external view returns (State memory);
function getBin(uint128 binId) external view returns (BinState memory bin);
function balanceOf(uint256 tokenId, uint128 binId) external view returns (uint256 lpToken);
function tokenAScale() external view returns (uint256);
function tokenBScale() external view returns (uint256);
function swap(address recipient, uint256 amount, bool tokenAIn, bool exactOutput, uint256 sqrtPriceLimit, bytes calldata data) external returns (uint256 amountIn, uint256 amountOut);
}
Modules§
- Contains dynamic ABI definitions for this contract.
Structs§
- Event with signature
AddLiquidity(address,uint256,(uint128,uint128,uint256,uint128,uint8,int32,bool)[])
and selector0x133a027327582be2089f6ca47137e3d337be4ca2cd921e5f0b178c9c2d5b8364
. - Event with signature
BinMerged(uint128,uint128,uint128,uint128)
and selector0x8ecf1f9da718dc4c174482cdb4e334113856b46a85e5694deeec06d512e8f772
. - Event with signature
BinMoved(uint128,int128,int128)
and selector0x42e51620e75096344ac889cc1d899ab619aedbe89a4f6b230ee3cecb849c7e2f
. - A
IMaverickPool
instance. - Event with signature
MigrateBinsUpStack(address,uint128,uint32)
and selector0x6deceb91de75f84acd021df8c6410377aa442257495a79a9e3bfc7eba745853e
. - Event with signature
ProtocolFeeCollected(uint256,bool)
and selector0x292394e5b7a6b75d01122bb2dc85341cefec10b852325db9d3658a452f5eb211
. - Event with signature
RemoveLiquidity(address,address,uint256,(uint128,uint128,uint256,uint128,uint8,int32,bool)[])
and selector0x65da280c1e973a1c5884c38d63e2c2b3c2a3158a0761e76545b64035e2489dfe
. - Event with signature
SetProtocolFeeRatio(uint256)
and selector0x06e6ba2b10970ecae3ab2c29feb60ab2503358820756ef14a9827b0fa5add30f
. - Event with signature
Swap(address,address,bool,bool,uint256,uint256,int32)
and selector0x3b841dc9ab51e3104bda4f61b41e4271192d22cd19da5ee6e292dc8e2744f713
. - Event with signature
TransferLiquidity(uint256,uint256,(uint128,uint128)[])
and selector0xd384edefdfebd0bb45d82f94aed5ff327fd6510cc6c53ddc78a3ef4a0e7c715c
. - Function with signature
balanceOf(uint256,uint128)
and selector0x6da3bf8b
. - Container type for the return parameters of the
balanceOf(uint256,uint128)
function. - Function with signature
binBalanceA()
and selector0x75bbbd73
. - Container type for the return parameters of the
binBalanceA()
function. - Function with signature
binBalanceB()
and selector0xfa158509
. - Container type for the return parameters of the
binBalanceB()
function. - Function with signature
binMap(int32)
and selector0xa2ba172f
. - Container type for the return parameters of the
binMap(int32)
function. - Function with signature
binPositions(int32,uint256)
and selector0x83f9c632
. - Container type for the return parameters of the
binPositions(int32,uint256)
function. - Function with signature
factory()
and selector0xc45a0155
. - Container type for the return parameters of the
factory()
function. - Function with signature
fee()
and selector0xddca3f43
. - Container type for the return parameters of the
fee()
function. - Function with signature
getBin(uint128)
and selector0x44a185bb
. - Container type for the return parameters of the
getBin(uint128)
function. - Function with signature
getCurrentTwa()
and selector0xd3d3861a
. - Container type for the return parameters of the
getCurrentTwa()
function. - Function with signature
getState()
and selector0x1865c57d
. - Container type for the return parameters of the
getState()
function. - Function with signature
getTwa()
and selector0xa4ed496a
. - Container type for the return parameters of the
getTwa()
function. - Function with signature
lookback()
and selector0xebcbd281
. - Container type for the return parameters of the
lookback()
function. - Function with signature
swap(address,uint256,bool,bool,uint256,bytes)
and selector0xc51c9029
. - Container type for the return parameters of the
swap(address,uint256,bool,bool,uint256,bytes)
function. - Function with signature
tickSpacing()
and selector0xd0c93a7c
. - Container type for the return parameters of the
tickSpacing()
function. - Function with signature
tokenA()
and selector0x0fc63d10
. - Container type for the return parameters of the
tokenA()
function. - Function with signature
tokenAScale()
and selector0x3ab72c10
. - Container type for the return parameters of the
tokenAScale()
function. - Function with signature
tokenB()
and selector0x5f64b55b
. - Container type for the return parameters of the
tokenB()
function. - Function with signature
tokenBScale()
and selector0x21272d4c
. - Container type for the return parameters of the
tokenBScale()
function.
Enums§
- Container for all the
IMaverickPool
function calls. - Container for all the
IMaverickPool
events.
Functions§
- Creates a new wrapper around an on-chain
IMaverickPool
contract instance.