bbgo_origin/pkg/exchange/bybit/stream_callbacks.go

16 lines
304 B
Go
Raw Normal View History

// Code generated by "callbackgen -type Stream"; DO NOT EDIT.
package bybit
import ()
func (s *Stream) OnBookEvent(cb func(e BookEvent)) {
s.bookEventCallbacks = append(s.bookEventCallbacks, cb)
}
func (s *Stream) EmitBookEvent(e BookEvent) {
for _, cb := range s.bookEventCallbacks {
cb(e)
}
}