Interface GsonParser<T>
- Type Parameters:
- T- the POJO type
- All Known Implementing Classes:
- BasicParser, ListParser, MapParser
public interface GsonParser<T>
Defines a parser that deserializes a JSON-formatted source input stream to the defined POJO type.
- 
Method SummaryModifier and TypeMethodDescriptiondefault Tparse(@NonNull com.google.gson.Gson gson, byte @NonNull [] jsonContent) Deserializes a JSON-formatted byte array to the defined POJO type.parse(com.google.gson.Gson gson, InputStream jsonStream) Deserializes a JSON-formatted input stream to the defined POJO type.
- 
Method Details- 
parseDeserializes a JSON-formatted input stream to the defined POJO type.- Parameters:
- gson- the Gson instance used to deserialize the string
- jsonStream- stream with expected JSON-formatted contents
- Returns:
- the parsed POJO instance
 
- 
parsedefault T parse(@NonNull com.google.gson.Gson gson, byte @NonNull [] jsonContent) throws IOException Deserializes a JSON-formatted byte array to the defined POJO type.- Parameters:
- gson- the Gson instance used to deserialize the string
- jsonContent- the byte array
- Returns:
- the parsed POJO instance
- Throws:
- IOException
 
 
-