Versions in this module Expand all Collapse all v1 v1.0.0 Jan 16, 2024 Changes in this version + var ErrMuxClosed = errors.New("event: mux closed") + type Feed struct + func (f *Feed) Send(value interface{}) (nsent int) + func (f *Feed) Subscribe(channel interface{}) Subscription + type FeedOf struct + func (f *FeedOf[T]) Send(value T) (nsent int) + func (f *FeedOf[T]) Subscribe(channel chan<- T) Subscription + type ResubscribeErrFunc func(context.Context, error) (Subscription, error) + type ResubscribeFunc func(context.Context) (Subscription, error) + type Subscription interface + Err func() <-chan error + Unsubscribe func() + func JoinSubscriptions(subs ...Subscription) Subscription + func NewSubscription(producer func(<-chan struct{}) error) Subscription + func Resubscribe(backoffMax time.Duration, fn ResubscribeFunc) Subscription + func ResubscribeErr(backoffMax time.Duration, fn ResubscribeErrFunc) Subscription + type SubscriptionScope struct + func (sc *SubscriptionScope) Close() + func (sc *SubscriptionScope) Count() int + func (sc *SubscriptionScope) Track(s Subscription) Subscription + type TypeMux struct + func (mux *TypeMux) Post(ev interface{}) error + func (mux *TypeMux) Stop() + func (mux *TypeMux) Subscribe(types ...interface{}) *TypeMuxSubscription + type TypeMuxEvent struct + Data interface{} + Time time.Time + type TypeMuxSubscription struct + func (s *TypeMuxSubscription) Chan() <-chan *TypeMuxEvent + func (s *TypeMuxSubscription) Closed() bool + func (s *TypeMuxSubscription) Unsubscribe()