Android开源框架Asynchronous Http Client for Android

来源:互联网 发布:一组数据的标准偏差 编辑:程序博客网 时间:2024/06/05 19:42

An asynchronous, callback-based Http client for Android built on top of Apache's HttpClient libraries.

CONTRIBUTING

AsyncHttpClient is an open-source project made by developers for developers!
If you would like to contribute to the project, that's really great. You can contribute in a variety of ways:

1) Help us with test cases and examples for the Wiki
2) If you have a good idea/patch for the project, create a pull request (see PULL)
3) Found a bug? You're more than welcome to submit an issue (see ISSUES)
4) Help other fellow developers solve their problems, you're welcome to do so in issues

We do require certain guidelines to be followed so that the quality of the project remains top-notch:

1. PULL requests

When you submit a patch or a new functionality for the project, you must open a pull request. We will get to the pull request as soon as possible, investigate what functionality or bug fixes have been added and decide whether to include it in the library or not -- for the benefit of everyone.
You further agree that any contribution that you make to the library will be distributed further under the same license as the library itself (Apache v2.0).
Don't be discouraged if your pull request is rejected. This is not a deadline and sometimes with a proper explanation on your side, we are persuaded to merge in the request. Just remember that this is a library for everyone and as such must meet certain, generic rules that we would like to believe are following.

2. ISSUES

The issues system is the place to report bugs. Please do not use it to submit patches or new functionality. As helpful as we would like to be, we cannot replace the developer and we certainly do not see what you're seeing. So when you come to report an issue, please follow these simple rules:

1) Reporting bugs in English language only
2) If the issue is due to a crash, we need the stack trace -- throwable.printStackTrace() -- and any other detail that will shed light on the problem
3) We need to see the source code (minus certain details that you think are confidential) that caused the problem in the first place
4) Opening issues without providing us with the information necessary to debug and fix it is useless; so we will close such issues within 7 days period

3. CODING STANDARDS

We need you to follow certain rules when sending source code contributions. These are the basic principles that we ourselves abide to and we require that you do so too:

1) Do not use the Tab character (it's in first place for a reason)
2) Indentation is 4 spaces
3) You must provide proper Javadoc, including description, in English for both public and protected methods, classes and properties
4) Group packages that belong to the same top-level package together, followed by an empty line
5) Add an empty line after and before class/interface declarations, methods and constructors
6) Add an empty line before and after a group of properties
7) Do not catch generic Exception/Throwable errors, but always catch the most specific type of the exception/error


Features

  • Make asynchronous HTTP requests, handle responses in anonymous callbacks
  • HTTP requests happen outside the UI thread
  • Requests use a threadpool to cap concurrent resource usage
  • GET/POST params builder (RequestParams)
  • Multipart file uploads with no additional third party libraries
  • Tiny size overhead to your application, only 60kb for everything
  • Automatic smart request retries optimized for spotty mobile connections
  • Automatic gzip response decoding support for super-fast requests
  • Optional built-in response parsing into JSON (JsonHttpResponseHandler)
  • Optional persistent cookie store, saves cookies into your app's SharedPreferences

Maven

You can now integrate this library in your project via Maven. There are available two kind of builds.

development snapshots https://oss.sonatype.org/content/repositories/snapshots/com/loopj/android/android-async-http/Maven URL: https://oss.sonatype.org/content/repositories/snapshots/ GroupId: com.loopj.android ArtifactId: android-async-http Version: 1.4.5-SNAPSHOT Packaging: JAR or AAR

releases, maven central

http://central.maven.org/maven2/com/loopj/android/android-async-http/Maven URL: http://repo1.maven.org/maven2/ GroupId: com.loopj.android ArtifactId: android-async-http Version: 1.4.4 Packaging: JAR or AAR

Documentation, Features and Examples

Full details and documentation can be found on the project page here:

http://loopj.com/android-async-http/

Bitdeli Badge

0 0