dependencies
dependencies copied to clipboard
Shield object should support builtin types.
This will be probably an easier way to solve #432
class Container(Injector):
calculations = shield(list, this.calc1, this.calc2, this.calc3)
calc1 = Calc1
calc2 = Calc2
calc3 = Calc3
Container.calculations # build list of instantiated dependencies
class Container(Injector):
calculations = shield(dict, x=this.calc1, y=this.calc2, z=this.calc3)
calc1 = Calc1
calc2 = Calc2
calc3 = Calc3
Container.calculations # build dict of instantiated dependencies with "x", "y" & "z" keys.