List of usage examples for com.google.gson TypeAdapter subclass-usage
From source file io.datakernel.datagraph.server.GsonInetSocketAddressAdapter.java
public final class GsonInetSocketAddressAdapter extends TypeAdapter<InetSocketAddress> { @Override public InetSocketAddress read(JsonReader reader) throws IOException { if (reader.peek() == JsonToken.NULL) { reader.nextNull(); return null;
From source file io.datakernel.datagraph.server.GsonStreamIdAdapter.java
public final class GsonStreamIdAdapter extends TypeAdapter<StreamId> { @Override public StreamId read(JsonReader reader) throws IOException { if (reader.peek() == JsonToken.NULL) { reader.nextNull(); return null;
From source file io.github.rcarlosdasilva.weixin.core.json.adapter.OpenPlatformAuthGetLicenseInformationResponseTypeAdapter.java
public class OpenPlatformAuthGetLicenseInformationResponseTypeAdapter extends TypeAdapter<OpenPlatformAuthGetLicenseInformationResponse> { private static final String LOG_UNKNOWN_JSON_KEY = "json [{}: {}]"; private final Logger logger = LoggerFactory.getLogger(getClass());
From source file io.trakerr.JSON.java
/** * Gson TypeAdapter for Joda DateTime type */ class DateTimeTypeAdapter extends TypeAdapter<DateTime> { private final DateTimeFormatter formatter = ISODateTimeFormat.dateTime();
From source file io.ucoin.ucoinj.core.client.model.bma.gson.EndpointAdapter.java
public class EndpointAdapter extends TypeAdapter<NetworkPeering.Endpoint> { @Override public NetworkPeering.Endpoint read(JsonReader reader) throws IOException { if (reader.peek() == com.google.gson.stream.JsonToken.NULL) { reader.nextNull();
From source file it.units.inginf.male.outputs.gson.DoubleTypeAdapter.java
/** * DoubleTypeAdapter is a GSON adapter; this maps the NaN double value to a string and viceversa. * @author MaleLabTs */ public class DoubleTypeAdapter extends TypeAdapter<Double> {
From source file me.ixfan.wechatkit.message.out.json.MassMessageGsonTypeAdapter.java
/** * @author Warren Fan */ public class MassMessageGsonTypeAdapter extends TypeAdapter<MessageForMassSend> { @Override public void write(JsonWriter out, MessageForMassSend value) throws IOException {
From source file me.ixfan.wechatkit.message.out.template.TemplateMessageForSendGsonTypeAdapter.java
/** * @author Warren Fan */ public class TemplateMessageForSendGsonTypeAdapter extends TypeAdapter<TemplateMessageForSend> { private final String HEX_COLOR_REGEX = "^(.+)(#([a-fA-F0-9]{6}|[a-fA-F0-9]{3}))$";
From source file me.z_wave.android.utils.BooleanTypeAdapter.java
public class BooleanTypeAdapter extends TypeAdapter<Boolean> { @Override public void write(JsonWriter out, Boolean value) throws IOException { if (value == null) { out.nullValue();
From source file me.z_wave.android.utils.IntegerTypeAdapter.java
public class IntegerTypeAdapter extends TypeAdapter<Boolean> { @Override public void write(JsonWriter out, Boolean value) throws IOException { if (value == null) { out.nullValue();