registry

package
v0.7.0 Latest Latest
Warning

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

Go to latest
Published: May 6, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(reg *Registration)

Register registers the given component implementations.

Types

type LocalStubFnInfo

type LocalStubFnInfo struct {
	Impl         any
	Name         string
	Interceptors []interceptor.Interceptor
}

LocalStubFnInfo is the information passed to LocalStubFn.

type Registration

type Registration struct {
	Name        string       // full package-prefixed component name
	Interface   reflect.Type // interface type for the component
	Impl        reflect.Type // implementation type (struct)
	Refs        string
	LocalStubFn func(context.Context, *LocalStubFnInfo) any
}

Registration is the registration information for a component.

func All

func All() []*Registration

Jump to

Keyboard shortcuts

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