Interface Json

All Known Implementing Classes:
GsonWrapper

public interface Json
  • Method Details

    • toJson

      String toJson(Object src)
      Serialize the object into json. If the object is a generic type, use toJson(Object, Type)
    • toJson

      String toJson(Object src, Type type)
      Serialize the generic object into json. If the object is not a generic, use toJson(Object, Type)
    • fromJson

      <T> T fromJson(String json, Type type)
      Deserialize the generic object from json. If the object is not a generic type, use
      invalid reference
      #fromJson(Object, Class)
    • fromJson

      <T> T fromJson(String json, Class<T> classOfT)
      Deserialize the object from json. If the object is a generic type, use
      invalid reference
      #fromJson(Object, Type)
    • fromJson

      <T> T fromJson(InputStream json, Charset charset, Type type)
      Deserialize the generic object from json. If the object is not a generic type, use
      invalid reference
      #fromJson(Object, Class)
    • fromJson

      <T> T fromJson(InputStream json, Charset charset, Class<T> classOfT)
      Deserialize the object from json. If the object is a generic type, use
      invalid reference
      #fromJson(Object, Type)