WatchGithub
Android MVP sample App using Dagger, Rx Java and Github API
Install / Use
/learn @nicholas-fwang/WatchGithubREADME
WatchGithub
An android MVP structure APP with RxJava, Dagger2 and GitHub v3 API.
References
https://github.com/googlesamples/android-architecture
<pre> - References to branch to todo-mvp, dev-todo-mvp-rxjava and todo-mvp-dagger - Concept of data flow through cache, local and remote. </pre> <br /> https://github.com/frogermcs/GithubClient <pre> - Use GitHub API with retrofit. - Concept of dagger @Subcomponent. </pre>Features
- The sample of Android MVP architecture using Dagger2 and RxJava.
- The GitHub API requests are restricted to 60 per a hour.
- Use 2 POJO model(User, Repository) classes with each 2 storages(local-remote & cache-remote).
Demo Video
Dependencies
Android Support Packages <br /> <a href="https://github.com/google/dagger">Dagger2</a> <br /> <a href="https://github.com/ReactiveX/RxJava">RxJava</a> <br /> <a href="https://github.com/ReactiveX/RxAndroid">RxAndroid</a> <br /> <a href="https://github.com/JakeWharton/RxBinding">RxBinding</a> <br /> <a href="https://github.com/JakeWharton/butterknife">butterknife</a> <br />
<a href="https://github.com/square/picasso">picasso</a> <br /> <a href="https://github.com/square/retrofit">retrofit</a> <br /> <a href="https://github.com/square/sqlbrite">sqlbrite</a> <br />
<a href="https://github.com/mockito/mockito">mockito</a> <br /> <a href="https://developer.android.com/training/testing/ui-testing/espresso-testing.html">espresso</a> <br />
adapter-rxjava, converter-gson, timber and guava <br />
Architecture
-
WatchGithub MVP Architecture <br />

-
Dagger Object Graph

Activity


Test
<pre> [Android Test] VIEW : Used espresso and Fake object for state verification. </pre> <pre> [Test] Presenter and Model : Used JUnit and Stub object implemented with Mockito for state verfication. Presenter and Model : Used Mockito and Mock object implemented with Mockito for behaviro verification. </pre>Articles
- <a href="https://fisache.github.io/Introduction-WatchGithub/">Introduction to
WatchGithub</a> <br /> - Construct MVP pattern with
Dagger2<br /> - Use
sqlbriteusingRxJava<br /> - Use
retrofitwithRxJava<br /> - Implement <a href="https://en.wikipedia.org/wiki/Cache_algorithms#LRU">LRU Cache</a> with
LinkedHashMapandRxJava<br /> - Implement filter with
RxJavaandsqlbrite<br /> - Implement filter with
RxJavaand Cache <br /> - Implement search with
RxBindingandsqlbrite<br /> - Implement scroll down when viewed data are end using
retrofitandrecyclerView onScroll<br /> - Connect to local data(
sqlbrite) with remote data(retrofit) usingRxJava<br /> - Connect to cache with remote data(
retrofit) usingRxJava<br /> - TODO : androidTest and Test with espresso, junit and mockito

