Slide 45
Slide 45 text
Favor constructor injection
over field injection
● Field injection requires non final and non private fields
● Forget an @Inject - get NullPointerException on a field
● Constructor injection = immutable and thread safe
objects. Protect from partially constructed state
● For objects, constructed by the system (Activities,
Fragments) - still use field injection