events

package
v0.0.2-0...-b55832e Latest Latest
Warning

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

Go to latest
Published: Aug 21, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Event

type Event struct {
	Name string
	Data string
}

type EventListener

type EventListener func(event Event)

type EventManager

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

func NewEventManager

func NewEventManager() *EventManager

func (*EventManager) AddListener

func (em *EventManager) AddListener(eventName string, listener EventListener)

func (*EventManager) Emit

func (em *EventManager) Emit(event Event)

Jump to

Keyboard shortcuts

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