diff --git a/README.md b/README.md index 3075889a..5b03bba0 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # DownloadUtil ![图标](https://github.com/AriaLyy/DownloadUtil/blob/v_2.0/app/src/main/res/mipmap-hdpi/ic_launcher.png)
-这是一个 android 多线程多任务断点续传工具,使用该工具,你可以很容易实现`多线程下载功能和复杂的任务自动切换功能`
+这是一个 android 智能切换多任务断点续传工具,使用该工具,你可以很容易实现`多线程下载功能和复杂的任务自动切换功能`
+ 该工具具有以下特点: - 通过命令控制下载 - 可在广播中接收任务的各种下载状态 @@ -11,7 +11,7 @@ #下载 [![Download](https://api.bintray.com/packages/arialyy/maven/MTDownloadUtil/images/download.svg)](https://bintray.com/arialyy/maven/MTDownloadUtil/_latestVersion)
-compile 'com.arialyy.downloadutil:DownloadUtil:2.1.0' +compile 'com.arialyy.downloadutil:DownloadUtil:2.1.1' #示例 @@ -130,13 +130,20 @@ private BroadcastReceiver mReceiver = new BroadcastReceiver() { } ``` +# 修改最大任务数 +``` +mManager.getTaskQueue().setDownloadNum(num); + +``` + # 开发日志 + v_2.1.0 修复大量bug + + v_2.1.1 增加,选择最大下载任务数接口 License ------- - Copyright 2016 AriaLyy + Copyright 2016 AriaLyy(DownloadUtil) Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/app/src/androidTest/java/com/example/arial/downloaddemo/ApplicationTest.java b/app/src/androidTest/java/com/example/arial/downloaddemo/ApplicationTest.java index b0b6aa45..c9a9d76d 100644 --- a/app/src/androidTest/java/com/example/arial/downloaddemo/ApplicationTest.java +++ b/app/src/androidTest/java/com/example/arial/downloaddemo/ApplicationTest.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.example.arial.downloaddemo; import android.app.Application; diff --git a/app/src/main/java/com/arialyy/simple/activity/MainActivity.java b/app/src/main/java/com/arialyy/simple/activity/MainActivity.java index bf720355..c6b232c4 100644 --- a/app/src/main/java/com/arialyy/simple/activity/MainActivity.java +++ b/app/src/main/java/com/arialyy/simple/activity/MainActivity.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.activity; import android.Manifest; @@ -64,4 +81,4 @@ public class MainActivity extends BaseActivity { break; } } -} +} \ No newline at end of file diff --git a/app/src/main/java/com/arialyy/simple/activity/MultiTaskActivity.java b/app/src/main/java/com/arialyy/simple/activity/MultiTaskActivity.java index 883695ca..e1d00c38 100644 --- a/app/src/main/java/com/arialyy/simple/activity/MultiTaskActivity.java +++ b/app/src/main/java/com/arialyy/simple/activity/MultiTaskActivity.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.activity; import android.content.BroadcastReceiver; @@ -110,4 +127,4 @@ public class MultiTaskActivity extends BaseActivity { mAdapter.setDownloadNum(Integer.parseInt(data + "")); } } -} +} \ No newline at end of file diff --git a/app/src/main/java/com/arialyy/simple/activity/SingleTaskActivity.java b/app/src/main/java/com/arialyy/simple/activity/SingleTaskActivity.java index 31ddca59..0db815af 100644 --- a/app/src/main/java/com/arialyy/simple/activity/SingleTaskActivity.java +++ b/app/src/main/java/com/arialyy/simple/activity/SingleTaskActivity.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.activity; import android.content.BroadcastReceiver; @@ -221,4 +238,4 @@ public class SingleTaskActivity extends BaseActivity { IDownloadCmd cancelCmd = mFactory.createCmd(mEntity, CmdFactory.TASK_CANCEL); mManager.setCmd(cancelCmd).exe(); } -} +} \ No newline at end of file diff --git a/app/src/main/java/com/arialyy/simple/adapter/DownloadAdapter.java b/app/src/main/java/com/arialyy/simple/adapter/DownloadAdapter.java index 87108708..6686d36a 100644 --- a/app/src/main/java/com/arialyy/simple/adapter/DownloadAdapter.java +++ b/app/src/main/java/com/arialyy/simple/adapter/DownloadAdapter.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.adapter; import android.content.Context; @@ -192,4 +209,4 @@ public class DownloadAdapter extends AbsRVAdapter extends AbsActivi @Override protected void init(Bundle savedInstanceState) { super.init(savedInstanceState); } -} +} \ No newline at end of file diff --git a/app/src/main/java/com/arialyy/simple/base/BaseApplication.java b/app/src/main/java/com/arialyy/simple/base/BaseApplication.java index 1b07a75a..4710265d 100644 --- a/app/src/main/java/com/arialyy/simple/base/BaseApplication.java +++ b/app/src/main/java/com/arialyy/simple/base/BaseApplication.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.base; import android.app.Application; @@ -13,4 +30,4 @@ public class BaseApplication extends Application { AbsFrame.init(this); DownloadManager.init(this); } -} +} \ No newline at end of file diff --git a/app/src/main/java/com/arialyy/simple/base/BaseDialog.java b/app/src/main/java/com/arialyy/simple/base/BaseDialog.java index a682aa55..50d55b5a 100644 --- a/app/src/main/java/com/arialyy/simple/base/BaseDialog.java +++ b/app/src/main/java/com/arialyy/simple/base/BaseDialog.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.base; import android.databinding.ViewDataBinding; @@ -20,4 +37,4 @@ public abstract class BaseDialog extends AbsDialogFr @Override protected void dataCallback(int result, Object data) { } -} +} \ No newline at end of file diff --git a/app/src/main/java/com/arialyy/simple/base/BaseModule.java b/app/src/main/java/com/arialyy/simple/base/BaseModule.java index fc27dc65..940cecdc 100644 --- a/app/src/main/java/com/arialyy/simple/base/BaseModule.java +++ b/app/src/main/java/com/arialyy/simple/base/BaseModule.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.base; import android.content.Context; @@ -10,4 +27,4 @@ public class BaseModule extends AbsModule { public BaseModule(Context context) { super(context); } -} +} \ No newline at end of file diff --git a/app/src/main/java/com/arialyy/simple/dialog/DownloadNumDialog.java b/app/src/main/java/com/arialyy/simple/dialog/DownloadNumDialog.java index 4d39c6fd..e4d34269 100644 --- a/app/src/main/java/com/arialyy/simple/dialog/DownloadNumDialog.java +++ b/app/src/main/java/com/arialyy/simple/dialog/DownloadNumDialog.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.dialog; import android.annotation.SuppressLint; @@ -50,4 +67,4 @@ import com.arialyy.simple.databinding.DialogDownloadNumBinding; dismiss(); } } -} +} \ No newline at end of file diff --git a/app/src/main/java/com/arialyy/simple/module/DownloadModule.java b/app/src/main/java/com/arialyy/simple/module/DownloadModule.java index 2a4fbe45..dd8eedb1 100644 --- a/app/src/main/java/com/arialyy/simple/module/DownloadModule.java +++ b/app/src/main/java/com/arialyy/simple/module/DownloadModule.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.module; import android.content.Context; @@ -110,4 +127,4 @@ public class DownloadModule extends BaseModule { } return path; } -} +} \ No newline at end of file diff --git a/app/src/main/java/com/arialyy/simple/widget/HorizontalProgressBarWithNumber.java b/app/src/main/java/com/arialyy/simple/widget/HorizontalProgressBarWithNumber.java index 2d0473ed..6ea5eee5 100644 --- a/app/src/main/java/com/arialyy/simple/widget/HorizontalProgressBarWithNumber.java +++ b/app/src/main/java/com/arialyy/simple/widget/HorizontalProgressBarWithNumber.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.simple.widget; import android.content.Context; diff --git a/downloadutil/jcenter.gradle b/downloadutil/jcenter.gradle index 7558784b..faba7984 100644 --- a/downloadutil/jcenter.gradle +++ b/downloadutil/jcenter.gradle @@ -3,8 +3,9 @@ version = PROJ_VERSION project.archivesBaseName = PROJ_ARTIFACT_ID apply plugin: 'com.jfrog.bintray' apply plugin: 'com.github.dcendents.android-maven' -//输入:gradlew bintrayupload 执行 +//输入:gradlew install 执行 +//############################## jar、sources、doc 打包 start ####################################### task sourcesJar(type: Jar) { from android.sourceSets.main.java.srcDirs classifier = 'sources' @@ -70,7 +71,9 @@ artifacts { archives javadocJar archives sourcesJar } +//############################## jar、sources、doc 打包 end ####################################### +//################################# jcenter 上传配置 start ######################################### bintray { user = hasProperty("bintrayUser") ? getProperty("bintrayUser") : getProperty("BINTRAY_USER") key = hasProperty("bintrayKey") ? getProperty("bintrayKey") : getProperty("BINTRAY_KEY") @@ -99,6 +102,7 @@ bintray { } } +//上传:gradlew install install { repositories.mavenInstaller { // This generates POM.xml with proper parameters @@ -135,4 +139,5 @@ install { } } } -} \ No newline at end of file +} +//################################# jcenter 上传配置 end ######################################### \ No newline at end of file diff --git a/downloadutil/src/androidTest/java/com/arialyy/downloadutil/ApplicationTest.java b/downloadutil/src/androidTest/java/com/arialyy/downloadutil/ApplicationTest.java index 45a9dd38..03b49432 100644 --- a/downloadutil/src/androidTest/java/com/arialyy/downloadutil/ApplicationTest.java +++ b/downloadutil/src/androidTest/java/com/arialyy/downloadutil/ApplicationTest.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil; import android.app.Application; diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/DownloadEntity.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/DownloadEntity.java index 057007bd..b466340e 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/DownloadEntity.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/DownloadEntity.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core; import android.os.Parcel; diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/DownloadManager.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/DownloadManager.java index 117857a4..07f3acd4 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/DownloadManager.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/DownloadManager.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core; import android.app.Application; @@ -149,4 +166,4 @@ public class DownloadManager { public void setDownloadQueue(ITaskQueue queue) { mTaskQueue = queue; } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/AddCmd.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/AddCmd.java index ec83044a..481d628f 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/AddCmd.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/AddCmd.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.command; import android.util.Log; @@ -22,4 +39,4 @@ class AddCmd extends IDownloadCmd { Log.w(TAG, "添加命令执行失败,【该任务已经存在】"); } } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/CancelCmd.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/CancelCmd.java index 3b7244e9..c5835328 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/CancelCmd.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/CancelCmd.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.command; import com.arialyy.downloadutil.core.DownloadEntity; @@ -22,4 +39,4 @@ class CancelCmd extends IDownloadCmd { mQueue.cancelTask(task); } } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/CmdFactory.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/CmdFactory.java index 5674dde0..1dd58af9 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/CmdFactory.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/CmdFactory.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.command; import com.arialyy.downloadutil.core.DownloadEntity; @@ -100,4 +117,4 @@ public class CmdFactory { private CancelCmd createCancelCmd(DownloadEntity entity) { return new CancelCmd(entity); } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/IDownloadCmd.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/IDownloadCmd.java index 435b06e5..3b0f3d50 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/IDownloadCmd.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/IDownloadCmd.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.command; import com.arialyy.downloadutil.core.DownloadEntity; @@ -31,4 +48,4 @@ public abstract class IDownloadCmd { * 执行命令 */ public abstract void executeCmd(); -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/StartCmd.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/StartCmd.java index 6e4d5acf..1bde6c2b 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/StartCmd.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/StartCmd.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.command; import com.arialyy.downloadutil.core.DownloadEntity; @@ -22,4 +39,4 @@ class StartCmd extends IDownloadCmd { mQueue.startTask(task); } } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/StopCmd.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/StopCmd.java index d8dc9e74..e6a4fb2b 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/StopCmd.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/command/StopCmd.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.command; import android.util.Log; diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/DownloadTaskQueue.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/DownloadTaskQueue.java index e2765cf9..04e66c8b 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/DownloadTaskQueue.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/DownloadTaskQueue.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.queue; import android.content.Context; @@ -156,4 +173,4 @@ public class DownloadTaskQueue implements ITaskQueue { return queue; } } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/IDownloader.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/IDownloader.java index cb56cdff..6e121159 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/IDownloader.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/IDownloader.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.queue; import com.arialyy.downloadutil.core.task.Task; @@ -34,4 +51,4 @@ public interface IDownloader { * @param task {@link Task} */ public void reTryStart(Task task); -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/IPool.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/IPool.java index 2ebfce19..3fa6eaaf 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/IPool.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/IPool.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.queue; import com.arialyy.downloadutil.core.task.Task; @@ -49,4 +66,4 @@ public interface IPool { * @return 返回缓存池或者当前任务池大小 */ public int size(); -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/ITaskQueue.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/ITaskQueue.java index 8f6824b3..0b832433 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/ITaskQueue.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/ITaskQueue.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.queue; import com.arialyy.downloadutil.core.DownloadEntity; @@ -53,4 +70,4 @@ public interface ITaskQueue extends IDownloader { * @param schedulers 下载调度器{@link IDownloadSchedulers} */ public void setScheduler(IDownloadSchedulers schedulers); -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/pool/CachePool.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/pool/CachePool.java index 45f1610e..d154141e 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/pool/CachePool.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/pool/CachePool.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.queue.pool; import android.text.TextUtils; @@ -107,4 +124,4 @@ public class CachePool implements IPool { @Override public int size() { return mCacheQueue.size(); } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/pool/ExecutePool.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/pool/ExecutePool.java index eb45ba64..a94825c2 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/pool/ExecutePool.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/queue/pool/ExecutePool.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.queue.pool; import android.text.TextUtils; @@ -167,4 +184,4 @@ public class ExecutePool implements IPool { @Override public int size() { return mExecuteQueue.size(); } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/scheduler/DownloadSchedulers.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/scheduler/DownloadSchedulers.java index a7b98158..9737b495 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/scheduler/DownloadSchedulers.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/scheduler/DownloadSchedulers.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.scheduler; import android.os.Message; @@ -194,4 +211,4 @@ public class DownloadSchedulers implements IDownloadSchedulers { */ public void onTaskComplete(Task task); } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/scheduler/IDownloadSchedulers.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/scheduler/IDownloadSchedulers.java index e2a14e38..c3d08716 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/scheduler/IDownloadSchedulers.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/scheduler/IDownloadSchedulers.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.scheduler; import android.os.Handler; @@ -22,4 +39,4 @@ public interface IDownloadSchedulers extends Handler.Callback { * @param entity 通过Handler传递的下载实体 */ public void startNextTask(DownloadEntity entity); -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/DownloadListener.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/DownloadListener.java index 53b0193b..b58d8246 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/DownloadListener.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/DownloadListener.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.task; class DownloadListener implements IDownloadListener { diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/DownloadUtil.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/DownloadUtil.java index 630e2abb..e4667f92 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/DownloadUtil.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/DownloadUtil.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.task; import android.content.Context; diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/IDownloadListener.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/IDownloadListener.java index 54a9dc26..c613cd0c 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/IDownloadListener.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/IDownloadListener.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.task; /** diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/IDownloadUtil.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/IDownloadUtil.java index 91d3b472..60ab112f 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/IDownloadUtil.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/IDownloadUtil.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.task; /** @@ -47,4 +64,4 @@ public interface IDownloadUtil { * 删除temp文件 */ public void delTempFile(); -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/Task.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/Task.java index c3e4aab0..dfdc1b0d 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/Task.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/Task.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.task; import android.content.Context; @@ -289,4 +306,4 @@ public class Task { context.sendBroadcast(intent); } } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/TaskFactory.java b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/TaskFactory.java index 187a9dee..02f03146 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/TaskFactory.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/core/task/TaskFactory.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.core.task; import android.content.Context; @@ -38,4 +55,4 @@ public class TaskFactory { builder.setOutHandler(schedulers); return builder.build(); } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/DbEntity.java b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/DbEntity.java index 5fb90e2e..05167d9d 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/DbEntity.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/DbEntity.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.orm; import android.support.annotation.NonNull; @@ -138,4 +155,4 @@ public class DbEntity { e.printStackTrace(); } } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/DbUtil.java b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/DbUtil.java index 890ad662..7bb3b4a3 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/DbUtil.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/DbUtil.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.orm; import android.app.Application; diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/Id.java b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/Id.java index 049642a9..10cf8dec 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/Id.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/Id.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.orm; import java.lang.annotation.ElementType; @@ -11,4 +28,4 @@ import java.lang.annotation.Target; */ @Target(ElementType.FIELD) @Retention(RetentionPolicy.RUNTIME) public @interface Id { int value() default -1; -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/Ignore.java b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/Ignore.java index 443690d6..b44d0632 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/Ignore.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/Ignore.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.orm; import java.lang.annotation.ElementType; @@ -11,4 +28,4 @@ import java.lang.annotation.Target; */ @Target(ElementType.FIELD) @Retention(RetentionPolicy.RUNTIME) public @interface Ignore { boolean value() default true; -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/SqlHelper.java b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/SqlHelper.java index 73b4b9bd..4fd49949 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/orm/SqlHelper.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/orm/SqlHelper.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.orm; import android.content.Context; @@ -33,4 +50,4 @@ public class SqlHelper extends SQLiteOpenHelper { @Override public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) { } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/util/CheckUtil.java b/downloadutil/src/main/java/com/arialyy/downloadutil/util/CheckUtil.java index e2f85b9c..8cd11d57 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/util/CheckUtil.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/util/CheckUtil.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.util; import android.content.res.Resources; @@ -46,4 +63,4 @@ public class CheckUtil { } return true; } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/util/CommonUtil.java b/downloadutil/src/main/java/com/arialyy/downloadutil/util/CommonUtil.java index 0d0f951a..35ad3cb7 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/util/CommonUtil.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/util/CommonUtil.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.util; import android.util.Log; @@ -272,4 +289,4 @@ public class CommonUtil { } } } -} +} \ No newline at end of file diff --git a/downloadutil/src/main/java/com/arialyy/downloadutil/util/PathUtil.java b/downloadutil/src/main/java/com/arialyy/downloadutil/util/PathUtil.java index 262146ef..911fe845 100644 --- a/downloadutil/src/main/java/com/arialyy/downloadutil/util/PathUtil.java +++ b/downloadutil/src/main/java/com/arialyy/downloadutil/util/PathUtil.java @@ -1,3 +1,20 @@ +/* + * Copyright (C) 2016 AriaLyy(DownloadUtil) + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + + package com.arialyy.downloadutil.util; import android.os.Environment; @@ -51,4 +68,4 @@ public class PathUtil { } return stringBuilder.toString(); } -} +} \ No newline at end of file