Closed macklinu closed 8 years ago
@crebma I'm assigning this to you. I know this is a large PR, but if you wouldn't mind either doing a quick QA or asking questions or just saying "do it up", that'd be cool, just so I'm not introducing a bunch of changes on the sly.
I will check it out tonight!
This looks really awesome!!
This commit performs some major refactoring of the app’s models. A lot of repeated code was removed by code generation tools AutoValue and AutoValue-Parcel.
https://github.com/google/auto/tree/master/value https://github.com/rharter/auto-value-parcel
Now, models are abstract classes that basically define the models’ public APIs. Most models also have an inner abstract Builder class. Both are generated by AutoValue.
Model classes that need custom parceling behavior are annotated with
@ParcelAdapter
and a custom TypeAdapter parceling implementation. This allows AutoValue-Parcel to properly generate parceling code to maintain the Parcelable interface of our models.To accommodate the updated model interfaces, Gson deserializers have been updated and/or created to properly deserialize JSON from the API into the proper models.
Resolves #3