在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称:nicholas-fwang/WatchGithub开源软件地址:https://github.com/nicholas-fwang/WatchGithub开源编程语言:Java 100.0%开源软件介绍:WatchGithubAn android MVP structure APP with RxJava, Dagger2 and GitHub v3 API. Referenceshttps://github.com/googlesamples/android-architecture - References to branch to todo-mvp, dev-todo-mvp-rxjava and todo-mvp-dagger - Concept of data flow through cache, local and remote. https://github.com/frogermcs/GithubClient - Use GitHub API with retrofit. - Concept of dagger @Subcomponent. Features
Demo VideoDependenciesAndroid Support Packages adapter-rxjava, converter-gson, timber and guava ArchitectureActivity[Local & Remote Storage] Create : - User can add new Github User clicking floating button. if user is not valid, snackbar is shown with warning. Read : - When app launched, all of users saved in local storage(SQLite) are updated with remote storage(GitHub API). - Aleary launched, users data is brought from local storage - Users are filterd into All User, Popular(have followers over 150), and User or Organization. - Also, you can search as typing the user login id. Update/Delete : - You can write user description(To find out who). It will place at the hint 'Go to setting..'. The way writing is to click the set icon (looks like gear) then, detail activity is launched, you can update user's description also delete user in local storage. [Cache & Remote Storage] Create : - User's repositories is cached by replacement policy of LRU. - When The capacity of cache is sufficient, cache will save repositories data with user login id and requested last page number Read : - When view user's repositories, first of all try to read from cache. - If not placed in cache, request to GitHub server and save to cache. - When You scroll down over viewed repositories, request next repositories to GitHub server and save to cache. - Filtering is similar to User filter (ALL, Popular(starred over 500), ORIGIN or FORK and Recently pushed(before 3days). Update : - Update is performed when requests repositories when the repositories are not placed in cache. Delete : - Cache is implemented with LinkedHashMap of Java, and follows the replacement policy of LRU. So, Least Rencently Used data is removed when save new data to cache in full capacity. Test[Android Test] VIEW : Used espresso and Fake object for state verification. [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. Articles
|
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论