本文整理汇总了C++中Customer::getID方法的典型用法代码示例。如果您正苦于以下问题:C++ Customer::getID方法的具体用法?C++ Customer::getID怎么用?C++ Customer::getID使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Customer
的用法示例。
在下文中一共展示了Customer::getID方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: rentVideo
void VideoStore::rentVideo(Customer &customer, int movieID)
{
db->rentVideo(customer.getID(), movieID);
db->updateQuantity(customer.getID(), 1);
db->updateVideoQuantity(movieID, -1);
customer.rentVideo(movieID);
}
示例2: dispAccount
void Manager::dispAccount(int uID){
Customer foundCust = findCust(uID);
cout<<"\nUsername: " << foundCust.getUserName() << "\nID Number: " << foundCust.getID();
if (foundCust.hasChequing()){
cout<<"\nChequing Account Balance: $"<<foundCust.getBalance(0);
}
if (foundCust.hasSavings()){
cout<<"\nSavings Account Balance: $"<<foundCust.getBalance(1);
}
cout<<endl;
}
示例3: memberRegistration
void memberRegistration() {
clearScreen();
cout << "Member Registration" << endl
<< "Register what kind of member?" << endl
<< "1. Gold Member" << endl
<< "2. Platinum Member" << endl
<< "3. Cancel" << endl << endl;
int memberType;
Customer* c;
bool success;
do {
success=true;
cout << "Selection: ";
memberType=getInt();
if(memberType==1 || memberType==2) {
char name[256];
do {
cout << "Enter name: ";
cin.getline(name,32);
if(!cin) {
cin.clear();
cin.ignore(numeric_limits<streamsize>::max(),'\n');
}
if(name[0]==0) {cout << "Invalid name!" << endl;}
} while(name[0]==0);
switch(memberType) {
case 1:
c=new MemberGold(name);
break;
case 2:
c=new MemberPlatinum(name);
break;
}
} else if(memberType==3) {
return;
} else {
success=false;
}
} while(!success);
Transaction* t=new Transaction(c);
t->registerMember();
cout << "The member ID is " << c->getID() << endl;
checkout(t);
delete t;
t=NULL;
}
示例4:
History::History(Customer cust, Business bus)
{
customerHistoryID = cust.getID();
}