eventbus

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package eventbus package eventbus

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bus

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

Bus Bus.

func Get

func Get(route ...string) *Bus

Get if route is empty, return singleton.

func (*Bus) PublishTopicEvent

func (c *Bus) PublishTopicEvent(topic string, arg ...interface{})

func (*Bus) Subscribe

func (c *Bus) Subscribe(topic string, fn ...interface{})

Subscribe -.

func (*Bus) SubscribeAsync

func (c *Bus) SubscribeAsync(topic string, transactional bool, fn ...interface{})

SubscribeAsync Transactional determines whether subsequent callbacks for a topic are run serially (true) or concurrently (false).

func (*Bus) UnSubscribe

func (c *Bus) UnSubscribe(topic string, fn ...interface{})

Jump to

Keyboard shortcuts

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