|
|
package domain; // 定义在 domain 包下,表示该类是领域对象类,用于存储教师的个人信息。
|
|
|
|
|
|
/**
|
|
|
* Teacher类,表示教师的个人信息。
|
|
|
* 该类用于存储教师的基本信息,包括教师ID、姓名、性别、教育背景、职称和登录密码。
|
|
|
*/
|
|
|
public class Teacher {
|
|
|
|
|
|
private String t_id; // 教师ID
|
|
|
private String t_name; // 教师姓名
|
|
|
private String t_sex; // 教师性别
|
|
|
private String t_education; // 教师教育背景
|
|
|
private String t_title; // 教师职称
|
|
|
private String t_password; // 教师登录密码
|
|
|
|
|
|
/**
|
|
|
* 获取教师ID。
|
|
|
*
|
|
|
* @return 返回教师的ID
|
|
|
*/
|
|
|
public String getT_id() {
|
|
|
return t_id;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 设置教师ID。
|
|
|
*
|
|
|
* @param t_id 教师ID
|
|
|
*/
|
|
|
public void setT_id(String t_id) {
|
|
|
this.t_id = t_id;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 获取教师姓名。
|
|
|
*
|
|
|
* @return 返回教师的姓名
|
|
|
*/
|
|
|
public String getT_name() {
|
|
|
return t_name;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 设置教师姓名。
|
|
|
*
|
|
|
* @param t_name 教师姓名
|
|
|
*/
|
|
|
public void setT_name(String t_name) {
|
|
|
this.t_name = t_name;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 获取教师性别。
|
|
|
*
|
|
|
* @return 返回教师的性别
|
|
|
*/
|
|
|
public String getT_sex() {
|
|
|
return t_sex;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 设置教师性别。
|
|
|
*
|
|
|
* @param t_sex 教师性别
|
|
|
*/
|
|
|
public void setT_sex(String t_sex) {
|
|
|
this.t_sex = t_sex;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 获取教师教育背景。
|
|
|
*
|
|
|
* @return 返回教师的教育背景
|
|
|
*/
|
|
|
public String getT_education() {
|
|
|
return t_education;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 设置教师教育背景。
|
|
|
*
|
|
|
* @param t_education 教师教育背景
|
|
|
*/
|
|
|
public void setT_education(String t_education) {
|
|
|
this.t_education = t_education;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 获取教师职称。
|
|
|
*
|
|
|
* @return 返回教师的职称
|
|
|
*/
|
|
|
public String getT_title() {
|
|
|
return t_title;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 设置教师职称。
|
|
|
*
|
|
|
* @param t_title 教师职称
|
|
|
*/
|
|
|
public void setT_title(String t_title) {
|
|
|
this.t_title = t_title;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 获取教师登录密码。
|
|
|
*
|
|
|
* @return 返回教师的登录密码
|
|
|
*/
|
|
|
public String getT_password() {
|
|
|
return t_password;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 设置教师登录密码。
|
|
|
*
|
|
|
* @param t_password 教师的登录密码
|
|
|
*/
|
|
|
public void setT_password(String t_password) {
|
|
|
this.t_password = t_password;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 重写 toString 方法,返回教师信息的字符串表示。
|
|
|
*
|
|
|
* @return 返回一个包含教师ID、姓名、性别、教育背景、职称和密码的字符串
|
|
|
*/
|
|
|
@Override
|
|
|
public String toString() {
|
|
|
return "Teacher{" +
|
|
|
"t_id='" + t_id + '\'' +
|
|
|
", t_name='" + t_name + '\'' +
|
|
|
", t_sex='" + t_sex + '\'' +
|
|
|
", t_education='" + t_education + '\'' +
|
|
|
", t_title='" + t_title + '\'' +
|
|
|
", t_password='" + t_password + '\'' +
|
|
|
'}';
|
|
|
}
|
|
|
}
|