帮我写一个类名为Emp 的pojo类java代码
时间: 2023-04-03 13:03:58 浏览: 153
好的,以下是Emp类的Java代码:
public class Emp {
private int id;
private String name;
private int age;
private String gender;
private String department;
private String position;
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public int getAge() {
return age;
}
public void setAge(int age) {
this.age = age;
}
public String getGender() {
return gender;
}
public void setGender(String gender) {
this.gender = gender;
}
public String getDepartment() {
return department;
}
public void setDepartment(String department) {
this.department = department;
}
public String getPosition() {
return position;
}
public void setPosition(String position) {
this.position = position;
}
}
阅读全文