Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

31 create common classes v0.1 #33

Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions src/main/java/seedu/duke/data/Menu.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
package seedu.duke.data;

import seedu.duke.data.dish.Dish;

import java.util.ArrayList;

public class Menu {
private ArrayList<Dish> menuItems;

public Menu(ArrayList<Dish> menuItems) {
this.menuItems = menuItems;
}
}
15 changes: 15 additions & 0 deletions src/main/java/seedu/duke/data/dish/Dish.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package seedu.duke.data.dish;

import java.util.ArrayList;

public class Dish {
private String name;
private ArrayList<Ingredient> ingredients;
private double price;

public Dish(String name, ArrayList<Ingredient> ingredients, double price) {
this.name = name;
this.ingredients = ingredients;
this.price = price;
}
}
9 changes: 9 additions & 0 deletions src/main/java/seedu/duke/data/dish/Ingredient.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
package seedu.duke.data.dish;

public class Ingredient {
private final String name;

public Ingredient(String name) {
this.name = name;
}
}
7 changes: 7 additions & 0 deletions src/test/java/seedu/duke/data/MenuTest.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package seedu.duke.data;

//import static org.junit.jupiter.api.Assertions.*;

class MenuTest {

}
7 changes: 7 additions & 0 deletions src/test/java/seedu/duke/data/dish/DishTest.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package seedu.duke.data.dish;

//import static org.junit.jupiter.api.Assertions.*;

class DishTest {

}
7 changes: 7 additions & 0 deletions src/test/java/seedu/duke/data/dish/IngredientTest.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package seedu.duke.data.dish;

//import static org.junit.jupiter.api.Assertions.*;

class IngredientTest {

}