?? employeeentity.cs
字號:
?using System;
/// <summary>
/// 員工資料實體
/// </summary>
public class EmployeeEntity
{
//定義私有變量
private string _name = "";
private string _sex = "";
private string _phone = "";
private string _mail = "";
private DateTime _birthday;
private string _note = "";
private string _depart = "";
//無參數的構造函數
public EmployeeEntity()
{
}
/// <summary>
/// 有參數的構造函數,初始化聯(lián)系資料
/// </summary>
/// <param name="name">姓名</param>
/// <param name="sex">性別</param>
/// <param name="phone">電話</param>
/// <param name="birthday">生日</param>
/// <param name="mail">郵箱</param>
/// <param name="note">備注</param>
/// <param name="depart">部門</param>
public EmployeeEntity(string name, string sex, string phone, DateTime birthday, string mail, string note, string depart)
{
//為私有變量賦值
this._depart = depart;
this._name = name;
this._sex = sex;
this._phone = phone;
this._birthday = birthday;
this._mail = mail;
this._note = note;
}
//員工姓名屬性
public string Name
{
get { return _name; }
set { _name = value; }
}
//性別
public string Sex
{
get { return _sex; }
set { _sex = value; }
}
//電話屬性
public string Phone
{
get { return _phone; }
set { _phone = value; }
}
//生日
public DateTime Birthday
{
get { return _birthday; }
set { _birthday = value; }
}
//Mail屬性
public string Mail
{
get { return _mail; }
set { _mail = value; }
}
//備注屬性
public string Note
{
get { return _note; }
set { _note = value; }
}
//員工所在部門
public string Depart
{
get { return _depart; }
set { _depart = value; }
}
}
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -