Rxjava and rxandroid a basic use
1. Rxjava Project Address
Https://github.com/ReactiveX/RxJava
2. Rxandroid Project Address
Https://github.com/ReactiveX/RxAndroid
3, the relationship between Rxjava and rxandroid
Rxandroid is an extension of the Android platform for Rxjava, mainly for Android development
4, the difference between Rxjava and Eventbus.
Rxjava is more widely used than Eventbus, Eventbus is just a messaging tool, but Rxjava can do almost anything. If Android is developed, you can use rxandroid, an extension of Rxjava, and Sqare's retrofit can easily complete network access. We know that asynchronous operations in Android are generally done with asyctask, but Asyctask has many drawbacks, such as the inability to terminate the execution of the task easily.
Rxandroid can completely replace Asyctask to complete various asynchronous operations, and there are bindactivity and Bindfragment methods, you do not need to consider asynchronous operations and F ragment life cycle problems, There are also more powerful chained calls that can make the program very concise. Recommended use of rxandroid.
5, the use of Rxandroid method
Compile ' io.reactivex:rxandroid:1.2.0 '
6, how to view the latest version of Rxandroid.
http://search.maven.org/#search%7cga%7c1%7ca%3a%22rxandroid%22
7, Rxandroid specific use method http://gank.io/post/560e15be2dca930e00da1083#toc_14 http://blog.csdn.net/theone1 0211024/article/details/50435325
http://huxian99.github.io/tags/RxJava/
Https://github.com/mcxiaoke/RxDocs
8. Create the viewer
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22-23 |