pubsub

package
v0.8.1 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2019 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Publish

func Publish(channel string, data Message)

Publish publishes a message to a channel.

func Subscribe

func Subscribe(channel string) chan Message

Subscribe subscribes to the channel and returns listener for it.

func Unsubscribe added in v0.2.0

func Unsubscribe(channel string, listener chan Message)

Unsubscribe unsubscribes a listener from listening channel.

Types

type Message

type Message interface{}

Message sends subscribe/publish messages.

Jump to

Keyboard shortcuts

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