From c7bb1cd0c584d479704027cdbb6b5ba32b46acae Mon Sep 17 00:00:00 2001 From: laoyuyu <511455842@qq.com> Date: Mon, 7 May 2018 19:48:12 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E4=BE=8B=E5=AD=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 23 ++++++++----------- app/src/main/AndroidManifest.xml | 4 ++-- .../download/group/ChildHandleDialog.java | 4 ++-- .../arialyy/simple/test/AnyRunActivity.java | 15 ++++++------ build.gradle | 2 +- 5 files changed, 23 insertions(+), 25 deletions(-) diff --git a/README.md b/README.md index 24e42665..0036279e 100644 --- a/README.md +++ b/README.md @@ -28,8 +28,8 @@ Aria有以下特点: [![Download](https://api.bintray.com/packages/arialyy/maven/AriaApi/images/download.svg)](https://bintray.com/arialyy/maven/AriaApi/_latestVersion) [![Download](https://api.bintray.com/packages/arialyy/maven/AriaCompiler/images/download.svg)](https://bintray.com/arialyy/maven/AriaCompiler/_latestVersion) ```java -compile 'com.arialyy.aria:aria-core:3.3.16' -annotationProcessor 'com.arialyy.aria:aria-compiler:3.3.16' +compile 'com.arialyy.aria:aria-core:3.4' +annotationProcessor 'com.arialyy.aria:aria-compiler:3.4' ``` 如果出现android support,请将 `compile 'com.arialyy.aria:aria-core:'`替换为 ``` @@ -94,20 +94,17 @@ protected void onCreate(Bundle savedInstanceState) { //在这里处理任务完成的状态 } ``` -[更多注解使用方法](https://github.com/AriaLyy/Aria/wiki/%E6%B3%A8%E8%A7%A3%E4%BD%BF%E7%94%A8) -### [HTTP任务组下载\FTP下载;HTTP\FTP文件上传](https://github.com/AriaLyy/Aria/wiki/Aria%E5%9F%BA%E6%9C%AC%E4%BD%BF%E7%94%A8) - -### [参数配置](https://github.com/AriaLyy/Aria/wiki/Aria%E5%8F%82%E6%95%B0%E9%85%8D%E7%BD%AE) - -### [更多说明,见WIKI](https://github.com/AriaLyy/Aria/wiki) +### [更多说明,见WIKI](http://aria.laoyuyu.me/aria_doc/) ### 版本日志 - + v_3.3.16 - - 修复一个activity启动多次,无法进行回掉的bug https://github.com/AriaLyy/Aria/issues/200 - - 优化target代码结构,移除路径被占用的提示 - - 添加支持chunked模式的下载 - - 去掉上一个版本"//"的限制 + + v_3.4 + - 优化大量代码 + - 重构Aria的ORM模型,提高了数据读取的可靠性和读写速度 + - 现在可在任意类中使用Aria了,[使用方法](http://aria.laoyuyu.me/aria_doc/start/any_java.html) + - 添加`window.location.replace("http://xxxx")`类型的网页重定向支持 + - 支持gzip、deflate 压缩类型的输入流 + - 添加`useServerFileName`,可使用服务端响应header的`Content-Disposition`携带的文件名 [更多版本记录](https://github.com/AriaLyy/Aria/blob/master/DEV_LOG.md) diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index bf4f2dc0..c11fae91 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -16,9 +16,9 @@ android:theme="@style/AppTheme.NoActionBar"> - + diff --git a/app/src/main/java/com/arialyy/simple/download/group/ChildHandleDialog.java b/app/src/main/java/com/arialyy/simple/download/group/ChildHandleDialog.java index c7bc958b..3de6d4f7 100644 --- a/app/src/main/java/com/arialyy/simple/download/group/ChildHandleDialog.java +++ b/app/src/main/java/com/arialyy/simple/download/group/ChildHandleDialog.java @@ -134,10 +134,10 @@ import java.util.List; @OnClick({ R.id.start, R.id.stop, R.id.cancel }) void onClick(View view) { switch (view.getId()) { case R.id.start: - Aria.download(getContext()).load(mUrls).getSubTaskManager().startSubTask(mChildEntity.getUrl()); + Aria.download(getContext()).loadGroup(mUrls).getSubTaskManager().startSubTask(mChildEntity.getUrl()); break; case R.id.stop: - Aria.download(getContext()).load(mUrls).getSubTaskManager().stopSubTask(mChildEntity.getUrl()); + Aria.download(getContext()).loadGroup(mUrls).getSubTaskManager().stopSubTask(mChildEntity.getUrl()); break; //case R.id.cancel: // Aria.download(this).load(mUrls).getSubTaskManager().cancelSubTask(mChildEntity.getUrl()); diff --git a/app/src/main/java/com/arialyy/simple/test/AnyRunActivity.java b/app/src/main/java/com/arialyy/simple/test/AnyRunActivity.java index 715952a3..f80bd566 100644 --- a/app/src/main/java/com/arialyy/simple/test/AnyRunActivity.java +++ b/app/src/main/java/com/arialyy/simple/test/AnyRunActivity.java @@ -4,6 +4,7 @@ import android.os.Bundle; import android.view.View; import com.arialyy.aria.core.Aria; import com.arialyy.aria.core.inf.AbsEntity; +import com.arialyy.aria.util.ALog; import com.arialyy.simple.R; import com.arialyy.simple.base.BaseActivity; import com.arialyy.simple.databinding.ActivityTestBinding; @@ -17,9 +18,7 @@ public class AnyRunActivity extends BaseActivity { AnyRunnModule module; String[] urls; int index = 0; - //String URL = "http://static.gaoshouyou.com/d/12/0d/7f120f50c80d2e7b8c4ba24ece4f9cdd.apk"; - String URL = - "https://www.baidu.com/link?url=_LFCuTPtnzFxVJByJ504QymRywIA1Z_T5xUxe9ZLuxcGM0C_RcdpWyB1eGjbJC-e5wv5wAKM4WmLMAS5KeF6EZJHB8Va3YqZUiaErqK_pxm&wd=&eqid=e8583fe70002d126000000065a99f864"; + String URL = "http://static.gaoshouyou.com/d/12/0d/7f120f50c80d2e7b8c4ba24ece4f9cdd.apk"; @Override protected int setLayoutId() { return R.layout.activity_test; @@ -42,12 +41,14 @@ public class AnyRunActivity extends BaseActivity { // index++; //} module.start(URL); + List list = Aria.download(this).getTotalTaskList(); + ALog.d(TAG, "size ==> " + list.size()); break; case R.id.stop: - List list = Aria.download(this).getTotalTaskList(); - - //module.stop(); - module.stop(URL); + //List list = Aria.download(this).getTotalTaskList(); + // + ////module.stop(); + //module.stop(URL); break; case R.id.cancel: diff --git a/build.gradle b/build.gradle index 3dcbefee..7d7d9d9c 100644 --- a/build.gradle +++ b/build.gradle @@ -39,7 +39,7 @@ task clean(type: Delete) { ext { userOrg = 'arialyy' groupId = 'com.arialyy.aria' - publishVersion = '3.4_dev_1' + publishVersion = '3.4' // publishVersion = '1.0.3' //FTP插件 repoName='maven' desc = 'android 下载框架'