From bdaec74748b389c076efa8ed1020266adc763e8a Mon Sep 17 00:00:00 2001 From: gedoor Date: Mon, 13 Dec 2021 13:45:53 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/main/java/io/legado/app/help/JsExtensions.kt | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/app/src/main/java/io/legado/app/help/JsExtensions.kt b/app/src/main/java/io/legado/app/help/JsExtensions.kt index 0897a5989..90ec06c55 100644 --- a/app/src/main/java/io/legado/app/help/JsExtensions.kt +++ b/app/src/main/java/io/legado/app/help/JsExtensions.kt @@ -490,6 +490,17 @@ interface JsExtensions { return msg } + /** + * 输出对象类型 + */ + fun logType(any: Any?) { + if (any == null) { + log("null") + } else { + log(any.javaClass.name) + } + } + /** * 生成UUID */