2020-07-13 05:25:48 +00:00
|
|
|
package bbgo
|
|
|
|
|
2020-09-19 03:09:20 +00:00
|
|
|
import (
|
2020-10-11 08:46:15 +00:00
|
|
|
"github.com/c9s/bbgo/pkg/accounting"
|
|
|
|
"github.com/c9s/bbgo/pkg/types"
|
2020-09-19 03:09:20 +00:00
|
|
|
)
|
|
|
|
|
2020-07-16 07:36:02 +00:00
|
|
|
type Notifier interface {
|
|
|
|
Notify(format string, args ...interface{})
|
2020-09-19 03:09:20 +00:00
|
|
|
NotifyTrade(trade *types.Trade)
|
|
|
|
NotifyPnL(report *accounting.ProfitAndLossReport)
|
2020-07-16 07:36:02 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
type NullNotifier struct{}
|
|
|
|
|
|
|
|
func (n *NullNotifier) Notify(format string, args ...interface{}) {
|
|
|
|
}
|