pubsub

package
v4.45.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 12, 2022 License: MIT Imports: 6 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func NewService

func NewService() *Service

func (*Service) Cleanup

func (s *Service) Cleanup() error

Cleanup cleans up internal caches of subscribers. Visible for testing only.

func (*Service) Publish

func (s *Service) Publish(name string, message interface{})

func (*Service) Subscribe

func (s *Service) Subscribe(name string) *Subscriber

type Subscriber

type Subscriber struct {
	// contains filtered or unexported fields
}

func (*Subscriber) Close

func (s *Subscriber) Close() error

func (*Subscriber) IsClosed

func (s *Subscriber) IsClosed() bool

func (*Subscriber) Wait

func (s *Subscriber) Wait() <-chan interface{}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL