public class SocialJSONDecodingSupport extends Object
| Constructor and Description |
|---|
SocialJSONDecodingSupport() |
| Modifier and Type | Method and Description |
|---|---|
static <T extends Model> |
JSONArrayObjectParser(Class<T> clazz,
org.apache.http.HttpResponse response) |
static <T extends Model> |
JSONArrayObjectParser(Class<T> clazz,
String jsonArrayContent) |
static <T extends Model> |
parser(Class<T> clazz,
org.apache.http.HttpResponse response)
Parse JSON text into java Model object from the input source.
|
static <T extends Model> |
parser(Class<T> clazz,
String jsonContent)
Parse JSON text into java Model object from the input source.
|
static Map |
parser(org.apache.http.HttpResponse response)
HttpResponse text into java Map object from the input source.
|
static Map |
parser(String jsonContent)
Parse JSON text into java Map object from the input source.
|
public static <T extends Model> T parser(Class<T> clazz, String jsonContent) throws org.json.simple.parser.ParseException
T - Generic type must extend from Model.clazz - Class type.jsonContent - Json content which you need to create the Modelorg.json.simple.parser.ParseException - Throw this exception if anypublic static <T extends Model> T parser(Class<T> clazz, org.apache.http.HttpResponse response) throws IOException, org.json.simple.parser.ParseException
T - Generic type must extend from Model.clazz - Class type.response - HttpResponse which getting the JSONContent.org.json.simple.parser.ParseException - Throw this exception if anyIOException - Throw this exception if anypublic static Map parser(String jsonContent) throws org.json.simple.parser.ParseException
jsonContent - Json content which you need to create the Modelorg.json.simple.parser.ParseException - Throw this exception if anypublic static Map parser(org.apache.http.HttpResponse response) throws org.json.simple.parser.ParseException
response - HttpResponse to get the content.org.json.simple.parser.ParseException - Throw this exception if anypublic static <T extends Model> List<T> JSONArrayObjectParser(Class<T> clazz, org.apache.http.HttpResponse response) throws IOException, org.json.simple.parser.ParseException
T - clazz - response - IOExceptionorg.json.simple.parser.ParseExceptionpublic static <T extends Model> List<T> JSONArrayObjectParser(Class<T> clazz, String jsonArrayContent) throws IOException, org.json.simple.parser.ParseException
T - clazz - jsonArrayContent - IOExceptionorg.json.simple.parser.ParseExceptionCopyright © 2011–2016 eXo Platform SAS. All rights reserved.