Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type PubSub ¶
type PubSub[Message any] struct { // contains filtered or unexported fields }
PubSub is a broadcaster that block when publishing without any subscribers
func (*PubSub[Message]) Publish ¶
Publish a message to a topic is blocking, if the receiver does not read the message in time, it will return an error
func (*PubSub[Message]) Subscribe ¶
func (b *PubSub[Message]) Subscribe(filter channel.MessageFilter[Message]) (<-chan Message, error)
func (*PubSub[Message]) Unsubscribe ¶
Click to show internal directories.
Click to hide internal directories.