瀏覽代碼

更新文档注释

drake 4 年之前
父節點
當前提交
d888bf2380
共有 1 個文件被更改,包括 3 次插入0 次删除
  1. 3 0
      net/src/main/java/com/drake/net/utils/FileUtils.kt

+ 3 - 0
net/src/main/java/com/drake/net/utils/FileUtils.kt

@@ -65,7 +65,10 @@ fun File.toRequestBody(contentType: MediaType? = null): RequestBody {
 
 /**
  * 安装APK
+ * @throws IllegalArgumentException 文件不存在或非apk后缀
+ * @throws UnsupportedOperationException 系统不存在包管理器
  */
+@Throws(IllegalArgumentException::class, UnsupportedOperationException::class)
 fun File.install() {
     val context = NetConfig.app