类的成员是这些

保存数据的函数
void Company::Save(std::list<Employee> &list)
{
ofstream outfile("F:\\131\\VS\\Worker\\Worker\\Worker\\Employee.txt", ios::trunc);
if (outfile.is_open())
{
outfile << setw(4) << "编号" << setw(9) << "姓名" << setw(9) << "年龄" << setw(9) << "性别" << setw(9) << "邮编" << setw(9) << "部门" << setw(10) << "工资" << endl;
for (auto it = list.begin(); it != list.end(); it++)
{
outfile << *it << endl;
}
}
outfile.close();
}