Denial of responsibility
- I know that we should no longer use HttpClient on Android
- In API 23 we can use
useLibrary 'org.apache.http.legacy'
I would like to continue using HttpClient (I also support libraries and projects based on it), however with API 23 the classes are gone.
I didn’t go away with the useLibrary , but cannot be used for further development (classes are not autocompleted, everything is displayed as invalid code)
We also have the opportunity to use the HttpComponents provided by the Android plug-in HttpClient 4.3.5.1 , which, however, does not provide the classes / headers / interfaces that Android provides in API <22, so it compiles, but we are still unable to develop efficiently.
Is there a complete reformatting of the HttpClient library (even versions higher than 4.3 are preferable), which can be used further with target / compile-Sdk version 23?
The last full repack that I could find is https://code.google.com/p/httpclientandroidlib/ , which uses version 4.3.2
I also added a comment to the HC JIRA issue https://issues.apache.org/jira/browse/HTTPCLIENT-1632
This workaround is likely to be needed only until HttpClient 5.X is released, as it must have completely different package names.
Marek sebera
source share