app

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2025 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func WithApp

func WithApp(app IApp) func(*manager)

func WithLogger

func WithLogger(log xlog.XLog) func(*manager)

Types

type IApp

type IApp interface {
	// Start 启动
	Start() error
	// Shutdown 关闭
	Shutdown() error
}

IApp 应用约定

type IManager

type IManager interface {
	// Register 注册应用
	Register(app IApp)
	// Run 启动应用
	Run()
}

func NewManager

func NewManager(opts ...func(*manager)) IManager

NewManager 创建 APP 管理器

Jump to

Keyboard shortcuts

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