Metadata-Version: 2.1
Name: ghoshell-container
Version: 0.3.0.dev3
Summary: the ioc container useful for Interface oriented programming
Author-Email: thirdgerb <thirdgerb@gmail.com>
License: MIT
Project-URL: Homepage, https://github.com/GhostInShells/ghoshell-container
Project-URL: Repository, https://github.com/GhostInShells/ghoshell-container
Requires-Python: >=3.10
Requires-Dist: typing-extensions>=4.12.0
Description-Content-Type: text/markdown

# Ghoshell Container

IoC container for [GhostInShells](https://github.com/GhostInShells).

## IoC Container

`GhostInShells` follows the concept of `interface-oriented programming` to build the project.
Most modules are divided into `interface` and `implementation`.
Register and get implementations by IoC Container.

About IoC: [Inverse of Control](https://en.wikipedia.org/wiki/Inversion_of_control)

## Installation

`pip install ghoshell-container`

## Features

* `set` and `get`, and type check by `fetch`, `force_fetch`
* `alias`: set alias for contract
* `bind` with factory function, subclass, instance e.t.c
* dict interface
* factory class `Provider` registrar
* `boostrap` and `shutdown`
* container bloodline inheritance
* `make`: recursively dependencies injection for class
* `call`: recursively dependencies injection for function
* `get_container` and `set_container` by contextvars
* `depends`: function decorator
* `Inject` : class property injection
* `DeclaredContainer`: auto bindings by property

see them in [examples](tests/examples)