這是一篇學習Clean架構的筆記,MVP本身是屬于展現層的邏輯,對于小型項目可能方便很多,但是對于大型項目來說MVP并不足以使代碼優化、依然會代碼冗余。所以分層和模塊化才是方向,clean架構就指出了這種架構的設計方式,所有本篇文章就做些clean架構的學習筆記。
原文: architecting-android-the-clean-way the-clean-architecture
quality software could be : not only about satisfying requirements, also should be robust, maintainable, testable, and flexible enough to adapt to growth and change.
the detail is :
Independent of FrameWorkTestableIndependent of UIIndependent of DatabaseIndependent of any external agencyEach layer uses its own data model so this independence can be reached.(the project uses datamapper to acheive the indepenices. 具體實施中還待商榷,畢竟同樣的model類型再次創建費勁。在確??蓽y試情況下應該重復創建。 ).
擴展閱讀: 說說Android的MVP模式
新聞熱點
疑難解答