bbgo_origin/pkg/indicator/ca_callbacks.go

16 lines
299 B
Go
Raw Permalink Normal View History

// Code generated by "callbackgen -type CA"; DO NOT EDIT.
package indicator
import ()
func (inc *CA) OnUpdate(cb func(value float64)) {
2023-06-01 06:27:03 +00:00
inc.updateCallbacks = append(inc.updateCallbacks, cb)
}
func (inc *CA) EmitUpdate(value float64) {
2023-06-01 06:27:03 +00:00
for _, cb := range inc.updateCallbacks {
cb(value)
}
}