0

Below is my sample JSON which I am getting from server I am using GSON annotation :-

{
    "FAMILY": [{
        "G": "0",
        "Red": [{
            "G": "89.5140282228858",
            "B": "75.6247151421873",
            "R": "190.744678043659"
        }, {
            "G": "159.384178987744",
            "B": "142.476648231788",
            "R": "237.397293369723"
        }]
    }, {
        "G": "0",
        "Blue": [{
            "G": "89.5140282228858",
            "B": "75.6247151421873",
            "R": "190.744678043659"
        }, {
            "G": "159.384178987744",
            "B": "142.476648231788",
            "R": "237.397293369723"
        }]
    }]
}
swiftBoy
  • 35,607
  • 26
  • 136
  • 135

1 Answers1

0

You can use Map for parsing json with dynamic keys. this link might help you. which uses gson to parse json. check this link also. check out the documentation of gson here.

Community
  • 1
  • 1
droidev
  • 7,352
  • 11
  • 62
  • 94