hook

package
v2.2.3+incompatible Latest Latest
Warning

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

Go to latest
Published: Jul 3, 2020 License: AGPL-3.0 Imports: 1 Imported by: 4

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Hook

type Hook func() error

type Hooks

type Hooks map[string][]Hook

func New

func New() Hooks

func (Hooks) Fire

func (h Hooks) Fire(ev string) error

func (Hooks) Names

func (h Hooks) Names() []string

func (Hooks) Off

func (h Hooks) Off(ev string)

func (Hooks) On

func (h Hooks) On(ev string, fn Hook)

func (Hooks) Size

func (h Hooks) Size(ev string) int

Jump to

Keyboard shortcuts

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