Android Multimodule Architecture Concepts is a project to showcase different architectural approaches to developing multi-modular Android apps.
The multi-module architecture proposed consists of 3 different layers:
- Presentation layer: contains all the Android UI framework components (i.e. Activities, Fragments, ViewModels...) and the related resources (i.e. images, strings...).
- Domain layer: contains the platform-independent business logic and models.
- Data layer: contains the repositories, the data sources api implementations and the corresponding api-specific models.
These layers are implemented using 3 separate modules to increase decoupling and separation of concerns. The dependencies between the modules are set in order to make the data layer completely invisible to the presentation layer and vice versa.
This project hosts each concept of this architecture in a separate branch (the main branch only contains an empty template for all the concepts).
The proposed concepts are:
- layered-architecture-concept: the dependency between the modules is presentation -> domain -> data. The 3 modules are Android modules.
- clean-architecture-concept: the dependency between the modules is presentation -> domain <- data. The presentation and data modules are Android modules whereas the domain module is a pure Kotlin library being the innermost platform-independent module.