Created
January 6, 2017 13:37
-
-
Save agustarc/7025de634bb2bb774da1118610fc9292 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@AutoValue | |
public abstract class Product { | |
@SerializedName("id") | |
public abstract long getId(); | |
@SerializedName("name") | |
public abstract String getName(); | |
@SerializedName("price") | |
public abstract float getPrice(); | |
public static TypeAdapter<Product> typeAdapter(Gson gson) { | |
return new AutoValue_Product.GsonTypeAdapter(gson); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment