emitter

package
v0.4.3 Latest Latest
Warning

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

Go to latest
Published: May 22, 2022 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 Emitter

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

func New

func New() *Emitter

func (*Emitter) Emit

func (e *Emitter) Emit(name string, args ...interface{})

func (*Emitter) Off

func (e *Emitter) Off(name string, callback func(Event))

func (*Emitter) OffAll

func (e *Emitter) OffAll(name string)

func (*Emitter) On

func (e *Emitter) On(name string, callback func(Event))

type Event

type Event struct {
	Name string
	Args []interface{}
}

Jump to

Keyboard shortcuts

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