Hierarchy

  • Injector

Implements

Constructors

Properties

C: Constructor<object>

which object owns this injector.

Maybe an object A has the injector refer to this, but A do not own it.

parent: IInjector

If you use $new method to create a object A which is provider, A

providers: Map<Symbol, Provider> = ...
values: Map<Symbol, any> = ...
writeProp: ((o: object, prop: string, value: any) => void)

Type declaration

    • (o: object, prop: string, value: any): void
    • Parameters

      • o: object
      • prop: string
      • value: any

      Returns void

Methods

  • Based on this injector, create an object which may depend providers from this injector. If C is a provider, we create a sub injector, whose parent is the injector.

    Type Parameters

    Parameters

    • c: C
    • Rest ...args: ConstructorParameters<C>

    Returns InstanceType<C>

  • load or reload providers, keep in mind! we don't re-bind the dependencies that have already bound.

    Returns void

Generated using TypeDoc