Versions in this module Expand all Collapse all v0 v0.9.3 Jun 4, 2026 v0.9.2 Jun 4, 2026 v0.9.1 Feb 7, 2026 Changes in this version + type Container struct + func NewContainer(opts ...ContainerOption) (*Container, error) + func (c *Container) Graph() Graph + func (c *Container) GraphDOT() string + func (c *Container) GraphDOTModules() map[string]string + func (c *Container) GraphModules() map[string]Graph + func (c *Container) Invoke(consumer any) error + func (c *Container) Provide(deps Dependencies) error + func (c *Container) Runnables() ([]Runnable, error) + func (c *Container) Validate() error + type ContainerOption func(c *containerConfig) + func WithDefaultLifecycle() ContainerOption + func WithDependencies(d ...Dependencies) ContainerOption + func WithMatchings(matchings ...any) ContainerOption + func WithModules(modules ...Module) ContainerOption + type Dependencies struct + func CollectDependencies(deps ...Dependency) Dependencies + func NewSingleDependency(constructor any, opts ...DependencyOption) Dependencies + func (d Dependencies) List() []Dependency + type Dependency struct + func Decorate(constructor any, opts ...DependencyOption) Dependency + func NewDependency(constructor any, opts ...DependencyOption) Dependency + func Replace(constructor any, opts ...DependencyOption) Dependency + func (d *Dependency) AddMatchingInterface(as ...any) error + func (d *Dependency) Error() error + func (d *Dependency) ExposedTypes() []reflect.Type + func (d *Dependency) IsRunnable() bool + func (d *Dependency) Type() reflect.Type + type DependencyOption func(*Dependency) + func Private() DependencyOption + func WithGroup(group string) DependencyOption + func WithKey(key string) DependencyOption + func WithMatch(a any) DependencyOption + func WithName(name string) DependencyOption + type Graph struct + Edges []ProviderEdge + Providers []ProviderNode + func BuildGraph(deps Dependencies) Graph + func (g Graph) DOT() string + func (g Graph) ProviderIDs() []string + type GraphToken struct + Group string + Name string + Optional bool + Type string + type Hook struct + OnStart func(context.Context) error + OnStop func(context.Context) error + type Lifecycle struct + func NewLifecycle() *Lifecycle + func (l *Lifecycle) Append(h Hook) + func (l *Lifecycle) Start(ctx context.Context) error + func (l *Lifecycle) Stop(ctx context.Context) error + type Matching struct + func NewMatching(origin any, interfaces ...any) Matching + func (m *Matching) Error() error + func (m *Matching) Origin() reflect.Type + type Module struct + Dependencies Dependencies + Name string + func NewModule(name string, dependencies Dependencies) Module + type Optional struct + Optional *T + func (o *Optional[T]) Get() (T, bool) + type OverrideInfo struct + Key string + Next ProviderInfo + Previous ProviderInfo + func DetectOverrides(deps Dependencies) []OverrideInfo + type ProviderEdge struct + From string + Group string + Missing bool + Name string + Optional bool + To string + Type string + type ProviderInfo struct + Constructor string + File string + Group string + Index int + Line int + Name string + Type string + type ProviderNode struct + Constructor string + File string + Group string + ID string + Key string + Kind string + Line int + Name string + Provides []GraphToken + Requires []GraphToken + Type string + type Runnable struct + OnStart func(context.Context) error + OnStop func(context.Context) error