minos.common.injections.injectors

Classes

DependencyInjector

Async wrapper of dependency_injector.containers.Container.

class DependencyInjector[source]

Bases: object

Async wrapper of dependency_injector.containers.Container.

__init__(config, injections=None)[source]
Parameters
injections

Get the injections’ dictionary.

Returns

A dict of injections.

async wire_and_setup_injections(*args, **kwargs)[source]

Connect the configuration.

Returns

This method does not return anything.

Return type

None

async unwire_and_destroy_injections()[source]

Disconnect the configuration.

Returns

This method does not return anything.

Return type

None

wire_injections(modules=None, *args, **kwargs)[source]

Connect the configuration.

Returns

This method does not return anything.

Return type

None

unwire_injections()[source]

Disconnect the configuration.

Returns

This method does not return anything.

Return type

None

async setup_injections()[source]

Set Up the injections.

Returns

This method does not return anything.

Return type

None

async destroy_injections()[source]

Destroy the injections

Returns

This method does not return anything.

Return type

None

container

Get the dependencies’ container.

Returns

A Container instance.