1
0
mirror of https://github.com/eventials/goevents.git synced 2025-04-26 13:48:59 +08:00

11 lines
216 B
Go
Raw Normal View History

2016-12-01 11:40:58 -02:00
package messaging
2016-11-25 18:51:34 -02:00
2016-12-01 10:52:22 -02:00
type EventHandler func(body []byte) bool
2016-11-25 18:51:34 -02:00
2016-12-01 10:52:22 -02:00
type Consumer interface {
Subscribe(action string, handler EventHandler) error
Unsubscribe(action string) error
Listen() error
ListenForever() error
2016-11-25 18:51:34 -02:00
}