91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

資源簡介

用rose畫出了 人事管理中常用的用例圖,類圖,順序圖,協作圖.雖然簡單但是思路還是很清晰的,軟件的開發設計重要的就是思想.

資源截圖

代碼片段和文件信息

#include?
#include?
#include?
#include?“emp1.h“
#include?“comm.h“
struct?emp_struct
{
int?number;
char?name[30];
int?gcode;
int?scode;
}estruct;? //員工信息記錄結構,用于記錄員工信息

struct?sal_struct
{
int?number;
char?name[30];
int?month;
float?salary;
}sstruct;? //員工工資信息記錄結構,用于記錄工資信息

//**********************************************
//class?Employee
//**********************************************
void?Employee::addEmployee(?)
{
cout?< cin?>>?name;
cout?< cin?>>?number;
while(number<1000?||?number>9999)
{
cout?< cin?>>?number;
}
cout?< cin?>>?group_code;? //獲取員工柜組代碼
while(group_code!=‘1‘?&&?group_code!=‘2‘?&&?group_code!=‘3‘)
{
cin?>>?group_code;
}
group_code-=48;? //將柜組代碼由字符轉換為數字
cout?< cin?>>?status_code;?//獲取員工職務代碼
while(status_code!=‘1‘&&?status_code!=‘2‘&&?status_code!=‘3‘)
{
cin?>>?status_code;
}
status_code-=48;? //將職務代碼由字符轉換為數字
strcpy(estruct.namename);? //將信息寫入結構體estruct中
estruct.number=number;
estruct.gcode=group_code;
estruct.scode=status_code;
ofstream?ofile(“Employee.txt“ios::app|ios::binary);
if(!ofile)
{
cerr?< return;
}
ofile.write((char*)&estructsizeof(estruct));
ofile.close(?);
cout?<}

void?Employee::delEmployee(?)? //刪除員工信息
{
int?i;
long?inpos;? //用于記錄文件指針位置
cout?< cin?>>?name;
fstream?iofile(“employee.txt“?ios::in|ios::out|ios::binary);
if(!iofile)
{
cerr?< return;
}
while(!iofile.eof(?))? //讀到文件結束
{
inpos=iofile.tellg(?);? //獲取當前文件指針位置
iofile.read((char*)&estructsizeof(estruct));
i=strcmp(estruct.namename);
if(i==0)
{
estruct.number=0;
strcpy(estruct.name“#?#?#“);
estruct.gcode=0;
estruct.scode=0;
iofile.seekp(inpos);
iofile.write((char*)&estructsizeof(estruct));
cout?< break;
}
}
iofile.close(?);
if(i!=0)
{
cout?< }
}

void?Employee::satusChange(char?name_str[30]int?g_codeint?s_code)
{
int?i;
long?inpos;? //用于記錄文件指針位置
fstream?iofile(“Employee.txt“?ios::in|ios::out|ios::binary);
if(!iofile)
{
cerr?< return;
}
while(!iofile.eof(?))? //讀到文件結束
{
inpos=iofile.tellg(?);? //獲取當前文件指針位置
iofile.read((char*)&estructsizeof(estruct));
i=strcmp(estruct.namename_str);
if(i==0)
{
estruct.gcode=g_code;? //柜組代碼
estruct.scode=s_code;? //職務代碼
iofile.seekp(inpos);? //將文件指針從待修改記錄的尾部移動到頭部
iofile.write((char*)&estructsizeof(estruct));
cout?< break;
}
}
iofile.close(?);
if(i!=0)
{
cout?< }
}
//*********************************************************************
//************

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----

?????文件???????1566??2007-07-23?13:55??emp\emp1.h

?????文件???????8351??2007-07-23?13:53??emp\Employee.cpp

?????文件???????3791??2010-06-25?15:28??emp\main.cpp

?????文件???????3626??2007-07-23?11:20??emp\main.dsp

?????文件????????533??2007-07-23?11:12??emp\main.dsw

?????文件????1608192??2010-06-25?12:28??UML大作業.doc

?????目錄??????????0??2010-06-25?15:29??emp

-----------?---------??----------?-----??----

??????????????1626059????????????????????7


評論

共有 條評論