You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have tried creating a POJO class with constructors supporting both object and array format, i.e. Data and Data[]
I have tried creating variations using a mix of constructors and setters.
I started to look at mixins but I didn't get very far as documentation and sample code referring to mixins is minimal.
I have created many converters to serialize/deserialize many custom data types like timestamps for example. Would a custom converter or more specifically a custom JsonReader.ReadObject be required?
Is it supported using dsl_json in any way?
More generally, I have often wanted to optionally deserialize data based on the presence of an attribute and have never managed to figure out if it was possible.
As always, thanks for all your effort in a great library!
The text was updated successfully, but these errors were encountered:
Hi,
I need to deserialize data from an external provider where I have no control of the format and one of the attributes can be an array or an object.
Sample data:
and
I have tried creating a POJO class with constructors supporting both object and array format, i.e.
Data
andData[]
I have tried creating variations using a mix of constructors and setters.
I started to look at mixins but I didn't get very far as documentation and sample code referring to mixins is minimal.
I have created many converters to serialize/deserialize many custom data types like timestamps for example. Would a custom converter or more specifically a custom
JsonReader.ReadObject
be required?Is it supported using dsl_json in any way?
More generally, I have often wanted to optionally deserialize data based on the presence of an attribute and have never managed to figure out if it was possible.
As always, thanks for all your effort in a great library!
The text was updated successfully, but these errors were encountered: