common

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2019 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// ETHAddr ethereum address
	ETHAddr = "0xeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeee"
	// ETHSymbol ethereum symbol
	ETHSymbol = "ETH"
)

Variables

This section is empty.

Functions

func FromDestToSrc

func FromDestToSrc(destAmount string, rate string, srcDecimals int, destDecimal int) (*big.Int, error)

func FromSrcToDest

func FromSrcToDest(srcAmount string, rate string, srcDecimals int, destDecimal int) (*big.Int, error)

func GetAmountEnableFirstBit

func GetAmountEnableFirstBit(amount float64, decimals int) *big.Int

func GetOrAmount

func GetOrAmount(amount *big.Int) *big.Int

func StringToWei

func StringToWei(amount string, decimals int) (*big.Int, error)

func ToToken

func ToToken(amount string, decimals int) (*big.Float, error)

func ToWei

func ToWei(amount float64, decimals int) *big.Int

Types

type UserInfo

type UserInfo struct {
	Cap   *big.Int `json:"cap"`
	Kyced bool     `json:"kyced"`
	Rich  bool     `json:"rich"`
}

Jump to

Keyboard shortcuts

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