Sample JSON Data
I have written a sample JSON to test this tool. You can get the JSON from PasteBin or try this tool with your own JSON data. You can visualize the structure of your JSON using several online JSON converters. I have used JSONViewer from Stack.hu. Below is the structure of my sample JSON data.
Generating Java Class from JSON
You can use JSON Gen – Client Code generation tool from ByintonDesign.com to generate Java classes from JSON data. The best part is the you could specify your JSON Data Class name and the Package name while generating.
One small drawback is the site doesn’t have option to directly paste the JSON data. You got to specify the url containing the JSON data, one quick workaround is to use online clipboards such as PasteBin to generate URL for the data. Click on the Raw option as shown below in the paste to get the direct url.
Your Comments
0 Responses to "How to generate Java Class files from JSON"