gethlyleswaps

package
v1.3.57 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteGethSwapsByBaseAssetId added in v1.3.10

func DeleteGethSwapsByBaseAssetId(baseAssetID *int) error

func GetDistinctMakerAddressesFromBaseTokenAssetID added in v1.3.11

func GetDistinctMakerAddressesFromBaseTokenAssetID(baseAssetID *int) ([]*int, error)

func GetDistinctTransactionHashesFromAssetIdAndStartingBlock added in v1.3.0

func GetDistinctTransactionHashesFromAssetIdAndStartingBlock(assetID *int, startingBlock *uint64) ([]string, error)

func GetHighestBlockFromBaseAssetId added in v1.3.13

func GetHighestBlockFromBaseAssetId(assetID *int) (*uint64, error)

func GetHighestSwapBlockFromBaseAssetId added in v1.3.10

func GetHighestSwapBlockFromBaseAssetId(assetID *int) (*uint64, error)

func GetNullAddressStrsFromSwaps added in v1.3.0

func GetNullAddressStrsFromSwaps(assetID *int) ([]string, error)

func InsertGethSwap

func InsertGethSwap(gethSwap *GethSwap) (int, string, error)

func InsertGethSwaps

func InsertGethSwaps(gethSwaps []*GethSwap) error

func RemoveGethSwapsFromAssetIDAndStartBlockNumber added in v1.3.9

func RemoveGethSwapsFromAssetIDAndStartBlockNumber(baseAssetID *int, startBlockNumber *int) error

func UpdateGethSwap

func UpdateGethSwap(gethSwap GethSwap) error

func UpdateGethSwapAddresses added in v1.3.0

func UpdateGethSwapAddresses(baseAssetID *int) error

Types

type GethSwap

type GethSwap struct {
	ID                 *int             `json:"id"`
	UUID               string           `json:"uuid"`
	ChainID            *int             `json:"chainId"`
	ExchangeID         *int             `json:"exchangeId"`
	BlockNumber        *uint64          `json:"blockNumber"`
	IndexNumber        *uint            `json:"indexNumber"`
	SwapDate           time.Time        `json:"swapDate"`
	TradeTypeID        *int             `json:"tradeTypeId"`
	TxnHash            string           `json:"txnHash"`
	MakerAddress       string           `json:"makerAddress"`
	MakerAddressID     *int             `json:"makerAddressId"`
	IsBuy              *bool            `json:"isBuy"`
	Price              *decimal.Decimal `json:"price"`
	PriceUSD           *decimal.Decimal `json:"priceUsd"`
	Token1PriceUSD     *decimal.Decimal `json:"token1PriceUsd"`
	TotalAmountUSD     *decimal.Decimal `json:"totalAmountUsd"`
	PairAddress        string           `json:"pairAddress"`
	LiquidityPoolID    *int             `json:"liquidityPoolId"`
	Token0AssetId      *int             `json:"token0Id"`
	Token1AssetId      *int             `json:"token1Id"`
	Token0Amount       *decimal.Decimal `json:"token0Amount"`
	Token1Amount       *decimal.Decimal `json:"token1Amount"`
	Description        string           `json:"description"`
	CreatedBy          string           `json:"createdBy"`
	CreatedAt          time.Time        `json:"createdAt"`
	UpdatedBy          string           `json:"updatedBy"`
	UpdatedAt          time.Time        `json:"updatedAt"`
	GethProcessJobID   *int             `json:"gethProcessJobId"`
	TopicsStr          []string         `json:"topicsStr"`
	StatusID           *int             `json:"statusId"`
	BaseAssetID        *int             `json:"baseAssetId"`
	OraclePriceUSD     *decimal.Decimal `json:"oraclePriceUsd"`
	OraclePriceAssetID *int             `json:"oraclePriceAssetId"`
}

func GetGethSwap

func GetGethSwap(gethSwapID int) (*GethSwap, error)

func GetGethSwapByBlockChain

func GetGethSwapByBlockChain(txnHash string, blockNumber *uint64, indexNumber *uint, makerAddressID *int, liquidityPoolID *int) (*GethSwap, error)

func GetGethSwapByFromBaseAssetAndBeforeBlockNumber added in v1.3.25

func GetGethSwapByFromBaseAssetAndBeforeBlockNumber(baseAssetID, blockNumber *int) ([]*GethSwap, error)

func GetGethSwapByFromMakerAddress

func GetGethSwapByFromMakerAddress(makerAddress string) ([]GethSwap, error)

func GetGethSwapByFromMakerAddressId

func GetGethSwapByFromMakerAddressId(makerAddressID *int) ([]*GethSwap, error)

func GetGethSwapByFromMakerAddressIdAndBeforeBlockNumber added in v1.3.14

func GetGethSwapByFromMakerAddressIdAndBeforeBlockNumber(baseAssetID, makerAddressID, blockNumber *int) ([]*GethSwap, error)

func GetGethSwapByStartAndEndDates

func GetGethSwapByStartAndEndDates(startDate, endDate time.Time) ([]GethSwap, error)

func GetGethSwapByTxnHash

func GetGethSwapByTxnHash(txnHash string, baseAssetID *int) ([]GethSwap, error)

func GetGethSwapsByTxnHashes added in v1.3.15

func GetGethSwapsByTxnHashes(txnHashes []string, baseAssetID *int) ([]GethSwap, error)

bulk swap methods

type GethSwapAudit

type GethSwapAudit struct {
	GethSwap
	GethSwapAuditId      *int `json:"gethSwapAuditId"`
	GethProcessVlogJobID *int `json:"gethProcessVlogJobId"`
	InsertTypeID         *int `json:"insertTypeId"`
}

Jump to

Keyboard shortcuts

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