hevent

package
v1.0.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HEvent

type HEvent struct {
	Data  interface{}
	Topic string
}

type HEventBus

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

func HEventSrv

func HEventSrv() *HEventBus

func (*HEventBus) Push

func (h *HEventBus) Push(topic string, data interface{})

func (*HEventBus) Sub

func (h *HEventBus) Sub(topic string, ch HEventData)

type HEventData

type HEventData chan HEvent

type HEventDataArray

type HEventDataArray []HEventData //一个topic 可以有多个消费者

type HEventRepo

type HEventRepo interface {
	Sub(topic string, ch HEventData)
	Push(topic string, data interface{})
}

Jump to

Keyboard shortcuts

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