- This happens when the app gets killed by the user. We want to keep a service running it to send push notifications even if they killed the app.
- http://stackoverflow.com/questions/18219657/how-do-i-keep-a-service-alive-indefinitely
- USING REALM instead of SQLITE. Step by step: https://realm.io/news/360andev-chris-guzman-android-libraries-beginner/ (Slide 61, minuto 25
New RXJava: https://github.com/amitshekhariitbhu/RxJava2-Android-Samples
App as view tutorial... this is what I'm doing
GUAU:
- https://github.com/nilopc-learning-android/Filmy
- https://github.com/nilopc-learning-android/android-examples
- http://hannesdorfmann.com/android/evolution-of-the-repository-pattern
THIS IS HUGE:
CUSTOM VIEWS:
- https://corner.squareup.com/2014/10/advocating-against-android-fragments.html
- https://developer.android.com/training/material/lists-cards.html
- Load from web deeplink (how do these even work?!)
- Do not call api is no internet and not un cache
- https://github.com/nilopc-learning-android/ZhiHuDaily/blob/master/app/src/main/java/com/marktony/zhihudaily/Utils/NetworkState.java
- https://github.com/realm/realm-java/tree/master/examples/rxJavaExample
- https://github.com/realm/realm-java/blob/master/examples/rxJavaExample/src/main/java/io/realm/examples/rxjava/gotchas/GotchasActivity.java
Images add much-needed context and visual flair to Android applications. Picasso allows for hassle-free image loading in your application—often in one line of code!
https://github.com/afollestad/material-dialogs
Testing
- https://github.com/facebook/screenshot-tests-for-android
- https://github.com/mattlogan/locationtracker (*unit style)
Repository cache: caching when user goes offline
- http://stackoverflow.com/questions/23429046/can-retrofit-with-okhttp-use-cache-data-when-offline
- https://github.com/digitalbuddha/StoreDemo
Retrofit to Domain Entities
Cache
- https://github.com/android10/Android-CleanArchitecture/blob/master/data/src/main/java/com/fernandocejas/android10/sample/data/cache/UserCache.java
- https://github.com/android10/Android-CleanArchitecture/blob/master/data/src/main/java/com/fernandocejas/android10/sample/data/cache/UserCacheImpl.java
- Stop weird refreshing. Remove progressbar status right having UI elements populated.
- https://github.com/android10/Android-CleanArchitecture/blob/master/domain/src/main/java/com/fernandocejas/android10/sample/domain/interactor/UseCase.java
- UseCase with RxJava
- Drop AsyncTask por Rx
- https://github.com/nilopc-learning-android/EffectiveAndroidUI
- http://blog.danlew.net/2014/09/15/grokking-rxjava-part-1/
- http://akarnokd.blogspot.com.es/
- Easy API endpoint data access.
- To generate POJOs: http://www.jsonschema2pojo.org/
- Observables
- Added Dagger2 for non UI related
- Added ButterKnife for UI related: https://github.com/JakeWharton/butterknife
-
Activity or Fragment
- Recibe: Presenter
- setea/esconde/muestra Fragments
-
Presenter:
- Recibe: UseCase
- Recibe: UserModelDataMapper
- Internamente implementa:
- private final class xxxSubscriber extends Rx.Subscriber
FragmentPagerAdapter
- Fragments are detached, NOT destroyed.
- Useful for SMALL list of fragments.
- Remains in memory. Fills up memory and app will crash if lots of fragments.
- Use for static data not coming from network and does not require calculations.
FragmentStatePagerAdapter
- Works well for LARGE lists.
- It destroys fragments when not used.
- Not kept in memory (as it keeps destroying).
- Requires proper use of CACHING (eg: repos) when using data from network or heavy calculations.
PageAdapter
- Items are destroyed.
- Useful for SMALL lists.