Remove redundant addition

This commit is contained in:
Mike Bierlee 2016-08-23 21:28:54 +02:00
parent de26a49b8d
commit 1a51e2081e

View file

@ -81,13 +81,8 @@ class ExampleClassB {
dependencies.register!ExampleClassA;
auto exampleInstance = new ExampleClassB();
// Manual autowiring
dependencies.autowire(exampleInstance);
// Let the container autowire on resolve
dependencies.register!ExampleClassB;
auto exampleInstance2 = dependencies.resolve!ExampleClassB;
assert(exampleInstance.dependency !is null);
```
It is possible to autowire public as well as protected and private members.