Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var EntryNotFound = errors.New("entry not found")
Functions ¶
This section is empty.
Types ¶
type Constructable ¶
type Constructable interface {
Constructor()
}
Constructable is a service that has special method that initializes it
type Container ¶
type Container interface { // Set defines new entry in container Set(any, ...string) // Build sets new entry in container without adding it to container Build(any) any // AppendTypes adds referenced types to an existing entry. Returns error if AppendTypes(any, ...any) error // Has checks whether the service of passed type exists Has(any) bool // Get returns service from container Get(any) any // GetByTag returns tagged services from container GetByTag(string) []any // All return all services All() []any }
Container handles services and fills them
type Destructible ¶
type Destructible interface {
Destructor()
}
Destructible is a service that has special method that destructs it
type Launchable ¶
type PrecompiledContainer ¶
type PrecompiledContainer interface { Compile() Destroy() Container }
PrecompiledContainer is an extension of Container that can fill services before usage
func NewContainer ¶
func NewContainer() PrecompiledContainer
type Runner ¶ added in v1.11.0
type Runner interface { PrecompiledContainer Name() string Run(context.Context) }
func NewApplication ¶ added in v1.10.0
Source Files ¶
Click to show internal directories.
Click to hide internal directories.