类 GsonBuilderUtils
java.lang.Object
cn.taketoday.http.converter.json.GsonBuilderUtils
A simple utility class for obtaining a Google Gson 2.x
GsonBuilder
which Base64-encodes byte[] properties when reading and writing JSON.- 从以下版本开始:
- 4.0
- 作者:
- Juergen Hoeller, Roy Clarkson
- 另请参阅:
-
嵌套类概要
嵌套类 -
构造器概要
构造器 -
方法概要
修饰符和类型方法说明static com.google.gson.GsonBuilderObtain aGsonBuilderwhich Base64-encodesbyte[]properties when reading and writing JSON.
-
构造器详细资料
-
GsonBuilderUtils
public GsonBuilderUtils()
-
-
方法详细资料
-
gsonBuilderWithBase64EncodedByteArrays
public static com.google.gson.GsonBuilder gsonBuilderWithBase64EncodedByteArrays()Obtain aGsonBuilderwhich Base64-encodesbyte[]properties when reading and writing JSON.A custom
TypeAdapterwill be registered viaGsonBuilder.registerTypeHierarchyAdapter(Class, Object)which serializes abyte[]property to and from a Base64-encoded String instead of a JSON array.
-