本文整理汇总了C++中Quote::isbn方法的典型用法代码示例。如果您正苦于以下问题:C++ Quote::isbn方法的具体用法?C++ Quote::isbn怎么用?C++ Quote::isbn使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Quote
的用法示例。
在下文中一共展示了Quote::isbn方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: print_total
double print_total(std::ostream& os, const Quote& item, size_t n)
{
double ret = item.net_price(n);
os << "ISBN:" << item.isbn() << "# sold: " << n << "total due: "
<<ret << std::endl;
return ret;
}
示例2: print_total
double print_total(ostream& os, const Quote& item, size_t number){
double ret = item.net_price(number);
os << "ISBN: " << item.isbn() << " # sold: " << number
<< " total due: " << ret << endl;
return ret;
}
示例3: print_total
double print_total(std::ostream& out, const Quote& item, std::size_t n)
{
// depending on the type of the object bound to the item parameter
// call corresponding functuon either Quote::net_price or Bulk_quote::net_price
double ret = item.net_price(n);
out << "IBSN: " << item.isbn() << " # sold: " << n << " total due: " << ret << std::endl;
return ret;
}
示例4: print_total
// non-member
double print_total(std::ostream &os, const Quote &item, size_t n)
{
// depending on the type of the object bound to the item parameter
// calls either Quote::net_price or Bulk_quote::net_price
double ret = item.net_price(n);
os << "ISBN: " << item.isbn() // calls Quote::isbn
<< " # sold: " << n << " total due: " << ret << std::endl;
return ret;
}
示例5: print_total
double print_total(ostream& os, Quote const& item, size_t sold)
{
double net_price = item.net_price(sold);
os << "isbn: " << item.isbn() << ", sold: " << sold
<< ", total due: " << net_price << endl;
return net_price;
}
示例6: printTotal
void printTotal(ostream& os, const Quote& book, const size_t bookNum)
{
os << book.isbn() <<":" <<book.net_price(bookNum);
}