问题
I m implementing an asynchronous HTTP server in Android. I am using the code from link http://hc.apache.org/httpcomponents-core-ga/examples.html (Asynchronous HTTP server).. While compiling it I am getting the following error and application crashes:
java.lang.IncompatibleClassChangeError:org.apache.http.params.SyncBasicHttpParams
in the line
HttpParams params = new SyncBasicHttpParams();
Please let me know the cause and how to resolve it?
I am using the jars from httpcomponents-core-4.3-alpha1.

Thank you!
回答1:
There might be a beginning of answer on this thread : What version of Apache HTTP Client is bundled in Android 1.6?
Indeed the error you get states that the SyncBasicHttpParams class you use is not compatible with the HttpParams class shipped in android. You should try to downgrade your apache libs to 4.0.X as indicated in the thread.
来源:https://stackoverflow.com/questions/13910895/asynchronous-http-server-in-android