⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 employeeinfo.java

📁 Athena酒店小组_Athena酒店管理系统
💻 JAVA
字号:
/*
 * EmployeeInfo.java
 * Copyright (C) 2007 Athena project team
 */

package vincent;

import java.io.Serializable;
import java.util.Calendar;
import java.util.Date;


/**
 * 实体类 EmployeeInfo
 * @author Vincent
 * @version 1.0
 */
public class EmployeeInfo implements Serializable
{
    protected String employeeId;
    protected String employeeName;
    protected String alias;
    protected String sex;
    protected String deptId;
    protected String job;
    protected String workState;
    protected String study;
    protected String professional;
    protected String school;
    protected Date leaveSchoolTime;
    protected String politics;
    protected Date birthDate;
    protected String email;
    protected String netCommunication;
    protected String homeAddress;
    protected String cellPhone;
    protected Date joinTime;
    protected String iDCardNo;
    protected Date startWorkTime;
    protected String nativePlace;
    protected String nation;
    protected String health;
    protected String marriage;
    protected String remark;
    
    /** 构造函数 */
    public EmployeeInfo()
    {
    }
    
    /**
     * 使用指定的值创建 EmployeeInfo 的新实例。
     * @param employeeId,EmployeeInfo 的 employeeId
     */
    public EmployeeInfo(String employeeId)
    {
	this.setEmployeeId(employeeId);
    }
    
    /**
     * 使用指定的值创建 EmployeeInfo 的新实例。
     * @param employeeId,EmployeeInfo 的 employeeId
     * @param employeeName,EmployeeInfo 的 employeeName
     */
    public EmployeeInfo(String employeeId, String employeeName)
    {
	this.setEmployeeId(employeeId);
	this.setEmployeeName(employeeName);
    }
    
    /**
     * 获取此 EmployeeInfo 的 employeeId。
     * @return employeeId
     */
    public String getEmployeeId()
    {
	return this.employeeId;
    }
    
    /**
     * 将此 EmployeeInfo 的 employeeId 设置为指定的值。
     * @param employeeId,新建 employeeId
     */
    public void setEmployeeId(String employeeId)
    {
	this.employeeId = employeeId;
    }
    
    /**
     * 获取此 EmployeeInfo 的 employeeName。
     * @return employeeName
     */
    public String getEmployeeName()
    {
	return this.employeeName;
    }
    
    /**
     * 将此 EmployeeInfo 的 employeeName 设置为指定的值。
     * @param employeeName,新建 employeeName
     */
    public void setEmployeeName(String employeeName)
    {
	this.employeeName = employeeName;
    }
    
    /**
     * 获取此 EmployeeInfo 的 alias。
     * @return alias
     */
    public String getAlias()
    {
	return this.alias;
    }
    
    /**
     * 将此 EmployeeInfo 的 alias 设置为指定的值。
     * @param alias,新建 alias
     */
    public void setAlias(String alias)
    {
	this.alias = alias;
    }
    
    /**
     * 获取此 EmployeeInfo 的 sex。
     * @return sex
     */
    public String getSex()
    {
	return this.sex;
    }
    
    /**
     * 将此 EmployeeInfo 的 sex 设置为指定的值。
     * @param sex,新建 sex
     */
    public void setSex(String sex)
    {
	this.sex = sex;
    }
    
    /**
     * 获取此 EmployeeInfo 的 age。
     * @return age
     */
    public Integer getAge()
    {
	Date date = new Date(System.currentTimeMillis());
	int age = date.getYear() - birthDate.getYear();
	return age;
    }
    
    /**
     * 获取此 EmployeeInfo 的 deptId。
     * @return deptId
     */
    public String getDeptId()
    {
	return this.deptId;
    }
    
    /**
     * 将此 EmployeeInfo 的 deptId 设置为指定的值。
     * @param deptId,新建 deptId
     */
    public void setDeptId(String deptId)
    {
	this.deptId = deptId;
    }
    
    /**
     * 获取此 EmployeeInfo 的 job。
     * @return job
     */
    public String getJob()
    {
	return this.job;
    }
    
    /**
     * 将此 EmployeeInfo 的 job 设置为指定的值。
     * @param job,新建 job
     */
    public void setJob(String job)
    {
	this.job = job;
    }
    
    /**
     * 获取此 EmployeeInfo 的 workState。
     * @return workState
     */
    public String getWorkState()
    {
	return this.workState;
    }
    
    /**
     * 将此 EmployeeInfo 的 workState 设置为指定的值。
     * @param workState,新建 workState
     */
    public void setWorkState(String workState)
    {
	this.workState = workState;
    }
    
    /**
     * 获取此 EmployeeInfo 的 study。
     * @return study
     */
    public String getStudy()
    {
	return this.study;
    }
    
    /**
     * 将此 EmployeeInfo 的 study 设置为指定的值。
     * @param study,新建 study
     */
    public void setStudy(String study)
    {
	this.study = study;
    }
    
    /**
     * 获取此 EmployeeInfo 的 professional。
     * @return professional
     */
    public String getProfessional()
    {
	return this.professional;
    }
    
    /**
     * 将此 EmployeeInfo 的 professional 设置为指定的值。
     * @param professional,新建 professional
     */
    public void setProfessional(String professional)
    {
	this.professional = professional;
    }
    
    /**
     * 获取此 EmployeeInfo 的 school。
     * @return school
     */
    public String getSchool()
    {
	return this.school;
    }
    
    /**
     * 将此 EmployeeInfo 的 school 设置为指定的值。
     * @param school,新建 school
     */
    public void setSchool(String school)
    {
	this.school = school;
    }
    
    /**
     * 获取此 EmployeeInfo 的 leaveSchoolTime。
     * @return leaveSchoolTime
     */
    public Date getLeaveSchoolTime()
    {
	return this.leaveSchoolTime;
    }
    
    /**
     * 将此 EmployeeInfo 的 leaveSchoolTime 设置为指定的值。
     * @param leaveSchoolTime,新建 leaveSchoolTime
     */
    public void setLeaveSchoolTime(Date leaveSchoolTime)
    {
	this.leaveSchoolTime = leaveSchoolTime;
    }
    
    /**
     * 获取此 EmployeeInfo 的 politics。
     * @return politics
     */
    public String getPolitics()
    {
	return this.politics;
    }
    
    /**
     * 将此 EmployeeInfo 的 politics 设置为指定的值。
     * @param politics,新建 politics
     */
    public void setPolitics(String politics)
    {
	this.politics = politics;
    }
    
    /**
     * 获取此 EmployeeInfo 的 birthDate。
     * @return birthDate
     */
    public Date getBirthDate()
    {
	return this.birthDate;
    }
    
    /**
     * 将此 EmployeeInfo 的 birthDate 设置为指定的值。
     * @param birthDate,新建 birthDate
     */
    public void setBirthDate(Date birthDate)
    {
	this.birthDate = birthDate;
    }
    
    /**
     * 获取此 EmployeeInfo 的 email。
     * @return email
     */
    public String getEmail()
    {
	return this.email;
    }
    
    /**
     * 将此 EmployeeInfo 的 email 设置为指定的值。
     * @param email,新建 email
     */
    public void setEmail(String email)
    {
	this.email = email;
    }
    
    /**
     * 获取此 EmployeeInfo 的 netCommunication。
     * @return netCommunication
     */
    public String getNetCommunication()
    {
	return this.netCommunication;
    }
    
    /**
     * 将此 EmployeeInfo 的 netCommunication 设置为指定的值。
     * @param netCommunication,新建 netCommunication
     */
    public void setNetCommunication(String netCommunication)
    {
	this.netCommunication = netCommunication;
    }
    
    /**
     * 获取此 EmployeeInfo 的 homeAddress。
     * @return homeAddress
     */
    public String getHomeAddress()
    {
	return this.homeAddress;
    }
    
    /**
     * 将此 EmployeeInfo 的 homeAddress 设置为指定的值。
     * @param homeAddress,新建 homeAddress
     */
    public void setHomeAddress(String homeAddress)
    {
	this.homeAddress = homeAddress;
    }
    
    /**
     * 获取此 EmployeeInfo 的 cellPhone。
     * @return cellPhone
     */
    public String getCellPhone()
    {
	return this.cellPhone;
    }
    
    /**
     * 将此 EmployeeInfo 的 cellPhone 设置为指定的值。
     * @param cellPhone,新建 cellPhone
     */
    public void setCellPhone(String cellPhone)
    {
	this.cellPhone = cellPhone;
    }
    
    /**
     * 获取此 EmployeeInfo 的 joinTime。
     * @return joinTime
     */
    public Date getJoinTime()
    {
	return this.joinTime;
    }
    
