Skip to content
/ EMS Public

Sample app showcasing android app development using modern tech stack including: Kotlin, MVI, ReactiveX, Koin, Jetpack Architecture Components, Motion Layout, Mockk & Junit5, Room

Notifications You must be signed in to change notification settings

Pantkowsky/EMS

Repository files navigation

Requirements

The gradle plugin used in this project required Java 11 for it to be compiled. If you currently don't have Java 11 installed on your machine (assuming you're using a linux distro) you can:

sudo apt-get update
sudo apt-get install openjdk-11-jdk

Additionally, make sure you have the latest android gradle plugin installed.

If you are running this app on an emulator, make sure you use the emulator that is api 26 and up, as this is the minimum required sdk version. Otherwise, if you're running this on a physical device, then the version of your OS should at least be 8.0 known as Oreo

To launch this project, clone/download this repository to your machine and open it from Android Studio. When gradle finishes indexing, SHIFT + F10 to launch it.

How to

Add Button - click to create a new employee (ADD operation)

image

Delete Button - click to delete an employee (REMOVE operation)

image

Give Raise Button - click to give an employee a raise (UPDATE operation)

image

GET operation is implemented implicitly and used for displaying all employees on the screen

Modularized project structure

Project is made from standalone android modules, as shown below:

.
-> app 
-> buildSrc
-> domain
-> features
   -> base
   -> roster

where:

  • app module contains the launch options component as well as splash activity
  • buildSrc module contains the project and build configuration logic.
  • domain module contains the database with its DAOs and business logic
  • features subdirectory contains all the standalone feature modules. Currently it contains base which contains all base android components for feature development, as well as roster which is the feature visible on the screen after app launch

Code Style

This project leverages two linting tools:

In favor of convenience, ./linters/ directory contains a stylecheck.sh script, which run both ktlint and detekt and fails early if any issues arise, otherwise completes successfully. To run it, open the terminal in ./linters/ directory and run:

chmod +x stylecheck.sh
./stylecheck.sh

Architecture

Project is built with clean architecture in mind, using mvi pattern (great link, another great link) as the underlying design pattern: The chart below represents the architecture in more detail:

*keep in mind that this project does not contain an Api Client which does appear on the diagram below

image

The data flow from database access until ui rendering is done via below model conversion:

Employee > EmployeeModel > EmployeeData > ViewState

frameworks

About

Sample app showcasing android app development using modern tech stack including: Kotlin, MVI, ReactiveX, Koin, Jetpack Architecture Components, Motion Layout, Mockk & Junit5, Room

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published