laoyuyu 6 years ago
parent 631017bb67
commit d8a14c0086
  1. 9
      Aria/src/main/java/com/arialyy/aria/core/common/ProxyHelper.java
  2. 15
      Aria/src/main/java/com/arialyy/aria/core/download/downloader/SimpleDownloadUtil.java
  3. 2
      Aria/src/main/java/com/arialyy/aria/core/inf/AbsTask.java
  4. 1
      Aria/src/main/java/com/arialyy/aria/util/AriaCrashHandler.java
  5. 4
      DEV_LOG.md
  6. 13
      README.md
  7. 1
      app/src/main/java/com/arialyy/simple/download/DownloadActivity.java
  8. 2
      build.gradle

@ -107,14 +107,16 @@ public class ProxyHelper {
} }
result = new HashSet<>(); result = new HashSet<>();
try { try {
if (Class.forName(className.concat("$$DownloadGroupListenerProxy")) != null) { if (getClass().getClassLoader().loadClass(className.concat("$$DownloadGroupListenerProxy"))
!= null) {
result.add(PROXY_TYPE_DOWNLOAD_GROUP); result.add(PROXY_TYPE_DOWNLOAD_GROUP);
} }
} catch (ClassNotFoundException e) { } catch (ClassNotFoundException e) {
//e.printStackTrace(); //e.printStackTrace();
} }
try { try {
if (Class.forName(className.concat("$$DownloadListenerProxy")) != null) { if (getClass().getClassLoader().loadClass(className.concat("$$DownloadListenerProxy"))
!= null) {
result.add(PROXY_TYPE_DOWNLOAD); result.add(PROXY_TYPE_DOWNLOAD);
} }
} catch (ClassNotFoundException e) { } catch (ClassNotFoundException e) {
@ -122,7 +124,8 @@ public class ProxyHelper {
} }
try { try {
if (Class.forName(className.concat("$$UploadListenerProxy")) != null) { if (getClass().getClassLoader().loadClass(className.concat("$$UploadListenerProxy"))
!= null) {
result.add(PROXY_TYPE_UPLOAD); result.add(PROXY_TYPE_UPLOAD);
} }
} catch (ClassNotFoundException e) { } catch (ClassNotFoundException e) {

@ -107,14 +107,15 @@ public class SimpleDownloadUtil implements IUtil, Runnable {
if (isStop || isCancel) { if (isStop || isCancel) {
return; return;
} }
if (mTaskWrapper.getEntity().getFileSize() <= 1 //if (mTaskWrapper.getEntity().getFileSize() <= 1
|| mTaskWrapper.isRefreshInfo() // || mTaskWrapper.isRefreshInfo()
|| mTaskWrapper.getRequestType() == AbsTaskWrapper.D_FTP // || mTaskWrapper.getRequestType() == AbsTaskWrapper.D_FTP
|| mTaskWrapper.getState() == IEntity.STATE_FAIL) { // || mTaskWrapper.getState() == IEntity.STATE_FAIL) {
// new Thread(createInfoThread()).start();
//} else {
// mDownloader.start();
//}
new Thread(createInfoThread()).start(); new Thread(createInfoThread()).start();
} else {
mDownloader.start();
}
} }
/** /**

@ -207,7 +207,7 @@ public abstract class AbsTask<ENTITY extends AbsEntity, TASK_WRAPPER extends Abs
/** /**
* 是否真正下载 * 是否真正下载
* *
* @return {@code true} 正下载 * @return {@code true} 下载
*/ */
@Override public boolean isRunning() { @Override public boolean isRunning() {
return mUtil.isRunning(); return mUtil.isRunning();

@ -17,7 +17,6 @@
*/ */
package com.arialyy.aria.util; package com.arialyy.aria.util;
import android.util.Log;
import java.util.concurrent.ExecutorService; import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors; import java.util.concurrent.Executors;

@ -3,7 +3,9 @@
- 优化数据库写入\修改的速度 - 优化数据库写入\修改的速度
- 精减任务实体的存储 - 精减任务实体的存储
- 增加下载组合任务的配置 - 增加下载组合任务的配置
- useBroadcast\notNetRetry这两个配置,统一在AppConfig中 - useBroadcast\notNetRetry这两个配置,统一在AppConfig中配置
- fix bug https://github.com/AriaLyy/Aria/issues/361
- fix bug https://github.com/AriaLyy/Aria/issues/365
+ v_3.5.4 (2019/1/8) + v_3.5.4 (2019/1/8)
- 修复不支持断点的下载地址,重复下载出现的数据库主键冲突问题 - 修复不支持断点的下载地址,重复下载出现的数据库主键冲突问题
+ v_3.5.3 (2018/12/23) + v_3.5.3 (2018/12/23)

@ -33,8 +33,8 @@ Aria有以下特点:
[![Compiler](https://api.bintray.com/packages/arialyy/maven/AriaCompiler/images/download.svg)](https://bintray.com/arialyy/maven/AriaCompiler/_latestVersion) [![Compiler](https://api.bintray.com/packages/arialyy/maven/AriaCompiler/images/download.svg)](https://bintray.com/arialyy/maven/AriaCompiler/_latestVersion)
```java ```java
compile 'com.arialyy.aria:aria-core:3.5.4' compile 'com.arialyy.aria:aria-core:3.6'
annotationProcessor 'com.arialyy.aria:aria-compiler:3.5.4' annotationProcessor 'com.arialyy.aria:aria-compiler:3.6'
``` ```
如果出现android support,请将 `compile 'com.arialyy.aria:aria-core:<last-version>'`替换为 如果出现android support,请将 `compile 'com.arialyy.aria:aria-core:<last-version>'`替换为
``` ```
@ -102,8 +102,13 @@ protected void onCreate(Bundle savedInstanceState) {
### 版本日志 ### 版本日志
+ v_3.5.4 (2019/1/8) + v_3.6(2019/2/27)
- 修复不支持断点的下载地址,重复下载出现的数据库主键冲突问题 - 优化数据库写入\修改的速度
- 精减任务实体的存储
- 增加下载组合任务的配置
- useBroadcast\notNetRetry这两个配置,统一在AppConfig中配置
- fix bug https://github.com/AriaLyy/Aria/issues/361
- fix bug https://github.com/AriaLyy/Aria/issues/365
[更多版本记录](https://github.com/AriaLyy/Aria/blob/master/DEV_LOG.md) [更多版本记录](https://github.com/AriaLyy/Aria/blob/master/DEV_LOG.md)

@ -24,6 +24,7 @@ import android.view.Gravity;
import android.view.View; import android.view.View;
import android.widget.Button; import android.widget.Button;
import butterknife.Bind; import butterknife.Bind;
import com.arialyy.aria.core.Aria;
import com.arialyy.frame.permission.OnPermissionCallback; import com.arialyy.frame.permission.OnPermissionCallback;
import com.arialyy.frame.permission.PermissionManager; import com.arialyy.frame.permission.PermissionManager;
import com.arialyy.frame.util.show.T; import com.arialyy.frame.util.show.T;

@ -39,7 +39,7 @@ task clean(type: Delete) {
ext { ext {
userOrg = 'arialyy' userOrg = 'arialyy'
groupId = 'com.arialyy.aria' groupId = 'com.arialyy.aria'
publishVersion = '3.5.4' publishVersion = '3.6'
// publishVersion = '1.0.4' //FTP插件 // publishVersion = '1.0.4' //FTP插件
repoName='maven' repoName='maven'
desc = 'android 下载框架' desc = 'android 下载框架'

Loading…
Cancel
Save