Tuesday, March 22, 2011

JSON parsing on Android

innen

  1. That comes with platform (org.json) – optimized since 2.2
  2. Jackson
  3. GSON
...
  1. org.json – Not very convenient to use. Doesn’t support stream parsing out of the box.
  2. jackson – very convenient to use, excellent mapping features, custom stream deserializers… but don’t use it on Android. Like Facebook and Twitter did… This will put you into the grave:) Everything is excellent before you will take a look into the ddms log.
  3. gson – GSON stream is very nice and small. It doesn’t produce so much garbage as Jackson. But it is not so convenient to use. Good news that GSON stream parser is included in API 11.