java.lang.NoClassDefFoundError: Failed resolution of: Lorg/apache/http/message/BasicNameValuePair
或者html
java.lang.RuntimeException: Stub! at org.apache.http.message.BasicNameValuePair.<init>(BasicNameValuePair.java:6)
出现此问题主要是 apache 的 http 库在android 9.0删除致使的,出现此问题应该是使用了 apache 的http库。java
尽可能不要再使用httpClient来访问网络,替换成HttpURLConnection或者OKHttp。最后再说明一下:尽可能不要使用过期的库进行开发。
android
参考连接:Android 9.0/P 版本推荐使用 HttpURLConnection,弃用 Apache HTTPClientapache