subscriber

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jun 4, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	NAME    = "subscriber"
	VERSION = 1
)

Name and Version of this service.

Variables

This section is empty.

Functions

This section is empty.

Types

type SubscriberService

type SubscriberService struct {
	service.ApplicationContainer
	// contains filtered or unexported fields
}

func NewSubscriberService

func NewSubscriberService(r bc.RemoteAccess) *SubscriberService

func (*SubscriberService) Get

func (subService *SubscriberService) Get(name string) (chan interface{}, error)

func (*SubscriberService) Run

func (subService *SubscriberService) Run(stream inet.Stream)

func (*SubscriberService) Set

func (subService *SubscriberService) Set(name string, value interface{}) error

func (*SubscriberService) Start

func (subService *SubscriberService) Start(ctx context.Context) error

func (*SubscriberService) Stop

func (subService *SubscriberService) Stop() error

func (*SubscriberService) SubscribeToTopics

func (subService *SubscriberService) SubscribeToTopics(topics []string) (chan *pubsub.Message, error)

SubscribeToTopics subscribes to multiple topics and outputs all into a single chan.

func (*SubscriberService) UnsubscribeToTopics added in v0.1.0

func (subService *SubscriberService) UnsubscribeToTopics(topics []string) error

UnsubscribeToTopics will unregister from the remote access and close the subscription channel

type TopicWrapper

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

Jump to

Keyboard shortcuts

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