I have the following code which I am trying to parse from JSON using Google GSON:
jsonLine = "
{
"data": {
"translations": [
{
"translatedText": "Hello world"
}
]
}
}
";
JsonParsing class
public class JsonParsing{
public void parse(String jsonLine) {
// ---------Get Hello World Here-------
}
}
How do I fetch the "Hello World" string in my class? Please help.