JSON to Java Class Converter is easy to use tool to convert JSON to Java Class. Copy, Paste and Convert.
It offer tools for:
Tips: you can customer the java class name and package name .
Input json string:
{
"id":1,
"name":"John",
"age":24
}
Output java class result:
package com.online.compiler.json2bean;
/**
* Auto-generated: 2024-08-09 15:9:0
*
* @author www.online-compiler.com
* @website http://www.online-compiler.com/json/json2java/
*/
public class OnlineCompiler {
private int id;
private String name;
private int age;
public void setId(int id) {
this.id = id;
}
public int getId() {
return id;
}
public void setName(String name) {
this.name = name;
}
public String getName() {
return name;
}
public void setAge(int age) {
this.age = age;
}
public int getAge() {
return age;
}
}