Advertisement
Guest User

Untitled

a guest
Mar 17th, 2018
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. #include "ItemToPurchase.h"
  5.  
  6. void ItemToPurchase::SetName(string itemName) {
  7. name = itemName;
  8. return;
  9. }
  10. string ItemToPurchase::GetName() const {
  11. return name;
  12. }
  13. void ItemToPurchase::SetPrice(double itemPrice) {
  14. price = itemPrice;
  15. return;
  16. }
  17. double ItemToPurchase::GetPrice() const {
  18. return price;
  19. }
  20. void ItemToPurchase::SetQuantity(int itemQuantity) {
  21. quantity = itemQuantity;
  22. return;
  23. }
  24. int ItemToPurchase::GetQuantity() const {
  25. return quantity;
  26. }
  27.  
  28. ItemToPurchase::ItemToPurchase() {
  29. name = "none";
  30. price = 0.0;
  31. quantity = 0;
  32. return;
  33. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement