structure

package
v0.0.0-...-cd2cf9c Latest Latest
Warning

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

Go to latest
Published: Jan 26, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateAccountEVM

func GenerateAccountEVM()

func GenerateAccountEVM33

func GenerateAccountEVM33(uid string)

Types

type Chain

type Chain struct {
	ChainID       uint64 `json:"ChainID"`
	ChainSymbol   string `json:"ChainSymbol"`
	ChainFullName string `json:"ChainFullName"`
}

type ChainType

type ChainType int
const (
	ChainTypeEthereum ChainType = 1
	ChainTypeBNBSmart ChainType = 2
	ChainTypeTron     ChainType = 3
)

func SupportChainType

func SupportChainType() []ChainType

type DepositOrder

type DepositOrder struct {
	Hash          string       `json:"Hash"`
	DepositState  DepositState `json:"DepositState"`
	From          string       `json:"From"`
	To            string       `json:"To"`
	UID           string       `json:"UID"`
	DepositAmount string       `json:"DepositAmount"`
	Ts            int64        `json:"Ts"`
	Remark        string       `json:"Remark"` //备注
}

type DepositState

type DepositState uint8

充币状态

const (
	DepositInit DepositState = 1 //充币交易-初始化

	DepositTransactionConfirming     DepositState = 2 //充币交易-链上确认中
	DepositTransactionConfirmSuccess DepositState = 3 //充币交易-链上确认成功
	DepositTransactionConfirmFail    DepositState = 4 //充币交易-链上确认失败

	DepositBillConfirming     DepositState = 5 //充币交易-交易所上账中
	DepositBillConfirmSuccess DepositState = 6 //充币交易-交易所上账成功
	DepositBillConfirmFail    DepositState = 7 //充币交易-交易所上账失败
)

type PrivateKeyType

type PrivateKeyType uint16
const (
	PrivateKeyTypeEVM  PrivateKeyType = 1
	PrivateKeyTypeTron PrivateKeyType = 2
)

func SupportPrivateKeyType

func SupportPrivateKeyType() []PrivateKeyType

type Token

type Token struct {
	TokenID       uint64 `json:"TokenID"`
	TokenSymbol   string `json:"TokenSymbol"`
	TokenFullName string `json:"TokenFullName"`
}

type TokenDeposit

type TokenDeposit struct {
	Chain
	Token
}

type TokenWithdraw

type TokenWithdraw struct {
	Chain
	Token
}

type WithdrawOrder

type WithdrawOrder struct {
	WithdrawID     uint64        `json:"WithdrawID"` //交易所指定的全局唯一ID
	Hash           string        `json:"Hash"`
	WithdrawState  WithdrawState `json:"WithdrawState"`
	From           string        `json:"From"`
	To             string        `json:"To"`
	WithdrawAmount string        `json:"WithdrawAmount"`
	FeeAmount      string        `json:"FeeAmount"`
	TotalAmount    string        `json:"TotalAmount"`
	Ts             int64         `json:"Ts"`
	Remark         string        `json:"Remark"` //备注
}

type WithdrawState

type WithdrawState uint8

提币状态

const (
	WithdrawInit WithdrawState = 1 //提币交易-初始化

	WithdrawTransactionBuild      WithdrawState = 2 //提币交易-链上构建
	WithdrawTransactionSign       WithdrawState = 3 //提币交易-链上签名
	WithdrawTransactionBroadcast  WithdrawState = 4 //提币交易-链上广播
	WithdrawTransactionConfirming WithdrawState = 5 //提币交易-链上确认中
	WithdrawTransactionSuccess    WithdrawState = 6 //提币交易-链上成功
	WithdrawTransactionFail       WithdrawState = 7 //提币交易-链上失败

	WithdrawBillConfirming     WithdrawState = 8  //充币交易-交易所上账中
	WithdrawBillConfirmSuccess WithdrawState = 9  //充币交易-交易所上账成功
	WithdrawBillConfirmFail    WithdrawState = 10 //充币交易-交易所上账失败
)

Jump to

Keyboard shortcuts

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