Skip to content
This repository has been archived by the owner on Oct 23, 2024. It is now read-only.
温绍锦 edited this page Apr 16, 2023 · 72 revisions

English | 中文

Fastjson is a Java library that can be used to convert Java Objects into their JSON representation. It can also be used to convert a JSON string to an equivalent Java object. Fastjson can work with arbitrary Java objects including pre-existing objects that you do not have source-code of.

Fastjson Goals

  • Provide best performance in server side and android client.
  • Provide simple toJSONString() and parseObject() methods to convert Java objects to JSON and vice-versa.
  • Allow pre-existing unmodifiable objects to be converted to and from JSON.
  • Extensive support of Java Generics.
  • Allow custom representations for objects.
  • Support arbitrarily complex objects (with deep inheritance hierarchies and extensive use of generic types).

Frequently Asked Questions

https://github.com/alibaba/fastjson/wiki/%E5%B8%B8%E8%A7%81%E9%97%AE%E9%A2%98

Download

android developer plz see Here

the latest JAR

or via Maven:

<dependency>
    <groupId>com.alibaba</groupId>
    <artifactId>fastjson</artifactId>
    <version>VERSION_CODE</version>
</dependency>

or via Gradle:

compile 'com.alibaba:fastjson:VERSION_CODE'

replace VERSION_CODE with real version name such as 2.0.28 released in Here or Here or Here.

Getting started

Samples : https://github.com/alibaba/fastjson/wiki/Samples-DataBind

Integrate Fastjson in Spring

https://github.com/alibaba/fastjson/wiki/%E5%9C%A8-Spring-%E4%B8%AD%E9%9B%86%E6%88%90-Fastjson

Integrate Fastjson in JAX-RS

https://github.com/alibaba/fastjson/wiki/Integrate-Fastjson-in-JAXRS

Use Fastjson in Kotlin

https://github.com/alibaba/fastjson/wiki/Use-Fastjson-in-Kotlin

Best Practice for JSON/Fastjson

https://github.com/alibaba/fastjson/wiki/Best-Practice-for-JSON-Fastjson%EF%BC%88JSON-Fastjson%E6%9C%80%E4%BD%B3%E5%AE%9E%E8%B7%B5%EF%BC%89

Clone this wiki locally