loader

package
v1.0.13 Latest Latest
Warning

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

Go to latest
Published: Mar 11, 2024 License: MIT Imports: 1 Imported by: 4

README

loader

The loader is a module that loads other modules.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BaseLoader added in v1.0.10

type BaseLoader struct {
}

func (*BaseLoader) Init added in v1.0.10

func (loader *BaseLoader) Init(opts ...Option) error

func (*BaseLoader) Initialized added in v1.0.10

func (loader *BaseLoader) Initialized() bool

func (*BaseLoader) Start added in v1.0.10

func (loader *BaseLoader) Start(ctx context.Context) error

func (*BaseLoader) Stop added in v1.0.10

func (loader *BaseLoader) Stop(ctx context.Context) error

func (*BaseLoader) String added in v1.0.10

func (loader *BaseLoader) String() string

func (*BaseLoader) Watch added in v1.0.10

func (loader *BaseLoader) Watch() error

type Loader

type Loader interface {
	// Initialized returns true if loader is initialized
	Initialized() bool
	// Init initializes loader
	Init(opts ...Option) error
	// Start starts loader
	Start(ctx context.Context) error
	// Watch watches for changes
	Watch() error
	// Stop stops loader
	Stop(ctx context.Context) error
	// String returns loader name
	String() string
}

type Option

type Option func(o *Options)

type Options

type Options struct {
	Initialized bool
	// for alternative data
	Context context.Context
}

func NewOptions

func NewOptions(opts ...Option) *Options

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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