Se ha denunciado esta presentación.
Utilizamos tu perfil de LinkedIn y tus datos de actividad para personalizar los anuncios y mostrarte publicidad más relevante. Puedes cambiar tus preferencias de publicidad en cualquier momento.

Forgetting android v2

955 visualizaciones

Publicado el

Architecture is About Intent, not Frameworks. So in this talk we are gonna talk about how you can prepare your android application to use the android framework as a tool instead of cramming your app into their limited constraints.

We are gonna focus on SOLID principles, and concepts like testability, independency of UI, decoupled code, etc, will take a fundamental part of this session.

Publicado en: Tecnología
  • Sé el primero en comentar

Forgetting android v2

  1. 1. Forgetting Android v.2 Jorge Juan Barroso Carmona @flipper83 +JorgeJBarroso Android expert
  2. 2. Basho. Poet Karumi is the beauty of ordinary things spoken of in a simple way.
  3. 3. Any fool can write code that a computer can understand. Good programmers write code that humans can understand. Martin Fowler
  4. 4. 1 Solid
  5. 5. Single responsibility principle Open/closed principle Liskov substitution principle Interface segregation principle Dependency inversion principle
  6. 6. Clean Architecture2
  7. 7. A good architecture allows you to defer framework decisions. A good architecture allows frameworks to act as plugins to the app. Robert Martin “The database is a detail, a hardware detail. We would not use one at all if all our data could fit in memory for ever”
  8. 8. UI External Interfaces Db Push Network Storage Interfaces Interfaces Business Model Interactors Interactors
  9. 9. UI Layer UI Layer UI Data Model Data Mapper Interactor Bussines Data Model Data Storage Test Storage Data Mapper Data Mapper Storage Data Model Test Data Model
  10. 10. FeedViewModel FeedBoundary FeedListFragment FeedProvider GetFeed GetFeedImp List<Hipster> User DataSource Net UserDataSourceLikeDataSource Like DataSource Parse API UserApi API Retrofit api Parse api UI Layer Domain Layer use Cases or Interactors Data sources
  11. 11. FeedViewModel FeedListFragment FeedPresenter GetFeed Hipsters User Repository Like Repository UserDatasource UserApi LikeDS Retrofit api DbView Syncronous LikeApi Retrofit api Parse UserDBParse Parse UI Layer / MVP Domain Layer Use cases Data sources Hipsters Read only
  12. 12. Conclusion3
  13. 13. Good Layer Responsabilites
  14. 14. Easy to test and mock
  15. 15. Easy to add or modify code
  16. 16. Easy to hide implementations
  17. 17. Easy to find smells
  18. 18. Async code
  19. 19. Duplicate data model
  20. 20. Change your mind
  21. 21. Not silver bullets
  22. 22. Find meI am very social! @flipper83 +JorgeJBarroso Questions?