1. 使用RxJava来改进用户体验 优化
  2. 使用RxJava 提升用户体验 (demo) 优化
  3. 给 Android 开发者的 RxJava 详解 入门必读 demo
  4. Architecting Android with RxJava
  5. Awesome-RxJava:RxJava resources
  6. RxJava使用场景小结:
  7. RxRelay:RxJava types that are both an Observable and an Action1.
  8. pic:请记住: 实践是检验真理的唯一标准,有所尝试才能有所收获。
  9. RxAndroidEventsSample:BusEvents implementation base RxJava/RxAndroid
  10. [RxBluetooth](https://github.com/IvBaranov/RxBluetooth:Android reactive bluetooth
  11. RxJavaSamples:RxJava 和 Retrofit 结合使用的几个最常见使用方式举例
  12. RxCamera:RxJava style API for android camera
  13. Isolate:A material design android app to show zhihu daily . 壁上观
  14. RxBus:RxBus (Support Sticky)
  15. RxActivityResult:Reactive results from startActivityForResult() in the form of an Observable.
  16. android-data-binding-rxjava:Demo that shows how to use RxJava with Android Data Binding ObservableFields
  17. RxActivityResult:A reactive-tiny-badass-vindictive library to break with the OnActivityResult implementation as it breaks the observables chain.
  18. AdvancedRxJava:Advanced RxJava http://akarnokd.blogspot.com/ 系列博客的中文翻译,已征得作者授权。
  19. RxRelay:RxJava types that are both an Observable and an Action1.

samples

  1. RxJavaDemo:How to use RxJava handle multisouce from network and local data.
  2. rxjava-examples:全面,完整,图文并茂的RxJavaAPI使用示例。

Rxjava2学习资料

  1. Android RxJava2:响应式编程 [Android RxJava2]

知识点:

库:

  1. RxViewStub:It's similar to RxBinding, but only support ViewStub.

项目:

  1. RxBlur:用RxJava处理和操作高斯模糊效果的简单用例。
  2. RxWeather:Architecting Android with RxJava
  3. RxFile:Rx methods to get a File and Image or Video thumbnails from a MediaContentProvider on Android (Drive, Dropbox etc)
  4. RxJava-Android-Samples:Learning RxJava for Android by example
  5. RxRecyclerAdapter:Rx based RecyclerView Adapter.
  6. ReactiveAudioRecord:A reactive (RxAndroid) implementation of the AudioRecord for recording raw (pcm) audio-data.
  7. RxJavaSamples:收集了RxJava常见的使用场景,例子简洁、经典、易懂…
  8. RxJava-collection:RxJava中文手册,资料,翻译收集

代码:

  1. 代码1:
     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    14
    15
    16
    17
    18
    
     RxTextView.textChanges(et_keyword)
                // 上面的对 tv_result 的操作需要在主线程
                .subscribeOn(AndroidSchedulers.mainThread())
                .debounce(600, TimeUnit.MILLISECONDS, AndroidSchedulers.mainThread())
                .filter(new Func1<CharSequence, Boolean>() {
                    @Override public Boolean call(CharSequence charSequence) {
                        // 清空搜索出来的结构
                        tv_result.setText("");
                        //当 EditText 中文字大于0的时候
                        return charSequence.length() > 0;
                    }
                })
                .switchMap(new Func1<CharSequence, Observable<Data>>() {
                    @Override public Observable<Data> call(CharSequence charSequence) {
                        // 搜索
                        return service.searchProdcut("utf-8", charSequence.toString());
                    }
                })
    

// .retryWhen(new RetryWithConnectivityIncremental(MainActivity.this, 5, 15, TimeUnit.MILLISECONDS)) // 网络操作在io线程 .subscribeOn(Schedulers.io()) //将 data 转换成 ArrayList<ArrayList> .map(new Func1<Data, ArrayList<ArrayList»() { @Override public ArrayList<ArrayList> call(Data data) { return data.result; } }) // 将 ArrayList<ArrayList> 中每一项提取出来 ArrayList .flatMap(new Func1<ArrayList<ArrayList>, Observable<ArrayList»() { @Override public Observable<ArrayList> call(ArrayList<ArrayList> arrayLists) { return Observable.from(arrayLists); } }) .filter(new Func1<ArrayList, Boolean>() { @Override public Boolean call(ArrayList strings) { return strings.size() >= 2; } }) .map(new Func1<ArrayList, String>() { @Override public String call(ArrayList strings) { return “[商品名称:” + strings.get(0) + “, ID:” + strings.get(1) + “]\n”; } }) // 发生错误后不要调用 onError,而是转到 onErrorResumeNext /.onErrorResumeNext(new Func1<Throwable, Observable<? extends String»() { @Override public Observable<? extends String> call(Throwable throwable) { return Observable.just(“error result”); } })/ .observeOn(AndroidSchedulers.mainThread()) .subscribe(new Action1() { @Override public void call(String charSequence) { showpop(charSequence); } }); ```