RxAndroidBootstrap


Source link: https://github.com/richardradics/RxAndroidBootstrap

A project which showcases usage of Dagger 2, Rxjava and retrolambda among other open source libraries.

Features

  • Model-View-Presenter architectural pattern
  • Dagger2
  • RxJava + Retrolambda
  • Connectivity aware retrofit client
  • ErrorHandling
  • Uncaught errorhandling
  • Navigator to get current activity onscreen
  • Design Support Library
  • Loading toast progress
  • Commons library with a lot of util classes and great 3rd party widgets

Overview

This project follows the following principles:

SOLID

  • Single Responsibility Principle
    • A Class should have only one reason to change.
    • A good separation of responsibilities is done only when the full picture of how the application should work is well understanded.
  • Open Close Principle
    • Classes, modules and functions should be open for extension, but closed for modifications.
  • Liskov's Substitution Principle
    • Derived types must be completely substitutable for their base types.
    • We must make sure that new derived classes are extending the base classes without changing their behavior.
  • Interface Segregation Principle
    • Clients should not be forced to depend upon interfaces that they don't use.
    • If the design is already done fat interfaces can be segregated using the Adapter pattern.
  • Dependency Inversion Principle
    • High-level modules should not depend on low-level modules. Both should depend on abstractions. Abstractions should not depend on details. Details should depend on abstractions.

Repository Pattern

Methods for retrieving domain objects should delegate to a specialized Repository object such that alternative storage implementations may be easily interchanged.

ResponseMapper

Api models usually different from the domain models. We have to map the response to domain models.

Interactor

An interactor (or usecase) represents a single use case in the app. It contains the business logit to manipulate model objects (Entities) to carry out a specific task. The work done in an interactor is independent of any type of UI.

Presenter

Presenters are composed with interactors (usecases) that perform the job in a new thread outside the android UI thread, and come back using a callback with the data that will be rendered in the view.

View

The view is going to be abstracted using an interface implemented by android components. The views have different view model.

RxJava

RxJava is an implementation of the Reactive Extensions (Rx) on the JVM, courtesy of Netflix. Rx was first conceived by Erik Meijer on the Microsoft .NET platform, as a way of combining data or event streams with reactive objects and functional composition. In Rx, events are modeled as observable streams to which observers are subscribed. These streams, or observables for short, can be filtered, transformed, and composed in various ways before their results are emitted to an observer. Every observer is defined within three messages: onNext, onCompleted, and onError. Concurrency is a variable in this equation, and abstracted away in the form of schedulers. Generally, every observable stream exposes an interface that is modeled after concurrent execution flows (i.e. you don’t call it, you subscribe to it), but by default is executed synchronously.

Useful links

Resources

Implementation of a Material Spinner for Android wich supports TextInputLayout functionalities
A simple Tooltip Library
This library allows you to show bottom navigation quickly, simply and animated.
Android library to use the Font Awesome icons in android apps
Dynamic GridView using Kotlin Language
A small Android library allowing you to have a smooth and customizable circular ProgressBar.

Topics


2D Engines   3D Engines   9-Patch   Action Bars   Activities   ADB   Advertisements   Analytics   Animations   ANR   AOP   API   APK   APT   Architecture   Audio   Autocomplete   Background Processing   Backward Compatibility   Badges   Bar Codes   Benchmarking   Bitmaps   Bluetooth   Blur Effects   Bread Crumbs   BRMS   Browser Extensions   Build Systems   Bundles   Buttons   Caching   Camera   Canvas   Cards   Carousels   Changelog   Checkboxes   Cloud Storages   Color Analysis   Color Pickers   Colors   Comet/Push   Compass Sensors   Conferences   Content Providers   Continuous Integration   Crash Reports   Credit Cards   Credits   CSV   Curl/Flip   Data Binding   Data Generators   Data Structures   Database   Database Browsers   Date &   Debugging   Decompilers   Deep Links   Dependency Injections   Design   Design Patterns   Dex   Dialogs   Distributed Computing   Distribution Platforms   Download Managers   Drawables   Emoji   Emulators   EPUB   Equalizers &   Event Buses   Exception Handling   Face Recognition   Feedback &   File System   File/Directory   Fingerprint   Floating Action   Fonts   Forms   Fragments   FRP   FSM   Functional Programming   Gamepads   Games   Geocaching   Gestures   GIF   Glow Pad   Gradle Plugins   Graphics   Grid Views   Highlighting   HTML   HTTP Mocking   Icons   IDE   IDE Plugins   Image Croppers   Image Loaders   Image Pickers   Image Processing   Image Views   Instrumentation   Intents   Job Schedulers   JSON   Keyboard   Kotlin   Layouts   Library Demos   List View   List Views   Localization   Location   Lock Patterns   Logcat   Logging   Mails   Maps   Markdown   Mathematics   Maven Plugins   MBaaS   Media   Menus   Messaging   MIME   Mobile Web   Native Image   Navigation   NDK   Networking   NFC   NoSQL   Number Pickers   OAuth   Object Mocking   OCR Engines   OpenGL   ORM   Other Pickers   Parallax List   Parcelables   Particle Systems   Password Inputs   PDF   Permissions   Physics Engines   Platforms   Plugin Frameworks   Preferences   Progress Indicators   ProGuard   Properties   Protocol Buffer   Pull To   Purchases   Push/Pull   QR Codes   Quick Return   Radio Buttons   Range Bars   Ratings   Recycler Views   Resources   REST   Ripple Effects   RSS   Screenshots   Scripting   Scroll Views   SDK   Search Inputs   Security   Sensors   Services   Showcase Views   Signatures   Sliding Panels   Snackbars   SOAP   Social Networks   Spannable   Spinners   Splash Screens   SSH   Static Analysis   Status Bars   Styling   SVG   System   Tags   Task Managers   TDD &   Template Engines   Testing   Testing Tools   Text Formatting   Text Views   Text Watchers   Text-to   Toasts   Toolkits For   Tools   Tooltips   Trainings   TV   Twitter   Updaters   USB   User Stories   Utils   Validation   Video   View Adapters   View Pagers   Views   Watch Face   Wearable Data   Wearables   Weather   Web Tools   Web Views   WebRTC   WebSockets   Wheel Widgets   Wi-Fi   Widgets   Windows   Wizards   XML   XMPP   YAML   ZIP Codes