Преглед на файлове

新增[fastest]函数来实现并发请求返回最快的请求结果, 更新License, 更新BRV版本

drake преди 4 години
родител
ревизия
4631d80550
променени са 100 файла, в които са добавени 366 реда и са изтрити 266 реда
  1. 4 3
      README.md
  2. 18 2
      build.gradle
  3. 2 0
      docs/api/net/alltypes/index.md
  4. 4 1
      docs/api/net/com.drake.net.utils/-saved-view-model/-init-.md
  5. 3 1
      docs/api/net/com.drake.net.utils/-saved-view-model/index.md
  6. 1 1
      docs/api/net/com.drake.net.utils/android.database.-cursor/foreach.md
  7. 1 1
      docs/api/net/com.drake.net.utils/android.database.-cursor/index.md
  8. 4 1
      docs/api/net/com.drake.net.utils/androidx.fragment.app.-fragment-activity/get-saved-model.md
  9. 1 1
      docs/api/net/com.drake.net.utils/androidx.fragment.app.-fragment-activity/index.md
  10. 4 1
      docs/api/net/com.drake.net.utils/androidx.fragment.app.-fragment/get-saved-model.md
  11. 1 1
      docs/api/net/com.drake.net.utils/androidx.fragment.app.-fragment/index.md
  12. 1 1
      docs/api/net/com.drake.net.utils/androidx.lifecycle.-lifecycle-owner/index.md
  13. 1 1
      docs/api/net/com.drake.net.utils/androidx.lifecycle.-lifecycle-owner/observe.md
  14. 4 1
      docs/api/net/com.drake.net.utils/androidx.lifecycle.-view-model-store-owner/get-view-model.md
  15. 1 1
      docs/api/net/com.drake.net.utils/androidx.lifecycle.-view-model-store-owner/index.md
  16. 1 1
      docs/api/net/com.drake.net.utils/index.md
  17. 2 2
      docs/api/net/com.drake.net/-net-config/host.md
  18. 1 1
      docs/api/net/com.drake.net/-net-config/index.md
  19. 2 2
      docs/api/net/com.drake.net/index.md
  20. 5 5
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-delete.md
  21. 2 2
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-download-body.md
  22. 2 2
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-download.md
  23. 5 5
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-get.md
  24. 5 5
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-head.md
  25. 5 5
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-options.md
  26. 5 5
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-patch.md
  27. 5 5
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-post.md
  28. 5 5
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-put.md
  29. 5 5
      docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-trace.md
  30. 5 5
      docs/api/net/com.drake.net/sync-delete.md
  31. 6 6
      docs/api/net/com.drake.net/sync-download-body.md
  32. 6 6
      docs/api/net/com.drake.net/sync-download.md
  33. 5 5
      docs/api/net/com.drake.net/sync-get.md
  34. 5 5
      docs/api/net/com.drake.net/sync-head.md
  35. 5 5
      docs/api/net/com.drake.net/sync-options.md
  36. 5 5
      docs/api/net/com.drake.net/sync-patch.md
  37. 5 5
      docs/api/net/com.drake.net/sync-post.md
  38. 5 5
      docs/api/net/com.drake.net/sync-put.md
  39. 5 5
      docs/api/net/com.drake.net/sync-trace.md
  40. 1 1
      docs/config.md
  41. 25 0
      docs/fast-select.md
  42. 14 20
      docs/material/partials/footer.html
  43. 1 1
      docs/scope.md
  44. 15 0
      gradle.properties
  45. 15 0
      gradle/wrapper/gradle-wrapper.properties
  46. 16 0
      kalle/build.gradle
  47. 14 14
      kalle/src/main/AndroidManifest.xml
  48. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/BaseContent.java
  49. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/Binary.java
  50. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/BodyRequest.java
  51. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/Canceller.kt
  52. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/Content.java
  53. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/FileBinary.java
  54. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/FileBody.java
  55. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/FormBody.java
  56. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/Headers.java
  57. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/JsonBody.java
  58. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/Kalle.java
  59. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/KalleConfig.java
  60. 6 5
      kalle/src/main/java/com/yanzhenjie/kalle/NetCancel.kt
  61. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/Params.java
  62. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/ProgressBar.java
  63. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/Request.java
  64. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/RequestBody.java
  65. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/RequestMethod.java
  66. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/Response.java
  67. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/ResponseBody.java
  68. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/StringBody.java
  69. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/Url.java
  70. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/UrlBody.java
  71. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/UrlRequest.java
  72. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/XmlBody.java
  73. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/BroadcastNetwork.java
  74. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/ConnectFactory.java
  75. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/Connection.java
  76. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/Interceptor.java
  77. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/Network.java
  78. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/NetworkChecker.java
  79. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/RealTimeNetwork.java
  80. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/StreamBody.java
  81. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/http/AppChain.java
  82. 5 4
      kalle/src/main/java/com/yanzhenjie/kalle/connect/http/Call.java
  83. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/http/Chain.java
  84. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/http/ConnectInterceptor.java
  85. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/http/LoggerInterceptor.java
  86. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/http/RedirectInterceptor.java
  87. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/http/RetryInterceptor.java
  88. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/stream/NullStream.java
  89. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/connect/stream/SourceStream.java
  90. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/cookie/Cookie.java
  91. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/cookie/CookieManager.java
  92. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/cookie/CookieStore.java
  93. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/cookie/DBCookieStore.java
  94. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/cookie/db/CookieDao.java
  95. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/cookie/db/Field.java
  96. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/cookie/db/SQLHelper.java
  97. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/cookie/db/Where.java
  98. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/download/BasicWorker.java
  99. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/download/BodyDownload.java
  100. 2 2
      kalle/src/main/java/com/yanzhenjie/kalle/download/BodyWorker.java

