common

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: May 26, 2024 License: GPL-3.0 Imports: 1 Imported by: 3

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidParameter       = errors.New("parameter is invalid")
	ErrInvalidIndex           = errors.New("index is invalid")
	ErrInvalidMnemonic        = errors.New("mnemonic is invalid")
	ErrUnsupportedAddressType = errors.New("address type is unsupported")
	ErrUnsupportedCurrency    = errors.New("currency is unsupported")
	ErrInvalidTransaction     = errors.New("transaction is invalid")
	ErrSendTransactionFailed  = errors.New("send transaction failed")
	ErrTransactionNotFound    = errors.New("transaction is not found")
	ErrUnsupportedChainType   = errors.New("chain type is unsupported")
	ErrUninitializedClient    = errors.New("client is uninitialized")
)

Functions

This section is empty.

Types

type AddressType

type AddressType int8
const (
	AddressType_BTC_LEGACY        AddressType = 1
	AddressType_BTC_NESTED_SEGWIT AddressType = 2
	AddressType_BTC_NATIVE_SEGWIT AddressType = 3
	AddressType_BTC_TAPROOT       AddressType = 4
	AddressType_ETH               AddressType = 5
	AddressType_TRON              AddressType = 6
	AddressType_BSC               AddressType = 7
	AddressType_SOL               AddressType = 8
)

func ParseAddressType

func ParseAddressType(AddressType string) (AddressType, error)

func (AddressType) Name

func (Self AddressType) Name() (string, error)

func (AddressType) Path

func (Self AddressType) Path() (string, error)

type ChainType

type ChainType int8
const (
	ChainType_BTC  ChainType = 1
	ChainType_ETH  ChainType = 2
	ChainType_TRON ChainType = 3
	ChainType_BSC  ChainType = 4
	ChainType_SOL  ChainType = 5
)

func ParseChain

func ParseChain(chain string) (ChainType, error)

func (ChainType) Name

func (Self ChainType) Name() (string, error)

Jump to

Keyboard shortcuts

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