xalign

package
v1.55.4 Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2023 License: AGPL-3.0 Imports: 11 Imported by: 1

Documentation

Index

Constants

View Source
const ID = "xalign"

Variables

This section is empty.

Functions

This section is empty.

Types

type QuoteCurrencyPreference

type QuoteCurrencyPreference struct {
	Buy  []string `json:"buy"`
	Sell []string `json:"sell"`
}

type Strategy

type Strategy struct {
	*bbgo.Environment
	Interval                 types.Interval              `json:"interval"`
	PreferredSessions        []string                    `json:"sessions"`
	PreferredQuoteCurrencies *QuoteCurrencyPreference    `json:"quoteCurrencies"`
	ExpectedBalances         map[string]fixedpoint.Value `json:"expectedBalances"`
	UseTakerOrder            bool                        `json:"useTakerOrder"`
	DryRun                   bool                        `json:"dryRun"`
	BalanceToleranceRange    fixedpoint.Value            `json:"balanceToleranceRange"`
	Duration                 types.Duration              `json:"for"`
	MaxAmounts               map[string]fixedpoint.Value `json:"maxAmounts"`
	// contains filtered or unexported fields
}

func (*Strategy) CrossRun

func (s *Strategy) CrossRun(ctx context.Context, _ bbgo.OrderExecutionRouter, sessions map[string]*bbgo.ExchangeSession) error

func (*Strategy) CrossSubscribe

func (s *Strategy) CrossSubscribe(sessions map[string]*bbgo.ExchangeSession)

func (*Strategy) Defaults added in v1.49.0

func (s *Strategy) Defaults() error

func (*Strategy) ID

func (s *Strategy) ID() string

func (*Strategy) InstanceID

func (s *Strategy) InstanceID() string

func (*Strategy) Subscribe

func (s *Strategy) Subscribe(session *bbgo.ExchangeSession)

func (*Strategy) Validate

func (s *Strategy) Validate() error

type TimeBalance added in v1.49.0

type TimeBalance struct {
	types.Balance

	Time time.Time
}

Jump to

Keyboard shortcuts

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