Lazuardy
1 min readFeb 4, 2020

--

Actually, this workaround is already posted by someone on internet. But, I think this is kinda tricky solution, because you have to add several properties to your JSON to get this things work.

In the InterfaceAdapter, it’s clearly say that he need the CLASSNAME and DATA property to verify the serialize and deserialize process. So, your JSON will looks like this:

{
CLASSNAME: “YourClass” // declare your class target
DATA: {
// your actual JSON object goes here
}
}

Sign up to discover human stories that deepen your understanding of the world.

Free

Distraction-free reading. No ads.

Organize your knowledge with lists and highlights.

Tell your story. Find your audience.

Membership

Read member-only stories

Support writers you read most

Earn money for your writing

Listen to audio narrations

Read offline with the Medium app

--

--

Lazuardy
Lazuardy

Written by Lazuardy

We help businesses through bleeding edge technology — www.lazuardy.tech.

Responses (1)

Write a response