Summary Files Commits Branches @commit @diff @stats
path: root / Year 1 / Object-oriented Programming / 09-Practice-19.04.2022 / Order.h
blob: d044c2defca8978be0a59350cec09a44c9a6e381 (plain) (blame)
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
#include "Product.h"

class Order {
	char restaurantName[25];
	Product* products;
	int productCount;

	void free();
	void copyFrom(const Order& other);

	void move(Order&& other);

public:
	Order(const char* restaurant);

	~Order();
	Order(const Order& other);
	Order& operator=(const Order& other);

	Order(Order&& other);
	Order& operator=(Order&& other);


	void addProduct(const Product& product);

	const char* get_restaurantName() const;
	int get_productCount() const;
	const Product* get_products() const;
};