swap

package
v1.2.54 Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Swap

type Swap struct {
	// contains filtered or unexported fields
}

func (*Swap) SetOtherAccountAmount

func (this *Swap) SetOtherAccountAmount(f float64)

func (*Swap) SetPlatformAccountAmount

func (this *Swap) SetPlatformAccountAmount(f float64)

func (*Swap) SetSwapRate

func (this *Swap) SetSwapRate(f float64)

func (*Swap) ToOtherCurrency

func (this *Swap) ToOtherCurrency() float64

func (*Swap) ToPlatformCurrency

func (this *Swap) ToPlatformCurrency() float64

type SwapInterface

type SwapInterface interface {
	ToPlatformCurrency() float64
	ToOtherCurrency() float64
	SetSwapRate(float64)
	SetPlatformAccountAmount(float64) // 筹码
	SetOtherAccountAmount(float64)    // 其他货币
}

func NewOther

func NewOther(rate, amount float64) SwapInterface

func NewPlatform

func NewPlatform(rate, amount float64) SwapInterface

Jump to

Keyboard shortcuts

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