How to parse json with fromJson method
        Posted  
        
            by 
                Ankit HTech
            
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by Ankit HTech
        
        
        
        Published on 2012-10-18T10:41:47Z
        Indexed on 
            2012/10/18
            11:00 UTC
        
        
        Read the original article
        Hit count: 368
        
I want to parse my json by fromJson class but I am unable to understand what should be the structure of my class if my json is like below:
String json = "{"Result":{"Status":"SUCCESS","Message":""},"Response":{"Token":"ca0d7507-3907-4eed-af19-ad256bc71088","ZoneUrl":"https:\/\/qa.tritononline.com\/","CustomerID":1,"UserID":29,"DefaultLanguageID":1,"ZoneID":1,"IsTritonIntegrated":false,"Language":[{"LanguageId":1,"Language":"English","IsSelected":false}]}}"
This is what I want to do
Response res = new Response();
        Gson gson = new Gson();
        res = gson.fromJson(json, Response.class);
I want to know what all variable should I take in Response class.
© Stack Overflow or respective owner