I released Ion nearly a month ago, and completely forgot to blog about it. Whoops.

Ion is a general purpose networking library. Whether it is JSON, Strings, Files, Images (into ImageViews), etc; Ion can handle it.

There were a few high level goals that I wanted to accomplish:

  • Thread management should be transparent. Automatic invocation back onto the UI thread.
  • Intuitive and flexible API.
  • Automatic http caching.
  • Activity and Service lifecycle aware. No more checking isDestroyed.
  • All operations should return Futures (which are Cancelable).

The Ion Github page has a ton of samples that are worth checking out, but here's a quick overview of the API. Suppose you want to download a http resource as a String:

Want to download JSON? Easy, just change the "asString" to "asJsonObject".

Posting JSON is also easy:

Putting an image into an ImageView follows the same mechanics.

The image API also supports ListView recycling, caching, etc. Ion is a successor to UrlImageViewHelper.

Ion's fluent API is meant to be intuitive, and easily extensible. As I mentioned, Ion offers a ton of flexibility and features. Check out the README on the Github page for more samples, as this post barely scratches the surface of what is possible. If you find a feature is missing, let me know, and I'll add it.

ION - Android Networking Made Easy<p>I released <a href="https://plus.google.com/103583939320326217147/posts/64ciSdeFaB5">Ion</a> nearly a month ago,</p><p><a href="/post/ion" title="Read more of ION - Android Networking Made Easy">read more</a></p>