-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathItem.h
51 lines (40 loc) · 967 Bytes
/
Item.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#ifndef ITEM_H
#define ITEM_H
#include <iostream>
#include <string>
#include <vector>
#include "Printable.h"
using namespace std;
class Item : public Printable
{
protected:
int numItem;
double price;
string brand;
bool isPerishableItem;
public:
// Constructors
Item(int numItem, double price, string brand, bool isPerishableItem);
Item();
// Getters
int get_numItem() const;
double get_price() const;
string get_brand() const;
bool get_isPerishableItem() const;
// Setters
void set_numItem(int);
void set_price(double);
void set_brand(string);
void set_isPerishableItem(bool a);
// Methods
void print() override;
virtual void change_numItem(int n);
virtual void sellItem(int n);
virtual void updateItem();
virtual int get_shelfLifeInDay();
virtual int *get_expirationList();
virtual void set_expirationList(int *n);
// Destructor
~Item();
};
#endif