-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDish.java
More file actions
61 lines (47 loc) · 1.08 KB
/
Copy pathDish.java
File metadata and controls
61 lines (47 loc) · 1.08 KB
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
52
53
54
55
56
57
58
59
60
61
package FunctionalProgramming.Model;
/**
* Created by brahim on 5/29/17.
*/
public class Dish {
private String name;
private boolean vegetarian;
private int calorie;
public Type type;
public enum Type {
MEAT, FISH, OTHER
}
public Dish(String name, boolean vegetarian, int calorie, Type type) {
this.name = name;
this.vegetarian = vegetarian;
this.calorie = calorie;
this.type = type;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public boolean isVegetarian() {
return vegetarian;
}
public void setVegetarian(boolean vegetarian) {
this.vegetarian = vegetarian;
}
public int getCalorie() {
return calorie;
}
public void setCalorie(int calorie) {
this.calorie = calorie;
}
public Type getType() {
return type;
}
public void setType(Type type) {
this.type = type;
}
@Override
public String toString() {
return name;
}
}