Module UniswapV3Pool

Module UniswapV3Pool 

Source
Expand description

Module containing a contract’s types and functions.

contract UniswapV3Pool {
    struct Slot0Data { uint160 sqrtPriceX96; int24 tick; uint16 observationIndex; uint16 observationCardinality; uint16 observationCardinalityNext; uint8 feeProtocol; bool unlocked; }
    struct TickInfo { uint128 liquidityGross; int128 liquidityNet; uint256 feeGrowthOutside0X128; uint256 feeGrowthOutside1X128; int56 tickCumulativeOutside; uint160 secondsPerLiquidityOutsideX128; uint32 secondsOutside; bool initialized; }
    struct PositionInfo { uint128 liquidity; uint256 feeGrowthInside0LastX128; uint256 feeGrowthInside1LastX128; uint128 tokensOwed0; uint128 tokensOwed1; }
    function slot0() external view returns (Slot0Data memory);
    function liquidity() external view returns (uint128);
    function feeGrowthGlobal0X128() external view returns (uint256);
    function feeGrowthGlobal1X128() external view returns (uint256);
    function ticks(int24 tick) external view returns (TickInfo memory);
    function positions(bytes32 key) external view returns (PositionInfo memory);
}

Structs§

PositionInfo
Position information
Slot0Data
Packed struct containing core pool state
TickInfo
Tick information
UniswapV3PoolInstance
A UniswapV3Pool instance.
feeGrowthGlobal0X128Call
Function with signature feeGrowthGlobal0X128() and selector 0xf3058399.
feeGrowthGlobal0X128Return
Container type for the return parameters of the feeGrowthGlobal0X128() function.
feeGrowthGlobal1X128Call
Function with signature feeGrowthGlobal1X128() and selector 0x46141319.
feeGrowthGlobal1X128Return
Container type for the return parameters of the feeGrowthGlobal1X128() function.
liquidityCall
Function with signature liquidity() and selector 0x1a686502.
liquidityReturn
Container type for the return parameters of the liquidity() function.
positionsCall
Function with signature positions(bytes32) and selector 0x514ea4bf.
positionsReturn
Container type for the return parameters of the positions(bytes32) function.
slot0Call
Function with signature slot0() and selector 0x3850c7bd.
slot0Return
Container type for the return parameters of the slot0() function.
ticksCall
Function with signature ticks(int24) and selector 0xf30dba93.
ticksReturn
Container type for the return parameters of the ticks(int24) function.

Enums§

UniswapV3PoolCalls
Container for all the UniswapV3Pool function calls.

Functions§

new
Creates a new wrapper around an on-chain UniswapV3Pool contract instance.