List of usage examples for com.google.gson TypeAdapter subclass-usage
From source file com.actimem.blog.gson.customtypeadapters.CompanyIdTypeAdapter.java
public class CompanyIdTypeAdapter extends TypeAdapter<CompanyId> { @Override public void write(JsonWriter out, CompanyId value) throws IOException { out.value(value.getId()); }
From source file com.actimem.blog.gson.customtypeadapters.DateTimeTypeAdapter.java
public class DateTimeTypeAdapter extends TypeAdapter<DateTime> { @Override public void write(JsonWriter out, DateTime value) throws IOException { out.value(value.toString()); }
From source file com.adobe.acs.commons.json.JcrJsonAdapter.java
/** * Type adapter to convert JCR Nodes to JSON Objects (replacement for deprecated * NodeItemWriter.) */ public class JcrJsonAdapter extends TypeAdapter<Node> {
From source file com.aelitis.azureus.util.ObjectTypeAdapterLong.java
/**
* Not Used. proguard will remove this file, or you can explicitely exclude it
*
* Adapts types whose static type is only 'Object'. Uses getClass() on
* serialization and a primitive/Map/List on deserialization.
*/
From source file com.algodefu.yeti.web.ClusterTypeAdapter.java
/** * Custom type adapter for the class Cluster. * Used by Gson to convert cluster data into Json */ public class ClusterTypeAdapter extends TypeAdapter<Cluster> {
From source file com.android.build.gradle.external.gson.PlainFileGsonTypeAdaptor.java
/** * GSon TypeAdapter that will convert between File and String. */ public class PlainFileGsonTypeAdaptor extends TypeAdapter<File> { @Override public void write(JsonWriter jsonWriter, File file) throws IOException {
From source file com.android.build.gradle.internal.gson.FileGsonTypeAdaptor.java
/** * Gson Type Adaptor for File. * * Using Gradle {@link FileResolver} to resolve relative paths. */ public class FileGsonTypeAdaptor extends TypeAdapter<File> {
From source file com.android.common.ide.common.blame.MessageJsonSerializer.java
/**
* Class to handle json serialization and deserialization of messages.
*
* Reads json objects of the form:
*
* <pre>
From source file com.android.common.ide.common.blame.SourceFileJsonTypeAdapter.java
/**
* JsonSerializer and Deserializer for {@link SourceFile}.
*
* The JsonDeserialiser accepts either a string of the file path or a json object of the form
* <pre>{
* "path":"/path/to/file.java",
From source file com.android.common.ide.common.blame.SourceFilePositionJsonSerializer.java
public class SourceFilePositionJsonSerializer extends TypeAdapter<SourceFilePosition> { private static final String POSITION = "position"; private static final String FILE = "file";