2020-07-13 05:25:48 +00:00
|
|
|
package bbgo
|
|
|
|
|
2020-09-19 03:09:20 +00:00
|
|
|
import (
|
2020-10-16 02:21:37 +00:00
|
|
|
"github.com/c9s/bbgo/pkg/accounting/pnl"
|
2020-10-11 08:46:15 +00:00
|
|
|
"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)
|
2020-10-16 02:21:37 +00:00
|
|
|
NotifyPnL(report *pnl.AverageCostPnlReport)
|
2020-07-16 07:36:02 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
type NullNotifier struct{}
|
|
|
|
|
|
|
|
func (n *NullNotifier) Notify(format string, args ...interface{}) {
|
|
|
|
}
|