Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Manager ¶
type Manager interface { Subscribe(resourceID string, subscriber Subscriber) Subscription GetSubscription(resourceID string, subscriptionID string) Subscription PublishUpdate(message Message) Publish(resourceID string, message any) }
func NewManager ¶
func NewManager(opts ...optFn) Manager
type Message ¶
func DecodeMessage ¶ added in v0.15.4
func (Message) DecodeContent ¶ added in v0.15.4
func (Message) EncodeContent ¶ added in v0.15.4
type Subscriber ¶
func NewSubscriberFunction ¶
func NewSubscriberFunction(function func(Message) error) Subscriber
type SubscriberFunction ¶
type SubscriberFunction struct {
// contains filtered or unexported fields
}
func (*SubscriberFunction) ID ¶
func (sf *SubscriberFunction) ID() string
func (*SubscriberFunction) Notify ¶
func (sf *SubscriberFunction) Notify(message Message) error
type Subscription ¶
type Subscription interface {
Unsubscribe() error
}
Click to show internal directories.
Click to hide internal directories.