notifier

package
v0.33.1 Latest Latest
Warning

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

Go to latest
Published: Apr 19, 2024 License: MPL-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ModuleFromContext

func ModuleFromContext(ctx context.Context) (*state.Module, error)

func ModuleIsOpen

func ModuleIsOpen(ctx context.Context) (bool, error)

Types

type Hook

type Hook func(ctx context.Context, changes state.ModuleChanges) error

type ModuleStore

type ModuleStore interface {
	AwaitNextChangeBatch(ctx context.Context) (state.ModuleChangeBatch, error)
	ModuleByPath(path string) (*state.Module, error)
}

type Notifier

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

func NewNotifier

func NewNotifier(modStore ModuleStore, hooks []Hook) *Notifier

func (*Notifier) SetLogger

func (n *Notifier) SetLogger(logger *log.Logger)

func (*Notifier) Start

func (n *Notifier) Start(ctx context.Context)

Jump to

Keyboard shortcuts

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