Documentation ¶
Index ¶
Constants ¶
View Source
const (
ID = "spreadmonitor"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Strategy ¶
type Strategy struct { *bbgo.Notifiability Config []StrategyConfig // 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) UnmarshalJSON ¶
type StrategyConfig ¶
type StrategyConfig struct { SourceExchange string `json:"sourceExchange"` SourceExchangeTakerFee float64 `json:"sourceExchangeTakerFee,omitempty"` SourceExchangeSide string `json:"sourceExchangeSide"` SourceExchangeMarket string `json:"sourceExchangeMarket"` TargetExchange string `json:"targetExchange"` TargetExchangeTakerFee float64 `json:"targetExchangeTakerFee,omitempty"` TargetExchangeSide string `json:"targetExchangeSide"` TargetExchangeMarket string `json:"targetExchangeMarket"` UpperLimitMessage string `json:"upperLimitMessage,omitempty"` SpreadUpperLimitBps int64 `json:"spreadUpperLimitBps,omitempty"` AboveLimitDuration time.Duration LowerLimitMessage string `json:"lowerLimitMessage,omitempty"` SpreadLowerLimitBps int64 `json:"spreadLowerLimitBps,omitempty"` BelowLimitDuration time.Duration SlackChannelName string `json:"slackChannelName"` QuietDuration time.Duration }
func (*StrategyConfig) UnmarshalJSON ¶
func (c *StrategyConfig) UnmarshalJSON(data []byte) error
Click to show internal directories.
Click to hide internal directories.