AlgebraPool

Modifiers

onlyFactoryOwner

onlyValidTicks

Variables

mapping(bytes32 => struct AlgebraPool.Position) positions

Returns the information about a position by the position's key

Functions

constructor

PoolImmutables

constructor() public

timepoints

timepoints(uint256) view external

Returns data about a specific timepoint index

Returns:

getInnerCumulatives

onlyValidTicks

getInnerCumulatives(int24,int24) view external

Returns a snapshot of the tick cumulative, seconds per liquidity and seconds inside a tick range

Returns:

getTimepoints

getTimepoints(uint32[]) view external

Returns the cumulative tick and liquidity as of each timestamp `secondsAgo` from the current block timestamp

Returns:

initialize

initialize(uint160) external

Sets the initial price for the pool

mint

lock, onlyValidTicks

mint(address,address,int24,int24,uint128,bytes) external

Adds liquidity for the given recipient/bottomTick/topTick position

Returns:

collect

lock

collect(address,int24,int24,uint128,uint128) external

Collects tokens owed to a position

Returns:

burn

lock, onlyValidTicks

burn(int24,int24,uint128) external

Burn liquidity from the sender and account tokens owed for the liquidity to the position

Returns:

swap

swap(address,bool,int256,uint160,bytes) external

Swap token0 for token1, or token1 for token0

Returns:

swapSupportingFeeOnInputTokens

swapSupportingFeeOnInputTokens(address,address,bool,int256,uint160,bytes) external

Swap token0 for token1, or token1 for token0 (tokens that have fee on transfer)

Returns:

flash

lock

flash(address,uint256,uint256,bytes) external

Receive token0 and/or token1 and pay it back, plus a fee, in the callback

setCommunityFee

lock, onlyFactoryOwner

setCommunityFee(uint8,uint8) external

Set the community's % share of the fees. Cannot exceed 25% (250)

setIncentive

setIncentive(address) external

Sets an active incentive

setLiquidityCooldown

onlyFactoryOwner

setLiquidityCooldown(uint32) external

Sets new lock time for added liquidity