| Constructor | Description |
|---|---|
AssetSerializer() |
| Modifier and Type | Method | Description |
|---|---|---|
com.google.gson.JsonElement |
serialize(Asset src,
Type typeOfSrc,
com.google.gson.JsonSerializationContext context) |
Serialize an asset object to json object
Note: given the type of the asset.data it maybe necessary to
to add a type adapter
JsonSerializer and/or JsonDeserializer with JsonUtils and
JsonUtils.addTypeAdapterSerializer(java.lang.Class, com.google.gson.JsonSerializer<?>)
TODO test user.data with custom serializer |
public com.google.gson.JsonElement serialize(Asset src, Type typeOfSrc, com.google.gson.JsonSerializationContext context)
JsonSerializer and/or JsonDeserializer with JsonUtils and
JsonUtils.addTypeAdapterSerializer(java.lang.Class, com.google.gson.JsonSerializer<?>)
TODO test user.data with custom serializerserialize in interface com.google.gson.JsonSerializer<Asset>src - object to serializetypeOfSrc - type of srccontext - the json contextCopyright © 2018. All rights reserved.