Skip to main content
Helpful?

ISubscriber

Git Source | Generated with forge doc

Interface that a Subscriber contract should implement to receive updates from the v4 position manager

Functions

notifySubscribe

function notifySubscribe(uint256 tokenId, bytes memory data) external;

Parameters

NameTypeDescription
tokenIduint256the token ID of the position
databytesadditional data passed in by the caller

notifyUnsubscribe

Called when a position unsubscribes from the subscriber

This call's gas is capped at unsubscribeGasLimit (set at deployment)

Because of EIP-150, solidity may only allocate 63/64 of gasleft()

function notifyUnsubscribe(uint256 tokenId) external;

Parameters

NameTypeDescription
tokenIduint256the token ID of the position

notifyModifyLiquidity

function notifyModifyLiquidity(uint256 tokenId, int256 liquidityChange, BalanceDelta feesAccrued) external;

Parameters

NameTypeDescription
tokenIduint256the token ID of the position
liquidityChangeint256the change in liquidity on the underlying position
feesAccruedBalanceDeltathe fees to be collected from the position as a result of the modifyLiquidity call

notifyTransfer

function notifyTransfer(uint256 tokenId, address previousOwner, address newOwner) external;

Parameters

NameTypeDescription
tokenIduint256the token ID of the position
previousOwneraddressaddress of the old owner
newOwneraddressaddress of the new owner
Helpful?