svenjacobs
10/01/2015, 4:32 PMlateinit var
doesn't need to be initialized when declared and thus non-null types are permitted (actually null-types are prohibited for lateinit
). So @Inject lateinit var someDep: SomeDep
is possible. I was afraid that I now have to write @Inject lateinit var someDep: SomeDep? = null
and use the !!
operator for all injected dependencies. But lateinit var
is not so bad...