Android-对Okhttp3进行二次封装

上传者: 39841365 | 上传时间: 2021-08-13 14:40:14 | 文件大小: 144KB | 文件类型: ZIP
对Okhttp3进行二次封装,对外提供了POST请求、GET请求、PATCH请求、PUT请求、DELETE请求、上传文件、下载文件、取消请求、Raw/Json/Gson返回、后台下载管理等功能

文件下载

资源详情

[{"title":"( 64 个子文件 144KB ) Android-对Okhttp3进行二次封装","children":[{"title":"tsy12321-MyOkHttp-949e3ce","children":[{"title":"myokhttp","children":[{"title":"src","children":[{"title":"androidTest","children":[{"title":"java","children":[{"title":"com","children":[{"title":"tsy","children":[{"title":"sdk","children":[{"title":"myokhttp","children":[{"title":"ApplicationTest.java <span style='color:#111;'> 351B </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true}],"spread":true}],"spread":true}],"spread":true},{"title":"test","children":[{"title":"java","children":[{"title":"com","children":[{"title":"tsy","children":[{"title":"sdk","children":[{"title":"myokhttp","children":[{"title":"ExampleUnitTest.java <span style='color:#111;'> 313B </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true}],"spread":true}],"spread":true}],"spread":true},{"title":"main","children":[{"title":"AndroidManifest.xml <span style='color:#111;'> 118B </span>","children":null,"spread":false},{"title":"res","children":[{"title":"values","children":[{"title":"strings.xml <span style='color:#111;'> 25B </span>","children":null,"spread":false}],"spread":true}],"spread":true},{"title":"java","children":[{"title":"com","children":[{"title":"tsy","children":[{"title":"sdk","children":[{"title":"myokhttp","children":[{"title":"body","children":[{"title":"ProgressRequestBody.java <span style='color:#111;'> 2.20KB </span>","children":null,"spread":false},{"title":"ResponseProgressBody.java <span style='color:#111;'> 1.94KB </span>","children":null,"spread":false}],"spread":true},{"title":"download_mgr","children":[{"title":"DownloadTask.java <span style='color:#111;'> 5.82KB </span>","children":null,"spread":false},{"title":"DownloadStatus.java <span style='color:#111;'> 538B </span>","children":null,"spread":false},{"title":"DownloadTaskListener.java <span style='color:#111;'> 1.12KB </span>","children":null,"spread":false},{"title":"AbstractDownloadMgr.java <span style='color:#111;'> 15.32KB </span>","children":null,"spread":false}],"spread":false},{"title":"callback","children":[{"title":"MyDownloadCallback.java <span style='color:#111;'> 5.67KB </span>","children":null,"spread":false},{"title":"MyCallback.java <span style='color:#111;'> 1.31KB </span>","children":null,"spread":false}],"spread":false},{"title":"builder","children":[{"title":"DeleteBuilder.java <span style='color:#111;'> 1.24KB </span>","children":null,"spread":false},{"title":"UploadBuilder.java <span style='color:#111;'> 4.91KB </span>","children":null,"spread":false},{"title":"PutBuilder.java <span style='color:#111;'> 1.35KB </span>","children":null,"spread":false},{"title":"PostBuilder.java <span style='color:#111;'> 1.74KB </span>","children":null,"spread":false},{"title":"PatchBuilder.java <span style='color:#111;'> 1.37KB </span>","children":null,"spread":false},{"title":"GetBuilder.java <span style='color:#111;'> 1.83KB </span>","children":null,"spread":false},{"title":"DownloadBuilder.java <span style='color:#111;'> 6.14KB </span>","children":null,"spread":false},{"title":"OkHttpRequestBuilderHasParam.java <span style='color:#111;'> 974B </span>","children":null,"spread":false},{"title":"OkHttpRequestBuilder.java <span style='color:#111;'> 1.97KB </span>","children":null,"spread":false}],"spread":false},{"title":"util","children":[{"title":"LogUtils.java <span style='color:#111;'> 4.28KB </span>","children":null,"spread":false}],"spread":false},{"title":"response","children":[{"title":"JsonResponseHandler.java <span style='color:#111;'> 3.09KB </span>","children":null,"spread":false},{"title":"RawResponseHandler.java <span style='color:#111;'> 1.40KB </span>","children":null,"spread":false},{"title":"IResponseHandler.java <span style='color:#111;'> 295B </span>","children":null,"spread":false},{"title":"DownloadResponseHandler.java <span style='color:#111;'> 436B </span>","children":null,"spread":false},{"title":"GsonResponseHandler.java <span style='color:#111;'> 2.57KB </span>","children":null,"spread":false}],"spread":false},{"title":"MyOkHttp.java <span style='color:#111;'> 2.39KB </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true}],"spread":true}],"spread":true}],"spread":true}],"spread":true},{"title":".gitignore <span style='color:#111;'> 12B </span>","children":null,"spread":false},{"title":"build.gradle <span style='color:#111;'> 1.28KB </span>","children":null,"spread":false},{"title":"proguard-rules.pro <span style='color:#111;'> 661B </span>","children":null,"spread":false}],"spread":true},{"title":"gradlew <span style='color:#111;'> 4.85KB </span>","children":null,"spread":false},{"title":"settings.gradle <span style='color:#111;'> 28B </span>","children":null,"spread":false},{"title":"LICENSE <span style='color:#111;'> 11.09KB </span>","children":null,"spread":false},{"title":"gradle","children":[{"title":"wrapper","children":[{"title":"gradle-wrapper.properties <span style='color:#111;'> 233B </span>","children":null,"spread":false},{"title":"gradle-wrapper.jar <span style='color:#111;'> 52.38KB </span>","children":null,"spread":false}],"spread":true}],"spread":true},{"title":"README.md <span style='color:#111;'> 17.14KB </span>","children":null,"spread":false},{"title":"gradlew.bat <span style='color:#111;'> 2.35KB </span>","children":null,"spread":false},{"title":"gradle.properties <span style='color:#111;'> 730B </span>","children":null,"spread":false},{"title":".gitignore <span style='color:#111;'> 86B </span>","children":null,"spread":false},{"title":"app","children":[{"title":"src","children":[{"title":"androidTest","children":[{"title":"java","children":[{"title":"com","children":[{"title":"tsy","children":[{"title":"sample","children":[{"title":"myokhttp","children":[{"title":"ExampleInstrumentedTest.java <span style='color:#111;'> 750B </span>","children":null,"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":true}],"spread":true},{"title":"test","children":[{"title":"java","children":[{"title":"com","children":[{"title":"tsy","children":[{"title":"sample","children":[{"title":"myokhttp","children":[{"title":"ExampleUnitTest.java <span style='color:#111;'> 401B </span>","children":null,"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":true},{"title":"main","children":[{"title":"AndroidManifest.xml <span style='color:#111;'> 834B </span>","children":null,"spread":false},{"title":"res","children":[{"title":"mipmap-hdpi","children":[{"title":"ic_launcher.png <span style='color:#111;'> 3.34KB </span>","children":null,"spread":false}],"spread":false},{"title":"mipmap-xxxhdpi","children":[{"title":"ic_launcher.png <span style='color:#111;'> 10.24KB </span>","children":null,"spread":false}],"spread":false},{"title":"mipmap-xhdpi","children":[{"title":"ic_launcher.png <span style='color:#111;'> 4.73KB </span>","children":null,"spread":false}],"spread":false},{"title":"mipmap-mdpi","children":[{"title":"ic_launcher.png <span style='color:#111;'> 2.15KB </span>","children":null,"spread":false}],"spread":false},{"title":"layout","children":[{"title":"activity_download_mgr.xml <span style='color:#111;'> 1.36KB </span>","children":null,"spread":false},{"title":"activity_main.xml <span style='color:#111;'> 4.04KB </span>","children":null,"spread":false}],"spread":false},{"title":"values-w820dp","children":[{"title":"dimens.xml <span style='color:#111;'> 358B </span>","children":null,"spread":false}],"spread":false},{"title":"values","children":[{"title":"colors.xml <span style='color:#111;'> 208B </span>","children":null,"spread":false},{"title":"strings.xml <span style='color:#111;'> 71B </span>","children":null,"spread":false},{"title":"styles.xml <span style='color:#111;'> 383B </span>","children":null,"spread":false},{"title":"dimens.xml <span style='color:#111;'> 211B </span>","children":null,"spread":false}],"spread":false},{"title":"mipmap-xxhdpi","children":[{"title":"ic_launcher.png <span style='color:#111;'> 7.54KB </span>","children":null,"spread":false}],"spread":false}],"spread":false},{"title":"java","children":[{"title":"com","children":[{"title":"tsy","children":[{"title":"sample","children":[{"title":"myokhttp","children":[{"title":"MyApplication.java <span style='color:#111;'> 1.44KB </span>","children":null,"spread":false},{"title":"UploadModel.java <span style='color:#111;'> 134B </span>","children":null,"spread":false},{"title":"DownloadMgrActivity.java <span style='color:#111;'> 4.20KB </span>","children":null,"spread":false},{"title":"DownloadMgr.java <span style='color:#111;'> 1.84KB </span>","children":null,"spread":false},{"title":"MainActivity.java <span style='color:#111;'> 8.77KB </span>","children":null,"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":false}],"spread":true},{"title":".gitignore <span style='color:#111;'> 7B </span>","children":null,"spread":false},{"title":"build.gradle <span style='color:#111;'> 995B </span>","children":null,"spread":false},{"title":"proguard-rules.pro <span style='color:#111;'> 661B </span>","children":null,"spread":false}],"spread":true},{"title":"build.gradle <span style='color:#111;'> 417B </span>","children":null,"spread":false}],"spread":false}],"spread":true}]

评论信息

  • henrymoore :
    多谢您的资源,接口封装的比较实用,谢谢分享。
    2019-10-15

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明