seawater

package
v0.0.0-...-845e4b4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 20, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	TopicMintPosition            = abi.Events["MintPosition"].ID
	TopicBurnPosition            = abi.Events["BurnPosition"].ID
	TopicTransferPosition        = abi.Events["TransferPosition"].ID
	TopicUpdatePositionLiquidity = abi.Events["UpdatePositionLiquidity"].ID
	TopicCollectFees             = abi.Events["CollectFees"].ID
	TopicNewPool                 = abi.Events["NewPool"].ID
	TopicCollectProtocolFees     = abi.Events["CollectProtocolFees"].ID
	TopicSwap2                   = abi.Events["Swap2"].ID
	TopicSwap1                   = abi.Events["Swap1"].ID
)

Functions

This section is empty.

Types

type BurnPosition

type BurnPosition struct {
	events.Event

	PosId int           `json:"pos_id"`
	Owner types.Address `json:"owner"`
}

func UnpackBurnPosition

func UnpackBurnPosition(topic1, topic2 ethCommon.Hash, d []byte) (*BurnPosition, error)

type CollectFees

type CollectFees struct {
	events.Event

	PosId   int                  `json:"pos_id"`
	Pool    types.Address        `json:"pool"`
	To      types.Address        `json:"to" gorm:"column:to_" json:"to"`
	Amount0 types.UnscaledNumber `json:"amount0"`
	Amount1 types.UnscaledNumber `json:"amount1"`
}

func UnpackCollectFees

func UnpackCollectFees(topic1, topic2, topic3 ethCommon.Hash, d []byte) (*CollectFees, error)

type CollectProtocolFees

type CollectProtocolFees struct {
	events.Event

	Pool    types.Address        `json:"pool"`
	To      types.Address        `gorm:"column:to_" json:"to"`
	Amount0 types.UnscaledNumber `json:"amount0"`
	Amount1 types.UnscaledNumber `json:"amount1"`
}

func UnpackCollectProtocolFees

func UnpackCollectProtocolFees(topic1, topic2 ethCommon.Hash, d []byte) (*CollectProtocolFees, error)

type MintPosition

type MintPosition struct {
	events.Event

	PosId int           `json:"pos_id"`
	Owner types.Address `json:"owner"`
	Pool  types.Address `json:"pool"`
	Lower types.Number  `json:"lower"`
	Upper types.Number  `json:"upper"`
}

func UnpackMintPosition

func UnpackMintPosition(topic1, topic2, topic3 ethCommon.Hash, d []byte) (*MintPosition, error)

type NewPool

type NewPool struct {
	events.Event

	Token       types.Address `json:"token"`
	Fee         uint32        `json:"fee"`
	Decimals    uint8         `json:"decimals"`
	TickSpacing uint8         `json:"tickSpacing"`
}

NewPool created

func UnpackNewPool

func UnpackNewPool(topic1, topic2, topic3 ethCommon.Hash, d []byte) (*NewPool, error)

type Swap1

type Swap1 struct {
	events.Event

	User       types.Address        `json:"user_" gorm:"column:user_"`
	Pool       types.Address        `json:"pool_"`
	ZeroForOne bool                 `json:"zeroForOne"`
	Amount0    types.UnscaledNumber `json:"amount0"`
	Amount1    types.UnscaledNumber `json:"amount1"`
	FinalTick  types.Number         `json:"finalTick"`
}

func UnpackSwap1

func UnpackSwap1(topic1, topic2 ethCommon.Hash, d []byte) (*Swap1, error)

type Swap2

type Swap2 struct {
	events.Event

	User        types.Address        `gorm:"column:user_" json:"user"`
	From        types.Address        `gorm:"column:from_" json:"from"`
	To          types.Address        `gorm:"column:to_" json:"to"`
	AmountIn    types.UnscaledNumber `json:"amountIn"`
	AmountOut   types.UnscaledNumber `json:"amountOut"`
	FluidVolume types.UnscaledNumber `json:"fluidVolume"`
	FinalTick0  types.Number         `json:"finalTick0"`
	FinalTick1  types.Number         `json:"finalTick1"`
}

func UnpackSwap2

func UnpackSwap2(topic1, topic2, topic3 ethCommon.Hash, d []byte) (*Swap2, error)

type TransferPosition

type TransferPosition struct {
	events.Event

	From  types.Address `json:"from_" gorm:"column:from_"`
	To    types.Address `json:"to_" gorm:"column:to_" json:"to"`
	PosId int           `json:"pos_id"`
}

func UnpackTransferPosition

func UnpackTransferPosition(topic1, topic2, topic3 ethCommon.Hash, d []byte) (*TransferPosition, error)

type UpdatePositionLiquidity

type UpdatePositionLiquidity struct {
	events.Event

	PosId  int                  `json:"pos_id"`
	Token0 types.UnscaledNumber `json:"token0"`
	Token1 types.UnscaledNumber `json:"token1"`
}

func UnpackUpdatePositionLiquidity

func UnpackUpdatePositionLiquidity(topic1, topic2 ethCommon.Hash, d []byte) (*UpdatePositionLiquidity, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL