Question: Hello, need help with making the program MealData.txt Avocado Egg Rolls 6.00 Parmesan-crusted Chicken 19.75 Strawberry Shortcake Pizookie 8.25 BBQ Tri-Tip Sliders 12.95 Spicy Peanut

Hello, need help with making the program

NOTE: You MAY NOT use arrays, ArrayLists or any other data structure

MealData.txt

Avocado Egg Rolls

6.00

Parmesan-crusted Chicken

19.75

Strawberry Shortcake Pizookie

8.25

BBQ Tri-Tip Sliders

12.95

Spicy Peanut Chicken with Soba Noodles

17.25

Monkey Bread Pizookie

8.25

Bacon Jam Wings

16.25

Prime Rib

28.95

Pizookie Trio

11.95

Honey Sriracha Brussels Sprouts

7.95

Mandarin Orange-Glazed Pork Chop

21.95

Mini Pizookie

4.25


NOTE: You MAY NOT use arrays, ArrayLists or any other data structure for this assignment. You may not use String.split() for this assignment. Create a UML class diagram representing a restaurant Meal. The meal consists of an appetizer and the appetizer's price, an entre and the entre's price and a dessert and the dessert's price. The Meal has the capability to report the value of all attributes, the total cost of the meal (getTotalCost() added to the Meal class - returns the price of appetizer, entree and dessert) and the current state of the object (using the toString()). The Java program will read a data file consisting of a restaurant (BJ's Restaurant) meal's dishes with corresponding prices to create Meal objects. The data in the file looks like this (remember that there are 4 meals in the data file): appetizer appetizer price entre entre price dessert dessert price The "driver" will have methods for the following: Read data from the file to create ONE Meal object at a time, (the data file contains data for 4 meals) - the data file is organized by meal: appetizer followed by its price on the next line, entree followed by its price on the next line, dessert followed by its price on the next line. Display one Meal object at a time and its total, well formatted (if you format your output in the toString() this is relatively easy) An example run (this shows ONE Meal object, yours will have 4 meals, the tip is calculated on the total of all meals) The meal at BJ's Restaurant consists of: Avocado Egg Rolls Parmesan-crusted Chicken $6.00 $19.75 Strawberry Shortcake Pizookie $ 8.25 Total $34.00

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!