public class JSONCoder extends Object
| Constructor and Description |
|---|
JSONCoder(JSONCoderOption option) |
| Modifier and Type | Method and Description |
|---|---|
<T> T |
decode(DecodeReq<T> req) |
static <T> T |
decode(DecodeReq<T> req,
JSONCoderOption opt) |
<T> T |
decode(Reader reader,
Class<T> type) |
static <T> T |
decode(Reader reader,
Class<T> type,
JSONCoderOption opt) |
<T> T |
decode(String str,
Class<T> type) |
static <T> T |
decode(String jsonStr,
Class<T> type,
JSONCoderOption opt) |
<T> T |
decode(TDNode treeDocNode,
Class<T> type) |
static <T> T |
decode(TDNode treeDocNode,
Class<T> type,
JSONCoderOption opt) |
<T> T |
decodeTo(String str,
T target) |
String |
encode(EncodeReq req) |
static String |
encode(EncodeReq req,
JSONCoderOption opt) |
String |
encode(Object obj) |
static String |
encode(Object obj,
JSONCoderOption opt) |
void |
encode(Object obj,
Writer writer) |
static void |
encode(Object obj,
Writer writer,
JSONCoderOption opt) |
public JSONCoder(JSONCoderOption option)
public static <T> T decode(DecodeReq<T> req, JSONCoderOption opt)
public static <T> T decode(String jsonStr, Class<T> type, JSONCoderOption opt)
public static <T> T decode(Reader reader, Class<T> type, JSONCoderOption opt)
public static <T> T decode(TDNode treeDocNode, Class<T> type, JSONCoderOption opt)
public <T> T decode(DecodeReq<T> req)
public <T> T decodeTo(String str, T target)
public static String encode(EncodeReq req, JSONCoderOption opt)
req - opt - public static String encode(Object obj, JSONCoderOption opt)
public static void encode(Object obj, Writer writer, JSONCoderOption opt)
Copyright © 2019. All rights reserved.