You would need to use some kind of dependency injection tool to provide something similar.
t
tjb
12/27/2017, 9:37 PM
gotcha, just found Kodein which will do what i want!
tjb
12/27/2017, 9:37 PM
thank you! 🙂
k
kristofdho
12/27/2017, 9:38 PM
there is more than just kodein, and from what i've seen around here, not everyone is as big a fan of it so you should probably do a comparison of your own
t
tjb
12/27/2017, 9:43 PM
any recommendations?
k
kristofdho
12/27/2017, 9:49 PM
well there are loads starting with this list https://kotlin.link/?q=dependency%20injection
and others like guice (which is java), dagger (also java), and I like the look of lightsaber
t
tjb
12/27/2017, 11:13 PM
awesome thanks! Kodein is actually doing what i need so ima vet it out some more 🙂