lifecycle

package
v0.2.10-20 Latest Latest
Warning

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

Go to latest
Published: Apr 5, 2023 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Exporter

type Exporter struct {
	Lifecycle    Lifecycle
	GetLifecycle GetLifecycle
}

func New

func New(handlers []Handler) Exporter

type GetLifecycle added in v0.2.4

type GetLifecycle interface {
	GetAfterStops() []executor
	GetBeforeStops() []executor
	GetAfterStarts() []executor
	GetBeforeStarts() []executor
}

type Handler added in v0.2.4

type Handler func(lc Lifecycle)

type Lifecycle

type Lifecycle interface {
	AfterStop(f func())
	BeforeStop(f func())
	AfterStart(f func())
	BeforeStart(f func())
}

Jump to

Keyboard shortcuts

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