+ 4 - 3
README.md

@@ -23,7 +23,7 @@ Android上 最强网络任务库, 创新式的网络请求库(针对[Kalle](http
 
 
 
-Net 1.0+ 版本为RxJava实现
+Net 1.0+ 版本为RxJava实现 <br>
 Net 2.0+ 版本开始引入Kotlin协程特性, 开发者无需掌握协程也可以使用
 
 
@@ -54,6 +54,7 @@ Net 2.0+ 版本开始引入Kotlin协程特性, 开发者无需掌握协程也可
 - 自动处理加载对话框
 - 协程作用域支持错误和结束回调
 - 支持先强制读取缓存后网络请求二次刷新
+- 多个并发请求返回最快请求结果
 - 附带超强轮循器
 
 
@@ -101,9 +102,9 @@ implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.3.0'
 implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.3.0'
 
 // 支持自动下拉刷新和缺省页的(可选)
-implementation 'com.github.liangjingkanji:BRV:1.3.6'
+implementation 'com.github.liangjingkanji:BRV:1.3.8'
 
-implementation 'com.github.liangjingkanji:Net:2.2.7'
+implementation 'com.github.liangjingkanji:Net:2.2.8'
 ```
 
 <br>

+ 18 - 2
build.gradle

@@ -1,10 +1,26 @@
+/*
+ * Copyright (C) 2018 Drake, Inc.
+ *
+ * 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.
+ */
+
 // Top-level build file where you can add configuration options common to all sub-projects/modules.
 
 buildscript {
     ext {
         kotlin_version = '1.4.0'
-        brv_version = '1.3.6'
-        coroutine_version = '1.3.0'
+        brv_version = '1.3.8'
+        coroutine_version = '1.3.7'
         glide_version = '4.9.0'
         room_version = "2.2.5"
     }

+ 2 - 0
docs/api/net/alltypes/index.md

@@ -159,6 +159,8 @@ Created by Zhenjie Yan on 2016/10/15.
 
 ##### [com.drake.net.utils.SavedViewModel](../com.drake.net.utils/-saved-view-model/index.md)
 
+继承这个类可以快速创建具备saveInstance的ViewModel
+
 
 |
 

+ 4 - 1
docs/api/net/com.drake.net.utils/-saved-view-model/-init-.md

@@ -2,4 +2,7 @@
 
 # &lt;init&gt;
 
-`SavedViewModel(saved: SavedStateHandle)`
+`SavedViewModel(saved: SavedStateHandle)`
+
+继承这个类可以快速创建具备saveInstance的ViewModel
+

+ 3 - 1
docs/api/net/com.drake.net.utils/-saved-view-model/index.md

@@ -4,11 +4,13 @@
 
 `open class SavedViewModel : ViewModel`
 
+继承这个类可以快速创建具备saveInstance的ViewModel
+
 ### Constructors
 
 | Name | Summary |
 |---|---|
-| [&lt;init&gt;](-init-.md) | `SavedViewModel(saved: SavedStateHandle)` |
+| [&lt;init&gt;](-init-.md) | 继承这个类可以快速创建具备saveInstance的ViewModel`SavedViewModel(saved: SavedStateHandle)` |
 
 ### Properties
 

+ 1 - 1
docs/api/net/com.drake.net.utils/android.database.-cursor/foreach.md

@@ -4,5 +4,5 @@
 
 `fun `[`Cursor`](https://developer.android.com/reference/android/database/Cursor.html)`.foreach(block: `[`Cursor`](https://developer.android.com/reference/android/database/Cursor.html)`.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
 
-迭代Cursor
+方便迭代Cursor, 针对数据库的便携函数
 

+ 1 - 1
docs/api/net/com.drake.net.utils/android.database.-cursor/index.md

@@ -4,4 +4,4 @@
 
 | Name | Summary |
 |---|---|
-| [foreach](foreach.md) | 迭代Cursor`fun `[`Cursor`](https://developer.android.com/reference/android/database/Cursor.html)`.foreach(block: `[`Cursor`](https://developer.android.com/reference/android/database/Cursor.html)`.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
+| [foreach](foreach.md) | 方便迭代Cursor, 针对数据库的便携函数`fun `[`Cursor`](https://developer.android.com/reference/android/database/Cursor.html)`.foreach(block: `[`Cursor`](https://developer.android.com/reference/android/database/Cursor.html)`.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |

+ 4 - 1
docs/api/net/com.drake.net.utils/androidx.fragment.app.-fragment-activity/get-saved-model.md

@@ -2,4 +2,7 @@
 
 # getSavedModel
 
-`fun <reified M : ViewModel> FragmentActivity.getSavedModel(): M`
+`fun <reified M : ViewModel> FragmentActivity.getSavedModel(): M`
+
+返回当前组件指定的SavedViewModel
+

+ 1 - 1
docs/api/net/com.drake.net.utils/androidx.fragment.app.-fragment-activity/index.md

@@ -4,5 +4,5 @@
 
 | Name | Summary |
 |---|---|
-| [getSavedModel](get-saved-model.md) | `fun <M : ViewModel> FragmentActivity.getSavedModel(): M` |
+| [getSavedModel](get-saved-model.md) | 返回当前组件指定的SavedViewModel`fun <M : ViewModel> FragmentActivity.getSavedModel(): M` |
 | [scopeDialog](scope-dialog.md) | 作用域开始时自动显示加载对话框, 结束时自动关闭加载对话框 可以设置全局对话框 [com.drake.net.NetConfig.onDialog](../../com.drake.net/-net-config/on-dialog.md)`fun FragmentActivity.scopeDialog(dialog: `[`Dialog`](https://developer.android.com/reference/android/app/Dialog.html)`? = null, cancelable: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = true, block: suspend CoroutineScope.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`NetCoroutineScope`](../../com.drake.net.scope/-net-coroutine-scope/index.md) |

+ 4 - 1
docs/api/net/com.drake.net.utils/androidx.fragment.app.-fragment/get-saved-model.md

@@ -2,4 +2,7 @@
 
 # getSavedModel
 
-`fun <reified M : ViewModel> Fragment.getSavedModel(): M`
+`fun <reified M : ViewModel> Fragment.getSavedModel(): M`
+
+返回当前组件指定的SavedViewModel
+

+ 1 - 1
docs/api/net/com.drake.net.utils/androidx.fragment.app.-fragment/index.md

@@ -4,7 +4,7 @@
 
 | Name | Summary |
 |---|---|
-| [getSavedModel](get-saved-model.md) | `fun <M : ViewModel> Fragment.getSavedModel(): M` |
+| [getSavedModel](get-saved-model.md) | 返回当前组件指定的SavedViewModel`fun <M : ViewModel> Fragment.getSavedModel(): M` |
 | [scopeDialog](scope-dialog.md) | `fun Fragment.scopeDialog(dialog: `[`Dialog`](https://developer.android.com/reference/android/app/Dialog.html)`? = null, cancelable: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = true, block: suspend CoroutineScope.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`NetCoroutineScope`](../../com.drake.net.scope/-net-coroutine-scope/index.md) |
 | [scopeLife](scope-life.md) | `fun Fragment.scopeLife(lifeEvent: Event = Lifecycle.Event.ON_STOP, block: suspend CoroutineScope.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`AndroidScope`](../../com.drake.net.scope/-android-scope/index.md) |
 | [scopeNetLife](scope-net-life.md) | Fragment应当在[Lifecycle.Event.ON_STOP](#)时就取消作用域, 避免[Fragment.onDestroyView](#)导致引用空视图`fun Fragment.scopeNetLife(lifeEvent: Event = Lifecycle.Event.ON_STOP, block: suspend CoroutineScope.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`NetCoroutineScope`](../../com.drake.net.scope/-net-coroutine-scope/index.md) |

+ 1 - 1
docs/api/net/com.drake.net.utils/androidx.lifecycle.-lifecycle-owner/index.md

@@ -4,6 +4,6 @@
 
 | Name | Summary |
 |---|---|
-| [observe](observe.md) | 观察LiveData`fun <M> LifecycleOwner.observe(liveData: LiveData<M>?, block: M?.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
+| [observe](observe.md) | 快速创建LiveData的观察者`fun <M> LifecycleOwner.observe(liveData: LiveData<M>?, block: M?.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
 | [scopeLife](scope-life.md) | `fun LifecycleOwner.scopeLife(lifeEvent: Event = Lifecycle.Event.ON_DESTROY, block: suspend CoroutineScope.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`AndroidScope`](../../com.drake.net.scope/-android-scope/index.md) |
 | [scopeNetLife](scope-net-life.md) | `fun LifecycleOwner.scopeNetLife(lifeEvent: Event = Lifecycle.Event.ON_DESTROY, block: suspend CoroutineScope.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`NetCoroutineScope`](../../com.drake.net.scope/-net-coroutine-scope/index.md) |

+ 1 - 1
docs/api/net/com.drake.net.utils/androidx.lifecycle.-lifecycle-owner/observe.md

@@ -4,5 +4,5 @@
 
 `fun <M> LifecycleOwner.observe(liveData: LiveData<M>?, block: M?.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)`): `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)
 
-观察LiveData
+快速创建LiveData的观察者
 

+ 4 - 1
docs/api/net/com.drake.net.utils/androidx.lifecycle.-view-model-store-owner/get-view-model.md

@@ -2,4 +2,7 @@
 
 # getViewModel
 
-`fun <reified M : ViewModel> ViewModelStoreOwner.getViewModel(): M`
+`fun <reified M : ViewModel> ViewModelStoreOwner.getViewModel(): M`
+
+返回当前组件指定的ViewModel
+

+ 1 - 1
docs/api/net/com.drake.net.utils/androidx.lifecycle.-view-model-store-owner/index.md

@@ -4,4 +4,4 @@
 
 | Name | Summary |
 |---|---|
-| [getViewModel](get-view-model.md) | `fun <M : ViewModel> ViewModelStoreOwner.getViewModel(): M` |
+| [getViewModel](get-view-model.md) | 返回当前组件指定的ViewModel`fun <M : ViewModel> ViewModelStoreOwner.getViewModel(): M` |

+ 1 - 1
docs/api/net/com.drake.net.utils/index.md

@@ -6,7 +6,7 @@
 
 | Name | Summary |
 |---|---|
-| [SavedViewModel](-saved-view-model/index.md) | `open class SavedViewModel : ViewModel` |
+| [SavedViewModel](-saved-view-model/index.md) | 继承这个类可以快速创建具备saveInstance的ViewModel`open class SavedViewModel : ViewModel` |
 
 ### Extensions for External Classes
 

+ 2 - 2
docs/api/net/com.drake.net/-net-config/host.md

@@ -4,8 +4,8 @@
 
 `lateinit var host: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)
 
-域名或者ip(baseUrl)
+全局的域名或者ip(baseUrl)
 
 ### Property
 
-`host` - 域名或者ip(baseUrl)
+`host` - 全局的域名或者ip(baseUrl)

+ 1 - 1
docs/api/net/com.drake.net/-net-config/index.md

@@ -11,7 +11,7 @@ Net的全局配置
 | Name | Summary |
 |---|---|
 | [app](app.md) | 全局上下文, 一般执行[initNet](../android.app.-application/init-net.md)即可, 无需手动赋值`lateinit var app: `[`Application`](https://developer.android.com/reference/android/app/Application.html) |
-| [host](host.md) | 域名或者ip(baseUrl)`lateinit var host: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) |
+| [host](host.md) | 全局的域名或者ip(baseUrl)`lateinit var host: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) |
 | [onDialog](on-dialog.md) | 全局加载框`var onDialog: `[`DialogCoroutineScope`](../../com.drake.net.scope/-dialog-coroutine-scope/index.md)`.(FragmentActivity) -> `[`Dialog`](https://developer.android.com/reference/android/app/Dialog.html) |
 | [onError](on-error.md) | 全局错误处理`var onError: `[`Throwable`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)`.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |
 | [onStateError](on-state-error.md) | 全局缺省页错误处理`var onStateError: `[`Throwable`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-throwable/index.html)`.(view: `[`View`](https://developer.android.com/reference/android/view/View.html)`) -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html) |

+ 2 - 2
docs/api/net/com.drake.net/index.md

@@ -22,8 +22,8 @@
 | Name | Summary |
 |---|---|
 | [syncDelete](sync-delete.md) | 同步网络请求`fun <M> syncDelete(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, cache: CacheMode = CacheMode.HTTP, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): M` |
-| [syncDownload](sync-download.md) | 同步文件下载(默认Get请求)`fun syncDownload(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, dir: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)` = NetConfig.app.externalCacheDir!!.absolutePath, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, method: RequestMethod = RequestMethod.GET, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) |
-| [syncDownloadBody](sync-download-body.md) | 同步文件下载, 以提交请求体方式(默认Post请求)`fun syncDownloadBody(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, dir: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)` = NetConfig.app.externalCacheDir!!.absolutePath, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, method: RequestMethod = RequestMethod.GET, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) |
+| [syncDownload](sync-download.md) | 同步文件下载, 默认Get请求`fun syncDownload(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, dir: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)` = NetConfig.app.externalCacheDir!!.absolutePath, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, method: RequestMethod = RequestMethod.GET, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) |
+| [syncDownloadBody](sync-download-body.md) | 同步文件下载, 允许提交请求体方式, 默认Post请求`fun syncDownloadBody(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, dir: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)` = NetConfig.app.externalCacheDir!!.absolutePath, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, method: RequestMethod = RequestMethod.GET, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html) |
 | [syncGet](sync-get.md) | 同步网络请求`fun <M> syncGet(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, cache: CacheMode = CacheMode.HTTP, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): M` |
 | [syncHead](sync-head.md) | 同步网络请求`fun <M> syncHead(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, cache: CacheMode = CacheMode.HTTP, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): M` |
 | [syncOptions](sync-options.md) | 同步网络请求`fun <M> syncOptions(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, cache: CacheMode = CacheMode.HTTP, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): M` |

+ 5 - 5
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-delete.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 2 - 2
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-download-body.md

@@ -8,13 +8,13 @@
 
 ### Parameters
 
-`path` - 网络路径, 非绝对路径会加上HOST[NetConfig.host](../-net-config/host.md)为前缀
+`path` - 请求路径, 非绝对路径会加上HOST[NetConfig.host](../-net-config/host.md)为前缀
 
 `method` - 请求方式, 默认GET
 
 `dir` - 下载文件存放目录 {默认存在android/data/packageName/cache目录}
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
 `absolutePath` - 下载链接是否是绝对路径
 

+ 2 - 2
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-download.md

@@ -8,13 +8,13 @@
 
 ### Parameters
 
-`path` - 网络路径, 非绝对路径会加上HOST[NetConfig.host](../-net-config/host.md)为前缀
+`path` - 请求路径, 非绝对路径会加上HOST[NetConfig.host](../-net-config/host.md)为前缀
 
 `method` - 请求方式, 默认GET
 
 `dir` - 下载文件存放目录 {默认存在android/data/packageName/cache目录}
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
 `absolutePath` - 下载链接是否是绝对路径
 

+ 5 - 5
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-get.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-head.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-options.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-patch.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-post.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-put.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/kotlinx.coroutines.-coroutine-scope/-trace.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](../-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/sync-delete.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 6 - 6
docs/api/net/com.drake.net/sync-download-body.md

@@ -4,16 +4,16 @@
 
 `fun syncDownloadBody(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, dir: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)` = NetConfig.app.externalCacheDir!!.absolutePath, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, method: RequestMethod = RequestMethod.GET, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)
 
-同步文件下载, 以提交请求体方式(默认Post请求)
+同步文件下载, 允许提交请求体方式, 默认Post请求
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 6 - 6
docs/api/net/com.drake.net/sync-download.md

@@ -4,16 +4,16 @@
 
 `fun syncDownload(path: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)`, dir: `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)` = NetConfig.app.externalCacheDir!!.absolutePath, tag: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, absolutePath: `[`Boolean`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-boolean/index.html)` = false, method: RequestMethod = RequestMethod.GET, uid: `[`Any`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-any/index.html)`? = null, block: Api.() -> `[`Unit`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-unit/index.html)` = {}): `[`String`](https://kotlinlang.org/api/latest/jvm/stdlib/kotlin/-string/index.html)
 
-同步文件下载(默认Get请求)
+同步文件下载, 默认Get请求
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/sync-get.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/sync-head.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/sync-options.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/sync-patch.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/sync-post.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/sync-put.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 5 - 5
docs/api/net/com.drake.net/sync-trace.md

@@ -8,12 +8,12 @@
 
 ### Parameters
 
-`path` - String 网络路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
+`path` - String 请求路径, 非绝对路径会加上[NetConfig.host](-net-config/host.md)为前缀
 
-`tag` - 可以传递对象给Request请求
+`tag` - 可以传递对象给Request请求, 一般用于在拦截器/转换器中进行针对某个接口行为判断
 
-`absolutePath` - Path是否是绝对路径
+`absolutePath` - 请求路径是否是绝对路径
 
-`uid` - 表示请求的唯一id
+`uid` - 表示请求的唯一id, 和[NetCancel.cancel](#)中的uid一致, 一般用于指定取消网络请求的唯一id
 
-`block` - 配置参数lambda
+`block` - 函数中可以配置请求参数

+ 1 - 1
docs/config.md

@@ -28,7 +28,7 @@ class App : Application() {
 
 initNet 作用域内可选函数
 
-<img src="https://i.imgur.com/k0aoQoK.png" width="60%"/>
+<img src="https://i.imgur.com/G8W4oDX.png" width="60%"/>
 
 ## 动态配置
 

+ 25 - 0
docs/fast-select.md

@@ -0,0 +1,25 @@
+Net支持多个接口请求并发, 仅返回最快的请求结果, 剩余请求将被自动取消, 同样可以用于筛选掉无法请求的域名
+<br>
+
+!!! note
+    接口请求错误被忽略(LogCat依然可以看到异常信息), 但如果所有请求全部异常则抛出最后一个请求的异常作为错误处理
+
+示例
+```kotlin
+scopeNetLife {
+
+    // 同时发起四个网络请求
+    val deferred = Get<String>("api0") // 错误接口
+    val deferred1 = Get<String>("api1") // 错误接口
+    val deferred2 = Get<String>("api")
+    val deferred3 = Post<String>("api")
+
+    // 只返回最快的请求结果
+    tv_fragment.text = fastSelect(deferred, deferred1, deferred2, deferred3)
+}
+```
+
+<br>
+
+!!! note
+    不要尝试使用这种方式来取代CDN加速

+ 14 - 20
docs/material/partials/footer.html

@@ -1,24 +1,18 @@
 <!--
-  Copyright (c) 2016-2020 Martin Donath <martin.donath@squidfunk.com>
-
-  Permission is hereby granted, free of charge, to any person obtaining a copy
-  of this software and associated documentation files (the "Software"), to
-  deal in the Software without restriction, including without limitation the
-  rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
-  sell copies of the Software, and to permit persons to whom the Software is
-  furnished to do so, subject to the following conditions:
-
-  The above copyright notice and this permission notice shall be included in
-  all copies or substantial portions of the Software.
-
-  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-  FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE
-  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
-  FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
-  IN THE SOFTWARE.
--->
+  ~ Copyright (C) 2018 Drake, Inc.
+  ~
+  ~ 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.
+  -->
 
 {% import "partials/language.html" as lang with context %}
 

+ 1 - 1
docs/scope.md

@@ -22,7 +22,7 @@ Net的网络请求本身支持在官方的自带的作用域内使用, 但是考
 ## 捕捉异常/执行完成
 ```kotlin
 scope {
-
+    // scope系列函数的这个大括号里面就是作用域
 }.catch {
     // 协程内部发生错误回调
 }.finally {

+ 15 - 0
gradle.properties

@@ -1,3 +1,18 @@
+#
+# Copyright (C) 2018 Drake, Inc.
+#
+# 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.
+#
 # Project-wide Gradle settings.
 # IDE (e.g. Android Studio) users:
 # Gradle settings configured through the IDE *will override*

+ 15 - 0
gradle/wrapper/gradle-wrapper.properties

@@ -1,3 +1,18 @@
+#
+# Copyright (C) 2018 Drake, Inc.
+#
+# 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.
+#
 #Mon Jun 22 01:18:38 CST 2020
 distributionBase=GRADLE_USER_HOME
 distributionPath=wrapper/dists

+ 16 - 0
kalle/build.gradle

@@ -1,3 +1,19 @@
+/*
+ * Copyright (C) 2018 Drake, Inc.
+ *
+ * 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.
+ */
+
 apply plugin: 'com.android.library'
 apply plugin: 'kotlin-android'
 apply plugin: 'kotlin-android-extensions'

+ 14 - 14
kalle/src/main/AndroidManifest.xml

@@ -1,19 +1,19 @@
 <?xml version="1.0" encoding="utf-8"?>
 <!--
-    Copyright © 2018 Zhenjie Yan.
-
-    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.
--->
+  ~ Copyright (C) 2018 Drake, Inc.
+  ~
+  ~ 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.
+  -->
 <manifest xmlns:android="http://schemas.android.com/apk/res/android"
     package="com.yanzhenjie.kalle">
 

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/BaseContent.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/Binary.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/BodyRequest.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/Canceller.kt

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/Content.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/FileBinary.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/FileBody.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/FormBody.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/Headers.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/JsonBody.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/Kalle.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/KalleConfig.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 6 - 5
kalle/src/main/java/com/yanzhenjie/kalle/NetCancel.kt

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,
@@ -21,7 +21,7 @@ object NetCancel {
     private val map = mutableMapOf<Canceller, Any>()
 
     /**
-     * Add a task to cancel.
+     * 添加一个网络请求取消者用于取消网络
      *
      * @param uid   target request.
      * @param canceller canceller.
@@ -32,7 +32,7 @@ object NetCancel {
     }
 
     /**
-     * Remove a task.
+     * 删除网络请求ID
      *
      * @param uid target request.
      */
@@ -45,8 +45,9 @@ object NetCancel {
     }
 
     /**
-     * According to the tag to cancel a task.
+     * 取消网络请求
      *
+     * @param uid 网络请求的ID
      */
     fun cancel(uid: Any?) {
         uid ?: return

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/Params.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/ProgressBar.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/Request.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/RequestBody.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/RequestMethod.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/Response.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/ResponseBody.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/StringBody.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/Url.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/UrlBody.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/UrlRequest.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/XmlBody.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/BroadcastNetwork.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/ConnectFactory.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/Connection.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/Interceptor.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/Network.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/NetworkChecker.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/RealTimeNetwork.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2019 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/StreamBody.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/http/AppChain.java

@@ -1,11 +1,11 @@
 /*
- * Copyright 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 5 - 4
kalle/src/main/java/com/yanzhenjie/kalle/connect/http/Call.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,
@@ -47,7 +47,8 @@ public class Call {
      * Execute request.
      */
     public Response execute() throws IOException {
-        if (isCanceled) throw new CancellationException("The request has been cancelled.");
+        if (isCanceled)
+            throw new CancellationException("The request has been cancelled [" + mRequest.location() + "]");
         isExecuted = true;
 
         List<Interceptor> interceptors = new ArrayList<>(Kalle.getConfig().getInterceptor());
@@ -59,7 +60,7 @@ public class Call {
             return chain.proceed(mRequest);
         } catch (Exception e) {
             if (isCanceled) {
-                throw new CancellationException("The request has been cancelled.");
+                throw new CancellationException("The request has been cancelled [" + mRequest.location() + "]");
             } else {
                 throw e;
             }

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/http/Chain.java

@@ -1,11 +1,11 @@
 /*
- * Copyright 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/http/ConnectInterceptor.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/http/LoggerInterceptor.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/http/RedirectInterceptor.java

@@ -1,11 +1,11 @@
 /*
- * Copyright 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/http/RetryInterceptor.java

@@ -1,11 +1,11 @@
 /*
- * Copyright 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/stream/NullStream.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/connect/stream/SourceStream.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/cookie/Cookie.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/cookie/CookieManager.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/cookie/CookieStore.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/cookie/DBCookieStore.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/cookie/db/CookieDao.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/cookie/db/Field.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/cookie/db/SQLHelper.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/cookie/db/Where.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/download/BasicWorker.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/download/BodyDownload.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

+ 2 - 2
kalle/src/main/java/com/yanzhenjie/kalle/download/BodyWorker.java

@@ -1,11 +1,11 @@
 /*
- * Copyright © 2018 Zhenjie Yan.
+ * Copyright (C) 2018 Drake, Inc.
  *
  * 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
+ * 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,

Някои файлове не бяха показани, защото твърде много файлове са промени