What is "gson"

Gson 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 for an equivalent Java object . Gson can work with arbitrary Java objects including pre-existing objects that you don’t have the source code.

Some characteristics:

  • Provide a simple interface to read and export in JSON format.
  • Allow pre-existing and unmodified objects to be converted to and from JSON.
  • Support for Java Generics.
  • Custom representation of objects.
  • Support for complex types of objects.

Link to official page: Link