How do i catch the below response in retrofit2? It has two different object types. And after retrieving from the api how do I store and use it? This the format of my api response
{
"products": [
{
"categoryID": 2,
"companyID": 1,
"companyName": "Audi",
"productID": 1001,
"productName": "S6"
},
{
"categoryID": 4,
"companyID": 1,
"companyName": "BWM",
"productID": 1001,
"productName": "Zen"
},
{
"categoryID": 5,
"companyID": 1,
"companyName": "Ford",
"productID": 1001,
"productName": "Mustang"
}],
"solutions": [
{
"companyID": 2,
"companyName": "Audi",
"solutionName": "A good plan",
"solutionType": "Personalised",
"working": "dsjhfgsdjhfgjsdh"
},
{
"companyID": 2,
"companyName": "djfhgkkl",
"solutionName": "A good plan",
"solutionType": "Personalised",
"working": "asfh"
}
]
}