Retrofit使用
Retrofit使用
step1 retrofit开源库、okhttp网络库、数据解析器集成、注册网络权限
见截图所示,第一步
见截图所示
retrofit引入
使用步骤:
1、Retrofit开源库、OkHttp网络库、数据解析器集成,注册网络权限
代码:compile ‘com.squareup.retrofit2:retrofit:2.2.0’
compile ‘com.squareup.okhttp3:okhttp:3.4.1’
compile ‘com.squareup.retrofit2:converter-gson:2.0.2’
需要INTERNET权限
retrofit
retrofix 网络通信技术
retrofit 最新网络通信协议的框架,继承okhttp