我正在尝试使用以下lib:
implementation 'com.github.javadev:underscore:1.38'
但这给了我以下错误:
java.lang.RuntimeException: An error occurred while executing doInBackground()
at android.os.AsyncTask$3.done(AsyncTask.java:318)
at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:354)
at java.util.concurrent.FutureTask.setException(FutureTask.java:223)
at java.util.concurrent.FutureTask.run(FutureTask.java:242)
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:243)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1133)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:607)
at java.lang.Thread.run(Thread.java:761)
Caused by: java.lang.IllegalArgumentException: javax.xml.parsers.ParserConfigurationException: http://apache.org/xml/features/nonvalidating/load-external-dtd
at com.github.underscore.lodash.Xml.fromXml(Xml.java:1170)
at com.github.underscore.lodash.U.xmlToJson(U.java:1837)
at com.github.underscore.lodash.U.xmlToJson(U.java:1845)
at com.widgettwitter.tv.ListWidgetViewsFactory$Html.doInBackground
我尝试转换的文件非常繁琐: Link
我也尝试过:implementation 'org.json:json:20180813'
但这只会给我普通lib org.json.
有什么建议吗? 您能告诉我,我不知道一个允许您执行此操作的库吗?