Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Get ¶
func Get[T any](dm *DependencyManager) (T, error)
Get retrieves the already-initialized dependency for the specified type.
func Register ¶
func Register[T any](dm *DependencyManager, initializer func(*DependencyManager) (T, error))
Register initializes and registers a dependency for the specified type.
Types ¶
type DependencyManager ¶
type DependencyManager struct {
// contains filtered or unexported fields
}
DependencyManager manages dependencies by initializing them at registration.
func NewDependencyManager ¶
func NewDependencyManager() *DependencyManager
NewDependencyManager creates a new instance of DependencyManager.
Click to show internal directories.
Click to hide internal directories.