loadek

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Feb 12, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	Config *Config
	Logger *slog.Logger
}

func NewApp

func NewApp(options ...AppOption) *App

func (*App) LoadSystem

func (a *App) LoadSystem(ctx context.Context, wg *sync.WaitGroup)

type AppOption

type AppOption func(*App)

func WithConfig

func WithConfig(config *Config) AppOption

func WithLogger

func WithLogger(logger *slog.Logger) AppOption

type Config

type Config struct {
	CpuLoadMi int
	MemLoadMb int
}

func NewConfig

func NewConfig(options ...ConfigOption) (*Config, error)

type ConfigOption

type ConfigOption func(*Config) error

func WithCpuLoadMi

func WithCpuLoadMi(cpuLoadMi int) ConfigOption

func WithMemLoadMb

func WithMemLoadMb(memLoadMb int) ConfigOption

Jump to

Keyboard shortcuts

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