-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjava.h
More file actions
26 lines (21 loc) · 746 Bytes
/
Copy pathjava.h
File metadata and controls
26 lines (21 loc) · 746 Bytes
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
#pragma once
#include "product.h"
#include <vector>
#include <iostream>
enum Darkness {Blonde, Light, Medium, Dark, Extra_dark};
const std::vector<std::string> darkness_to_string =
{"Blonde", "Light", "Medium", "Dark", "Extra Dark"};
enum Shot {None, Chocolate, Vanilla, Peppermint, Hazelnut};
const std::vector<std::string> shot_to_string =
{"none", "chocolate", "vanilla", "peppermint", "hazelnut"};
class Java : public Product {
public:
Java(std::string name, double price, double cost, Darkness darkness);
Java(std::istream& ist);
void add_shot(Shot shot);
void save(std::ostream& ost)override;
std::string to_string() override;
protected:
Darkness _darkness;
std::vector<Shot> _shots;
};