container

package
v1.3.6 Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrEntityExist = errors.New("entity existed")
)
View Source
var (
	ErrorDependNotCompleted = errors.New("依赖尚未完成")
)

Functions

This section is empty.

Types

type Container

type Container interface {
	Provider
	Populater
	Invoker
	Get(plugin plugin.Plugin, name ...string) (interface{}, error)
}

func New

func New() Container

type Invoker added in v1.0.0

type Invoker interface {
	Invoke(fn interface{}) ([]reflect.Value, error)
}

type Option

type Option func(*entity)

func WithName added in v1.0.0

func WithName(name string) Option

type Populater added in v1.0.0

type Populater interface {
	Populate() error
}

type Provider added in v1.0.0

type Provider interface {
	ProvideFunc(val interface{}, opts ...Option) error
	Provide(val plugin.Plugin, opts ...Option) error
}

Jump to

Keyboard shortcuts

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