Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

JAVA GUI- OOP Your code structure will be suitable for object oriented programming. Please don't make the code structure complicated. can you explain the code

JAVA GUI- OOP

Your code structure will be suitable for object oriented programming.

Please don't make the code structure complicated.

can you explain the code you wrote (create comment lines. (explain methods)

This project needs to be done urgently, can you do it immediately? (In about 12 hours) How long can you complete? Can you inform me? Can you write a comment.

Please make sure the code you wrote is correct, Thank you

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

image text in transcribed

Create the classes in the Class diagram. Chef Employee > # id: int # name: String + Employee (int, String) + toString(): String - mastery: String - canCook: ArrayList constructor with necessary parameters + toString(): String + addMeal (Meal): boolean + getMealsofChef(): String necessary getters and setters Meal RIS - meal Name: String - type: String + Meal (String, String) + toString(): String + equals (Meal): boolean necessary getters and setters - chefs: ArrayList + addChef (Chef): boolean + getAllChefsWithMeals(): String + getAllChefs (): String + checkChef (int) :int + list Type (String): String Employee (5 pts) Write the data members, constructor and override toString() method. Meal (10 pts) Write the data members, constructor and override toString() method. Write an equals method that gets a Meal object as a parameter and checks if the name and type equals to the object. Chef (15 pts) Write the data members, constructor and override toString() method. Write an addMeal method that gets a Meal object as a parameter and adds it to the ArrayList if that meal doesn't exist in the ArrayList. Write a getMealsOfChef method that returns the meals that chef can cook as a String. RIS (25 pts + 15 pts Bonus) (3 pts) Write the data members. (5 pts) Write an addChef method that gets a Chef object as a parameter and adds it to ArrayList if it doesn't exist. (7 pts) Write a getAllChefs With Meals method that returns all the meals with the related chefs as a String. (5 pts) Write a getAllChefs method that returns all the chefs as a String. (5 pts) Write a checkChef method that gets id as a parameter and returns the index of chef with the given id. (Bonus 15 pts) Write a list Type method that gets a type as a parameter and returns all the meals with the given type as a String. Create a JFrame Form as shown below: Welcome X ADD CHEF & MEAL DISPLAY (5 pts) When user clicks "ADD CHEF & MEAL" button related frame will be shown. X Add Chef & Meal Add Chef & Meal O Add Chef Add Meal O Add Chef O Add Meal ID: ID: Name: Name: Mastery: Aperatif Type: : Aperatif ADD ADD CLEAR CLOSE CLEAR CLOSE (3 pts) When user selects between Add Chef" and "Add Meal radio buttons only the 3rd label will be changed as seen in the above screen shots. If the user selects the Add Chef radiobutton: O (10 pts) When user clicks "ADD" button program should add the chef to the Arraylist if it doesn't exist in the ArrayList. 0 s Add Chef & Meal Add Chef & Meal O Add Cher Add Meal Add Cher Add Meal ID: 100 ID: 100 Name John Name Sophie Mastory Main Course Mastory. Aperatif ADD ADD Chefadded!! Chef already exists!! CLEAR CLOSE CLEAR CLOSE If the user selects the Add Meal radiobutton: (10 pts) When user clicks ADD" button program should add the meal to the Arraylist if it doesn't exist in the ArrayList. Also checks if that chef exists or not. Add Chef & Meal Add Chef & Meal Add Chet Add Meal Add Chef Add Meal ID: 200 ID 101 Name: Salad Name: Salad Type: Aperatit Type Aperatif ADD ADD Chef doesn't exist!! Neal added!! CLEAR CLOSE CLEAR CLOSE Add Chef & Meal x Add Chet Add Meal ID 101 Name: Salad Type Aperatit ADD Meal already exists!! CLEAR CLOSE (2 pts) When user clicks "CLEAR" button all textfields and messageLabel will be cleared and combobox should return to default selection. (5 pts) When user clicks "DISPLAY button from the first frame the following frame will be shown. X Display Display Chefs Display Meals Aperatur Bonus CLOSE (5 pts) When user clicks "Display Chefs" button all chefs will be displayed in the text area. Display Display Chefs Display Meals Aperatif ID 100 Name: John Mastory: Main Course ID 101 Name Sophie Nastery: Aperatif CLOSE (5 pts) When user clicks "Display Meals" button all meals with the chefs will be displayed in the text area. Display Display Chefs Display Meals Aperatif Chef John Chef can cook Meal Name: Beef Type: Main Course Meal Name: Ravioli Type: Main Course Chef:Sophie Chef can cook CLOSE (Bonus 5 pts) When user selects a meal type from combobox, meals with selected type will be displayed in the text area. X Display Display Chofs Display Moals Aperatif Meals in selected type are: Meal Name: Salad Type: Aperatif Meal Name: Crepes Type: Aperatif CLOSE

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Cost Accounting A Managerial Emphasis

Authors: Charles T. Horngren, Srikant M. Datar, Madhav V. Rajan

15th edition

978-0133428858, 133428850, 133428702, 978-0133428704

More Books

Students also viewed these Accounting questions

Question

Required Information - here is the 1 0 4 0 completed

Answered: 1 week ago