Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

wanglyGithub/RxJava_Okhttp3

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RxAndroid 响应式开发

Rx 是响应式编程的意思,本质是观察者模式,是以观察者(Observer)和订阅者(Subscriber) 为基础的异步响应方式。 响应式编程:就是用户在点击或者操作某个功能的时候,能够快速的检测当中的数据变化!这就涉及到了RxJava 中的 观察者(Observer)与被观察者(Obserable) 订阅者(subscribe)。在网上举的形象实例就是 小偷与警察的故事了!

RxJava 的基本使用不在这里赘述了,可以参考 https://github.com/wanglyGithub/Basic_RxJava 了解简单的使用。 在使用这些的时候还是更多的额关注的使用RxJava 提供的操作符这是非常重要的

okhttp的使用 更是简单,了解基本的GET、POSt 、表单形式请求数据等等,以下示例就简单的 使用了 GET 请求,获取用户信息!

Rx 响应式编程的优点:

1、代码简洁 2、异步的处理数据 3、很好的处理迸发

当中使用了MVP的设计模式,毕竟是Demo 所以就不在过多的包装了,不喜勿喷~~~~~~~~~ 简单的效果没有那么美观了,O(∩_∩)O哈哈~

About

RxJava+Okhttp use, to understand the response of the operation of programming ideas

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.