public final class FastJsonUtil extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
static <T> List<T> |
parseList(String text,
Class<T> clazz)
Json 字符串 转对象
|
static <T> T |
parseObject(String text,
Class<T> clazz,
com.alibaba.fastjson.parser.Feature... features)
Json 字符串 转对象
|
static String |
toJSONString(Object object,
com.alibaba.fastjson.serializer.SerializerFeature... features)
对象转Json字符串
|
static String |
toJSONStringWithDateFormat(Object object,
String dateFormat,
com.alibaba.fastjson.serializer.SerializerFeature... features)
对象转Json字符串
|
static String |
toPrettyJSONString(Object object)
对象转Json字符串 漂亮的格式
不同接口通信 不要调用此方法.会加入多余的换行,导致下游系统无法解析 |
public static final String toPrettyJSONString(Object object)
object - public static final String toJSONString(Object object, com.alibaba.fastjson.serializer.SerializerFeature... features)
object - features - public static final String toJSONStringWithDateFormat(Object object, String dateFormat, com.alibaba.fastjson.serializer.SerializerFeature... features)
object - dateFormat - features - public static final <T> T parseObject(String text, Class<T> clazz, com.alibaba.fastjson.parser.Feature... features)
text - clazz - features - Copyright © 2018. All rights reserved.