Advertisement
Guest User

Untitled

a guest
Dec 18th, 2017
81
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.63 KB | None | 0 0
  1. open class App : Application() {
  2.  
  3. override fun onCreate() {
  4. super.onCreate()
  5.  
  6. component = buildComponent()
  7. }
  8.  
  9. private fun buildComponent(): ApplicationComponent {
  10. return DaggerApplicationComponent.builder()
  11. .applicationModule(ApplicationModule(this))
  12. .dataSourceModule(DataSourceModule())
  13. .repositoryModule(RepositoryModule())
  14. .netModule(NetModule())
  15. .dbModule(DbModule())
  16. .build()
  17. }
  18.  
  19. companion object {
  20.  
  21. @JvmStatic
  22. lateinit var component: ApplicationComponent
  23. }
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement