xxxx18一60岁hd中国/日韩女同互慰一区二区/西西人体扒开双腿无遮挡/日韩欧美黄色一级片 - 色护士精品影院www

資源簡(jiǎn)介

用rose畫(huà)出了 人事管理中常用的用例圖,類(lèi)圖,順序圖,協(xié)作圖.雖然簡(jiǎn)單但是思路還是很清晰的,軟件的開(kāi)發(fā)設(shè)計(jì)重要的就是思想.

資源截圖

代碼片段和文件信息

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

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

//**********************************************
//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;? //將柜組代碼由字符轉(zhuǎn)換為數(shù)字
cout?< cin?>>?status_code;?//獲取員工職務(wù)代碼
while(status_code!=‘1‘&&?status_code!=‘2‘&&?status_code!=‘3‘)
{
cin?>>?status_code;
}
status_code-=48;? //將職務(wù)代碼由字符轉(zhuǎn)換為數(shù)字
strcpy(estruct.namename);? //將信息寫(xiě)入結(jié)構(gòu)體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(?))? //讀到文件結(jié)束
{
inpos=iofile.tellg(?);? //獲取當(dāng)前文件指針位置
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(?))? //讀到文件結(jié)束
{
inpos=iofile.tellg(?);? //獲取當(dāng)前文件指針位置
iofile.read((char*)&estructsizeof(estruct));
i=strcmp(estruct.namename_str);
if(i==0)
{
estruct.gcode=g_code;? //柜組代碼
estruct.scode=s_code;? //職務(wù)代碼
iofile.seekp(inpos);? //將文件指針從待修改記錄的尾部移動(dòng)到頭部
iofile.write((char*)&estructsizeof(estruct));
cout?< break;
}
}
iofile.close(?);
if(i!=0)
{
cout?< }
}
//*********************************************************************
//************

?屬性????????????大小?????日期????時(shí)間???名稱(chēng)
-----------?---------??----------?-----??----

?????文件???????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大作業(yè).doc

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

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

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


評(píng)論

共有 條評(píng)論

相關(guān)資源