An open API service providing package, version and dependency metadata of many open source software ecosystems and registries.

Top 8.2% on proxy.golang.org

proxy.golang.org : github.com/reiver/go-container

Package container provides 'dependency injection' functionality. A large part of this is done through the 'dependency injection container', which is reified through the 'container.Container' interface, and created by calling the 'container.New()' func. As in: You do 3 things with a 'dependency injection container'. (Although it is possible that in practice you might only do 2 of these 3 things. But if you end up doing all 3 of these things, that's OK too.) #1: You register things with the container, giving the thing you registed a (string) name when you register it. For example: Also, for example: #2: You manually get things out of the container. (Doing this is a bit involved, but #3 provides a better alternative to this method.) For example: Also, for example: #3: The container can inject dependencies into something. For example:

Registry - Source - Documentation - JSON
purl: pkg:golang/github.com/reiver/go-container
License: MIT
Latest release: almost 9 years ago
First release: almost 9 years ago
Namespace: github.com/reiver
Stars: 1 on GitHub
Forks: 0 on GitHub
See more repository details: repos.ecosyste.ms
Last synced: 14 days ago

    Loading...
    Readme
    Loading...