关于AndroidStudio的AsyncHttpClient的编译问题

初学安卓使用了 AsyncHttpClient 的包,对照的是黑马程序员的《Android移动开发案例教程》的案例写的。但是编译时遇到了意想不到的问题,国内外搜索引擎都搜索过了,但是都没有找到类似的情况,有没有大神帮忙看看

关于AndroidStudio的AsyncHttpClient的编译问题

报错代码如下:

E/AndroidRuntime: FATAL EXCEPTION: main
    Process: com.example.anew, PID: 16687
    java.lang.VerifyError: Verifier rejected class com.loopj.android.http.AsyncHttpClient: org.apache.http.client.HttpClient com.loopj.android.http.AsyncHttpClient.getHttpClient() failed to verify: org.apache.http.client.HttpClient com.loopj.android.http.AsyncHttpClient.getHttpClient(): [0x2]  can't resolve returned type 'Unresolved Reference: org.apache.http.client.HttpClient' or 'Unresolved Reference: org.apache.http.impl.client.DefaultHttpClient' (declaration of 'com.loopj.android.http.AsyncHttpClient' appears in /data/app/~~xM1ELfPEwCvtHUE4wqLf6Q==/com.example.anew-JpslhCGbgi5bmZFmC7wlrw==/base.apk)
        at com.example.anew.MainActivity.fillData(MainActivity.java:44)
        at com.example.anew.MainActivity.onCreate(MainActivity.java:35)
        at android.app.Activity.performCreate(Activity.java:8000)
        at android.app.Activity.performCreate(Activity.java:7984)
        at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1309)
        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3422)
        at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3601)
        at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:85)
        at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
        at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2066)
        at android.os.Handler.dispatchMessage(Handler.java:106)
        at android.os.Looper.loop(Looper.java:223)
        at android.app.ActivityThread.main(ActivityThread.java:7656)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:592)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:947)

 

上一篇:Adnroid中的Main()函数所在


下一篇:ActivityThread和ApplicationThread