event

package
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2024 License: GPL-3.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 Broadcaster

type Broadcaster interface {
	BroadCast(e interface{})
}

type Engine

type Engine struct {
	Register   chan Listener
	Unregister chan Listener
	// contains filtered or unexported fields
}

func NewEventEngine

func NewEventEngine() *Engine

func (*Engine) BroadCast

func (e *Engine) BroadCast(evt interface{})

func (*Engine) Start

func (e *Engine) Start(ctx context.Context)

Start event engine start function need goroutine

type Event

type Event interface {
}

type EventError

type EventError struct {
	Message string
}

func (EventError) Error

func (e EventError) Error() string

type Listener

type Listener interface {
	Listen(e interface{})
}

Directories

Path Synopsis
Package mock_event is a generated GoMock package.
Package mock_event is a generated GoMock package.

Jump to

Keyboard shortcuts

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