www.pudn.com > Flight_Book.rar > User.cpp


#include "string.h" 
#include "iostream.h" 
#include "iomanip.h" 
 
#include "User.h" 
 
CUser::CUser() 
{ 
 
} 
 
CUser::~CUser() 
{ 
 
} 
 
char * CUser::GetUserID() 
{ 
	return userID; 
} 
 
char * CUser::GetPassword() 
{ 
	return password; 
} 
 
int CUser::GetPopedom() 
{ 
	return popedom; 
} 
void CUser::SetUserID(char *ID) 
{ 
	strcpy(userID, ID); 
} 
 
void CUser::SetPassword(char *psd) 
{ 
	strcpy(password, psd); 
} 
 
void CUser::SetPopedom(int pdm) 
{ 
	popedom = pdm; 
} 
 
CUser CUser::operator=(const CUser &right) 
{ 
	strcpy(userID, right.userID); 
	strcpy(password, right.password); 
	popedom = right.popedom; 
	return *this; 
} 
 
CUser::CUser(const CUser &right) 
{ 
	strcpy(userID, right.userID); 
	strcpy(password, right.password); 
	popedom = right.popedom; 
} 
 
void CUser::Show() 
{ 
	cout<<"╔--------------------------------------------------------╗\n"; 
	cout<<"  |"<<"用户名"<<"|"<<"用户密码"<<"用户权限"<<"|"<