Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type StreamExecutor ¶
type StreamExecutor struct { Session *bbgo.ExchangeSession Symbol string Side types.SideType TargetQuantity fixedpoint.Value SliceQuantity fixedpoint.Value StopPrice fixedpoint.Value NumOfTicks int UpdateInterval time.Duration DeadlineTime time.Time // contains filtered or unexported fields }
StreamExecutor is a TWAP execution that places orders on the best price by connecting to the real time market data stream.
func (*StreamExecutor) Done ¶
func (e *StreamExecutor) Done() (c <-chan struct{})
func (*StreamExecutor) Shutdown ¶
func (e *StreamExecutor) Shutdown(shutdownCtx context.Context)
Shutdown stops the execution If we call this method, it means the execution is still running, We need to: 1. stop the order updater (by using the execution context) 2. the order updater cancels all open orders and close the user data stream
Click to show internal directories.
Click to hide internal directories.