    /**
     * 将此 EmployeeInfo 的 joinTime 设置为指定的值。
     * @param joinTime,新建 joinTime
     */
    public void setJoinTime(Date joinTime)
    {
	this.joinTime = joinTime;
    }
    
    /**
     * 获取此 EmployeeInfo 的 iDCardNo。
     * @return iDCardNo
     */
    public String getIDCardNo()
    {
	return this.iDCardNo;
    }
    
    /**
     * 将此 EmployeeInfo 的 iDCardNo 设置为指定的值。
     * @param iDCardNo,新建 iDCardNo
     */
    public void setIDCardNo(String iDCardNo)
    {
	this.iDCardNo = iDCardNo;
    }
    
    /**
     * 获取此 EmployeeInfo 的 startWorkTime。
     * @return startWorkTime
     */
    public Date getStartWorkTime()
    {
	return this.startWorkTime;
    }
    
    /**
     * 将此 EmployeeInfo 的 startWorkTime 设置为指定的值。
     * @param startWorkTime,新建 startWorkTime
     */
    public void setStartWorkTime(Date startWorkTime)
    {
	this.startWorkTime = startWorkTime;
    }
    
    /**
     * 获取此 EmployeeInfo 的 nativePlace。
     * @return nativePlace
     */
    public String getNativePlace()
    {
	return this.nativePlace;
    }
    
    /**
     * 将此 EmployeeInfo 的 nativePlace 设置为指定的值。
     * @param nativePlace,新建 nativePlace
     */
    public void setNativePlace(String nativePlace)
    {
	this.nativePlace = nativePlace;
    }
    
    /**
     * 获取此 EmployeeInfo 的 nation。
     * @return nation
     */
    public String getNation()
    {
	return this.nation;
    }
    
    /**
     * 将此 EmployeeInfo 的 nation 设置为指定的值。
     * @param nation,新建 nation
     */
    public void setNation(String nation)
    {
	this.nation = nation;
    }
    
    /**
     * 获取此 EmployeeInfo 的 health。
     * @return health
     */
    public String getHealth()
    {
	return this.health;
    }
    
    /**
     * 将此 EmployeeInfo 的 health 设置为指定的值。
     * @param health,新建 health
     */
    public void setHealth(String health)
    {
	this.health = health;
    }
    
    /**
     * 获取此 EmployeeInfo 的 marriage。
     * @return marriage
     */
    public String getMarriage()
    {
	return this.marriage;
    }
    
    /**
     * 将此 EmployeeInfo 的 marriage 设置为指定的值。
     * @param marriage,新建 marriage
     */
    public void setMarriage(String marriage)
    {
	this.marriage = marriage;
    }
    
    /**
     * 获取此 EmployeeInfo 的 remark。
     * @return remark
     */
    public String getRemark()
    {
	return this.remark;
    }
    
    /**
     * 将此 EmployeeInfo 的 remark 设置为指定的值。
     * @param remark,新建 remark
     */
    public void setRemark(String remark)
    {
	this.remark = remark;
    }
    
    
    
    /**
     * 返回对象的散列代码值。该实现根据此对象
     * 中 id 字段计算散列代码值。
     * @return 此对象的散列代码值。
     */
    public int hashCode()
    {
	int hash = 0;
	hash += (this.getEmployeeId() != null ? this.getEmployeeId().hashCode() : 0);
	return hash;
    }
    
    /**
     * 确定其他对象是否等于此 EmployeeInfo。当且仅当
     * 参数不为 null 且该参数是具有与此对象相同 id 字段值的 EmployeeInfo 对象时,
     * 结果才为 <code>true</code>。
     * @param 对象,要比较的引用对象
     * 如果此对象与参数相同,则 @return <code>true</code>;
     * 否则为 <code>false</code>。
     */
    public boolean equals(Object object)
    {	
	if (!(object instanceof EmployeeInfo))
	{
	    return false;
	}
	EmployeeInfo other = (EmployeeInfo)object;
	if (this.getEmployeeId() != other.getEmployeeId() && (this.getEmployeeId() == null || !this.getEmployeeId().equals(other.getEmployeeId()))) return false;
	return true;
    }
    
    /**
     * 返回对象的字符串表示法。该实现根据 id 字段
     * 构造此表示法。
     * @return 对象的字符串表示法。
     */
    public String toString()
    {
	return employeeId;
    }    
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -