-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
23 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# 基于Retrofit网络框架的封装 | ||
|
||
## 实现功能 | ||
* get请求封装 | ||
* 请求头和参数统一配置,分开配置 | ||
* 异步统一回调接口 | ||
* 单个请求、单个界面请求、所有请求取消 | ||
* 缓存策略:在线缓存、离线缓存 | ||
* 下载 | ||
* 上传 | ||
|
||
|
||
### 引用 | ||
``` | ||
compile 'com.excellence.retrofit:retrofit2:_latestVersion' | ||
``` | ||
|
||
### 权限 | ||
``` | ||
<uses-permission android:name="android.permission.INTERNET"/> | ||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/> | ||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/> | ||
``` |